My drone is not moving in exercise 2.2

Hello , I am facing a problem in exercise 2.2 as this exercise is about controlling the drone using keyboard but as I download the teleoperation program using command :

git clone GitHub - ros-teleop/teleop_twist_keyboard: Generic Keyboard Teleop for ROS

the file gets downloaded but after the rosrun command :

rosrun teleop_twist_keyboard teleop_twist_keyboard.py

drone is not moving even before modification of code and after the modification of code

Hello @Soham_SD,

please execute this command before running the teleop_twist_keyboard node:

rostopic pub /drone/takeoff std_msgs/Empty "{}" -1

Once the drone is in the air, you can proceed to execute the teleop_twist_keyboard node:

rosrun teleop_twist_keyboard teleop_twist_keyboard.py

And the drone should move now.

Once you have finished, execute:

rostopic pub /drone/land std_msgs/Empty "{}" -1

to bring your drone back to the ground.

Hope this helps,

Roberto

Thank you sir. I will definitely try this method.

This topic was automatically closed after 22 hours. New replies are no longer allowed.