Sending roll/pitch/yaw/thrust in High-Level Mode
Posted: Sun Sep 06, 2020 4:44 pm
I am interested in using the CF firmware logic for calculating setpoints and the roll/pitch/yaw/thrust computed by the controller to be passed back to the CF as send_setpoint(roll, pitch, yaw, thrust).
Basically, the same roll/pitch/yaw/thrust computed by the firmware is sent back to the drone from the remote/PC side.
Since send_setpoint(roll, pitch, yaw/yawRate, thrust) is taken in a setPointQueue, I want to make sure that the setpoint_t used for calculating in high-level mode does not interfere with the setpoint_t struct used for actuation. How can I do that? Does my logic make sense?
Basically, the same roll/pitch/yaw/thrust computed by the firmware is sent back to the drone from the remote/PC side.
- I already made firmware changes where I have 2 setpoint_t and control_t structs. One pair of setpoint_t and control_t is responsible for calculating the setpoint and controller inputs. The other pair is used for actuation.
- I have a client script that reads roll/pitch/yaw/thrust in callback routine over a ROS topic using crazyflie_ros.
- I then send the roll/pitch/yaw/thrust in /cmd_vel topic using crazyflie_ros to the drone.
Since send_setpoint(roll, pitch, yaw/yawRate, thrust) is taken in a setPointQueue, I want to make sure that the setpoint_t used for calculating in high-level mode does not interfere with the setpoint_t struct used for actuation. How can I do that? Does my logic make sense?