Example #1
0
 def turn_drone_left(self):
     cmd = DroneMovementCommand()
     cmd.movement_command = G.TURN_LEFT
     self.drone_command_pub.publish(cmd)
     rospy.sleep(1.0)
Example #2
0
    def failsafe(self):
        cmd = DroneMovementCommand()
        cmd.movement_command = G.DO_EMERGENCY
        self.drone_command_pub.publish(cmd)

        print('Failed Safely')
Example #3
0
 def move_drone_right(self):
     cmd = DroneMovementCommand()
     cmd.movement_command = G.GO_RIGHT
     self.drone_command_pub.publish(cmd)
     rospy.sleep(1.0)
Example #4
0
 def move_drone_backwards(self):
     cmd = DroneMovementCommand()
     cmd.movement_command = G.GO_BACKWARD
     self.drone_command_pub.publish(cmd)
     rospy.sleep(1.0)
Example #5
0
 def move_drone_forward(self):
     cmd = DroneMovementCommand()
     cmd.movement_command = G.GO_FORWARD
     self.drone_command_pub.publish(cmd)
     rospy.sleep(1.0)
Example #6
0
 def land_drone(self):
     cmd = DroneMovementCommand()
     cmd.movement_command = G.DO_LAND
     self.drone_command_pub.publish(cmd)
     rospy.sleep(1.0)
Example #7
0
 def takeoff_drone(self):
     cmd = DroneMovementCommand()
     cmd.movement_command = G.DO_TAKEOFF
     self.drone_command_pub.publish(cmd)
     rospy.sleep(1.0)