Kespry drone

Drone Coding: Fun, Future, and Fundamentals

This entry is part 8 of 8 in the series September 2017

For Surveying’s Next Generation

Attracting the next generation of surveyors is a perennial topic in the geospatial profession. I’d like to suggest adding K-12 UAS coding programs to the list of outreach efforts. The sooner students become interested in the geospatial field, the greater the success of attracting them to the profession. It is widely believed that young people’s personalities become fixed to a great degree by the age of 18; waiting until high school may be too late.

Why Drone Coding?

That kids love flying toys is a given. And I think we can all agree that drones are playing an important role in the geospatial profession, a role that promises to grow. Why coding? In today’s digital world, many people believe that coding is a fundamental skill that should be taught like math and reading.

I just finished reading The Second Machine Age: Work, Progress, and Prosperity in a Time of Brilliant Technologies by Erik Brynjolfsson and Andrew McAfee, about the impact of artificial intelligence, automation, and robotics on humans. The authors point out three places where we need to excel to keep ahead of the automation curve.

Humans exceed robots in three critical areas: 1) ideation, the ability to generate ideas; 2) wide-spectrum pattern recognition, the ability to see patterns across disparate disciplines to create solutions; and 3) communication, especially with machines; in other words, coding and programming. Proponents of coding education argue the coding teaches ideation/creativity as well.

I’ve been hearing this “learn to code” drumbeat for some time now, and coincidentally an email from Apple started me on path to learn more. “Learn to code drones” was the subject line, and the email invited to me to download Apple’s Swift Playgrounds app for the iPad. The app is designed for students of all ages to learn Swift, the programming language of Apple apps.

Parrot’s Playground

From numerous individual lesson packages (called playgrounds), I focused on drone-related playgrounds and found two from Parrot, the parent company of senseFly. I added the Parrot Education playground and went over to Parrot’s website to see what they had to offer in the realm of drone education, including coding.

Turns out they have a robust offering for K-12, collegiate, field research, and developers. Starting out as an absolute beginner to coding, I checked out the K-12 section. At this level Parrot offers coding for its MiniDrones, both aerial and ground-based products. (Parrot’s MiniDrones are toys and not to be confused to geospatial data-collecting UAS.)

What’s more, I found several other compatible programs that teach coding. In addition to Swift Playgrounds, Parrot MiniDrones can work with Tynker (iOS, Android and Chromebook) and Tickle (iOS).

Because I had already installed the Apple Swift Playground for Parrot, I dived into its lessons and found it educational and fun. While coding in general is a useful skill, coding for drones in an educational environment has at least three strong advantages.

  1. It’s interactive; the student writes the code, runs the code, and watches the drone perform its programmed tasks, providing instant feedback and reinforcement.
  2. Students learn the terminology and underlying mechanics of UAS flight. Gaz (moving up and down), roll (left and right movement), pitch (forward and backwards movement), yaw (rotation), and other terms are explained and demonstrated.
  3. Professional data-collection UAS makes good use of autonomous (programmed) flight. While the programing of flight maneuvers is generally built in to most UAS control and navigation systems, knowing the underlying concepts is a real bonus. Additionally, many UAS manufacturers incorporate open-source coding so that end-users can customize flight operations.

Let’s take a look at these programs. One caveat: my experience was with the Apple ecosystem of hardware and software. I don’t have an Android tablet so I cannot comment on how that platform works. (Your experience may differ, and save those receipts!)

Fig 1, drone coding

Fig 1

Apple’s Swift Playgrounds is comprised of a dual-paned interface (Figure 1). On the top left are the lesson’s goals and instructions; below is the actual coding window with the requisite code commands and functions displayed along the bottom. In the right pane is an animated display of the done and how it functions with the code written. At the bottom of this pane is the “Run My Code” command button.

The student works through the lessons by reading the goals and instructions, then starts the coding process by simply tapping on the commands and functions displayed along the bottom in the correct and logical sequence. The Swift 3.0 code is displayed in simple English with the required brackets, parenthesis, and punctuation already in place (Figure 2).

Fig 2, drone coding

Fig 2

After the code is written, the student pairs the app with the drone via Bluetooth and hits the “Run My Code” button. The code is transmitted to the drone through the Bluetooth connection, and the programming automatically initiates, providing instant feedback of whether the code sequence met the goals of the lesson. If not, the program offers up a hint suggesting what the student did wrong.

Tynker and Tickle operate similarly with the big difference being how they handle the coding process. In both programs the raw code is encapsulated in visual coding blocks similar to Lego bricks that the student drags from the left side of the display and snaps into place in the required order to accomplish the mission (Figure 3). After coding is complete, the student taps the right arrow button on the lower-left of the screen and the drone takes off and executes the project.

Fig 3, drone coding

Fig 3

With this in mind, it’s easy to see that the visual coding approach of Tynker and Tickle are probably best suited for the younger set, while Apple’s Swift Playgrounds might be more appropriate for older students who are less intimidated by raw coding.

Next Steps

If you are a parent who’d like to introduce your child to both coding and drones, then check out Parrot’s website for ideas and products. If you’re involved or would like to become involved with STEM education at your local school, either as a parent or as a resource, a conversation with the STEM educator might be in order. Parrot has an Education Guide you can download as an aid to starting a conversation.

If you’d like to learn more about coding for your own personal development, just jump in. I had a blast and can heartily recommend this as an educational activity.


To read the rest of the articles in this print issue, click on the issue cover, below.

Series Navigation<< Tech Feats for a X-Country Course

Leave a Reply

Your email address will not be published. Required fields are marked *