Giving high-level control programatically on tum_simulator
I am confused how I can give high-level control like take off, landing etc programatically on tum_simulator. Via terminal of course, I can do something like (taken from the link provided):
Take off:
rostopic pub -1 /ardrone/takeoff std_msgs/Empty
Fly forward:
rostopic pub -r 10 /cmd_vel geometry_msgs/Twist '{linear: {x: 1.0, y: 0.0, z: 0.0}, angular: {x: 0.0,y: 0.0,z: 0.0}}'
Can anybody give me a hint or better still directly give a C++ snippet for take off and fly forward for me to easily grasp it.
Thanks in advance