Instructional Material: First Flight

Printer-friendly version

We are now ready to fly the drone under program control. This example adds the command for the drone to take off. When this command is issued the drone will start it's propellors and take off to hover at the default starting height. The take off can take several seconds and the drone will not respond to new commands until take off is completed. The takeOff() method will wait for confirmation from the drone that take off is finished.

Once in the air, we call movement control methods on TelloControl to move the drone through several maneuvers. After the maneuvers are complete, the program lands the drone.

The Demo3 example program demonstrates this. Modify the Main class by commenting out the code that runs Demo2 and uncommenting the lines that run Demo3. Take a look at the Demo3 code and then run it with the green arrow button. Make sure there is some room around the drone for small movement back and forth, up and down and 3.25 feet forward.

The final maneuver is a flip. This is commented out to start. After you fly the drone and see it in action, you can uncomment the flip and try it out. The flip is a bit violent so be ready!

 

Material Type: 
Lab Activity
Education Level: 
HW Platform: 
SW Platform: 
Interactivity Style: 
Audience: