The free software you need to start drone programming

6 min read
Blue line drawing of a laptop and a quadcopter hovering above it, with a gear icon and a checkmark on a pale sky background.

In this post

What software do you actually need to start programming a drone? Many people assume you need a pricey paid tool, or that you must buy a drone before you can write a single line of code. Neither is true. You can set up a full drone programming environment with free, open-source software and test everything on your own computer first.

Key takeaways

  • A drone programming setup has four software layers: flight firmware, a ground station, a Python library and a simulator or test setup.
  • To start, pick one autopilot path: ArduPilot (with pymavlink and Mission Planner or QGroundControl) or PX4 (with MAVSDK-Python and QGroundControl).
  • Test your code in a simulator before any real flight. The Aasma browser simulator is free, needs no install, and runs in your browser.

What are the four software layers?

Think of a drone programming setup like a small team. Each member has one job, and they pass messages to each other.

The four layers, in short

  1. Flight firmware. The software that runs on the drone’s flight controller and keeps it stable in the air.
  2. Ground station. A computer app for planning flights, watching the drone’s status and setting up its parameters, the settings that control how it flies.
  3. Python library. The code layer you write. It talks to the autopilot over a message system called MAVLink (a shared language drones use to exchange data).
  4. Simulator or test setup. A safe place to run your code before it touches a real drone.

Each layer does something different, so you can learn them one at a time.

Which firmware should you look at first?

Firmware is the core of the drone’s autopilot. Two widely used open-source options are ArduPilot and PX4 Autopilot. ArduPilot’s official documentation describes it as an autopilot for copters, planes and rovers, and it is used in education and research. You can read its copter documentation at ardupilot.org/copter. PX4 Autopilot is also open source and is used in research and industry. Its official documentation is at docs.px4.io. AVO flight controllers from Aasma run ArduPilot and are Arduino-compatible. What decides the choice? Start with the community and the documentation you find most readable, and with the Python library you want to use. Both projects are free to read and learn from.

Which ground station runs on which system?

A ground station is the computer app you use alongside the drone.

  • Mission Planner is the Windows ground station for ArduPilot. You can check its features on its project page.
  • QGroundControl works with both PX4 and ArduPilot, and runs on Windows, Mac and Linux. Check its platform support on its project page.

So if you use Windows with ArduPilot, Mission Planner is one option. If you use Linux, Mac or Windows with either autopilot, QGroundControl is the option to check first.

Which Python library pairs with which autopilot?

This is the key pairing to remember.

You may also come across DroneKit-Python, an older Python API for ArduPilot. Its project page describes it as older, so check its current status before you choose it: github.com/dronekit/dronekit-python.

Two starter stacks, both options

These are two ways to start, not a ranking. Choose the one that matches your goal and your computer.

The ArduPilot path

The PX4 path

Your first week: install in this order

Work through these steps before you touch any hardware.

Step 1: read the official docs

Start with the ArduPilot or PX4 documentation for your chosen path. Official docs are written by the people who build the software, so they are a dependable place to learn the first steps.

Step 2: install the ground station and Python library

Install the ground station and the Python library that match your stack and your operating system. Follow each project’s own installation guide, because versions and steps change over time.

Step 3: check each project’s licence and status

Open each project’s own page and confirm its licence, its features and whether it is still maintained. Do not rely on what you read in a blog post, including this one. Licence terms are set by each project.

Step 4: test before you fly

Always test your code in a simulator before any real flight. A simulator lets you make mistakes for free. The official ArduPilot and PX4 documentation describe simulator options, so follow their guidance for setup. You can also practise flying in the free Aasma BYOD flight simulator, which runs in your browser at sim.aasmaaerospace.in. It has 6 missions and keyboard controls, and needs no install. It is one place to practise flying alongside the open-source options.

Before you fly: check the official rules

Drone rules differ by country and change over time. Before you fly any drone in India, check the current official government rules. This post does not summarise them, so look up the official source yourself before you fly.

Frequently asked questions

Is drone programming software free?

The projects in this post are open source, and you can read their licences on their own pages. Check each licence before you use it. Some tools may have paid versions, so confirm what you are downloading.

Do I need a real drone to start programming?

No. You can write and test code in a simulator first. A real drone comes later, once your code and setup work in the simulator.

Should I learn ArduPilot or PX4 first?

Either is a reasonable start. Choose based on the documentation you find clearest, the Python library you want to use and the ground station that runs on your computer.

Next step

Try the free browser simulator at sim.aasmaaerospace.in. It needs no install, and it has 6 missions and keyboard controls. When you are ready for hardware, explore Aasma’s learning kits.

Try it in the simulator

Free, in your browser. Nothing to install.

Share with a friend who builds drones

Fly a drone in your browser

Free, six missions, nothing to install.

Teaching drones at your college?

We run hands-on workshops in your lab, with our drones and this simulator.

Keep reading

Scroll to Top