My final aim to design a NMPC controller that would generate a pitch, roll angles, yaw rate commands, and z position command.
What I am trying to do is to publish to the following topic:
/dji_sdk/flight_control_setpoint_rollpitch_yawrate_zposition
To do this, I first launch the dji_sdk_node. Then, I open another terminal, and run the following command in terminal:
rostopic pub /dji_sdk/flight_control_setpoint_rollpitch_yawrate_zposition sensor_msgs/Joy "{header: {stamp: {secs: 0, nsecs: 0}, frame_id: ''}, axes: [0.0, 0.0, 0.0, 0.5], buttons: []}"
When i run the command, it says "publishing and latching message", but I don't see anything happening in the DJI Assitant 2 Simulator.
But, When I publish to the /dji_sdk/flight_control_setpoint_generic, it works and I see the drone moving in the simulator. I think it has to do something with the flags. Could anyone please help me out here!
My final aim to design a NMPC controller that would generate a pitch, roll angles, yaw rate commands, and z position command.
What I am trying to do is to publish to the following topic:
/dji_sdk/flight_control_setpoint_rollpitch_yawrate_zpositionTo do this, I first launch the
dji_sdk_node. Then, I open another terminal, and run the following command in terminal:rostopic pub /dji_sdk/flight_control_setpoint_rollpitch_yawrate_zposition sensor_msgs/Joy "{header: {stamp: {secs: 0, nsecs: 0}, frame_id: ''}, axes: [0.0, 0.0, 0.0, 0.5], buttons: []}"When i run the command, it says "publishing and latching message", but I don't see anything happening in the DJI Assitant 2 Simulator.
But, When I publish to the
/dji_sdk/flight_control_setpoint_generic, it works and I see the drone moving in the simulator. I think it has to do something with the flags. Could anyone please help me out here!