What serial connection means and why you need it

A serial connection links your PX4 flight controller to a computer using a USB cable or dedicated serial port. This connection lets you upload flight code, monitor sensor data in real time, and troubleshoot problems without removing the controller from your drone or aircraft. Most PX4 boards come with a micro-USB port or a dedicated serial header — the physical pins where you plug in a cable.

The connection works one direction at a time: data flows from the flight controller to your computer, or from your computer to the flight controller, but not simultaneously. This is different from modern USB, which sends and receives at the same time. Understanding this limitation helps you know what to expect when you're watching live data or uploading new firmware.

You'll use serial connection for three main tasks: flashing new PX4 firmware onto the board, reading diagnostic messages and sensor values while the drone is running, and configuring parameters that control how the flight controller behaves. Each task uses the same physical connection but different software on your computer.

Key Takeaways

  • Serial connection requires a USB cable (usually micro-USB) or a dedicated serial adapter, plus software on your computer like QGroundControl or a terminal program.
  • Before connecting, install the correct USB driver for your flight controller board — Windows often needs this, while macOS and Linux usually detect it automatically.
  • Identify your board's serial port in your operating system (COM3 on Windows, /dev/ttyUSB0 on Linux, /dev/tty.usbserial on macOS) before opening any software.
  • Most serial connections use 57600 or 115200 baud rate — the speed at which data travels — and you must match this in your software or the connection will show garbage text.
  • If your board has a dedicated serial header instead of USB, you need a USB-to-serial adapter (FTDI or CH340 chip) to connect to your computer.

Identifying your PX4 board and its serial port

Different PX4 boards have different serial connections. The Pixhawk 4 and Pixhawk 4 Mini use micro-USB. The original Pixhawk uses a dedicated 6-pin DF13 connector. Newer boards like the Pixhawk 6C use USB-C. Check your board's manual or the label on the board itself to see which type you have.

Once you know the physical port, you need to find what your computer calls it. On Windows, open Device Manager (right-click the Start button, select Device Manager), plug in your board, and look under "Ports (COM & LPT)". You should see a new entry like "COM3" or "COM5" appear. Write down that number.

On macOS, open Terminal and type ls /dev/tty.usb*. You'll see something like /dev/tty.usbserial-14201. On Linux, type ls /dev/ttyUSB* and you'll see /dev/ttyUSB0 or similar. These are your serial port names — you'll enter them into your software next.

Installing USB drivers on Windows

Windows often does not recognize PX4 boards automatically. If Device Manager shows an unknown device with a yellow warning triangle instead of a COM port, you need a driver. The driver depends on which USB chip your board uses — most Pixhawk boards use the Silicon Labs CP210x chip, while some use the CH340.

For Silicon Labs boards, download the driver from Silicon Labs' website (search "CP210x USB to UART Bridge VCP Drivers"), unzip it, and run the installer for your Windows version (32-bit or 64-bit). Restart your computer. Plug in your board again and Device Manager should now show a COM port with no warning.

For CH340 boards, download the driver from WCH's website (search "CH340 driver Windows"), unzip it, run the installer, and restart. If you're not sure which chip your board has, check the board's documentation or look at the small chip near the USB port — the label will say "CP2102" or "CH340".

macOS and Linux usually detect these boards without drivers. If your board does not appear in Terminal after plugging it in, try a different USB cable — some cables are charge-only and do not carry data.

Connecting with QGroundControl

QGroundControl is the most common software for PX4 boards. It shows live sensor data, lets you configure parameters, and can upload firmware. Download it from qgroundcontrol.com for Windows, macOS, or Linux.

Open QGroundControl and plug in your board. The software should detect it automatically and show a green "Connected" indicator at the top. If it does not, click the "Q" icon in the top left, select "Comm Links", and manually add your serial port. Enter the port name (COM3, /dev/ttyUSB0, etc.) and set the baud rate to 57600. Click "Connect".

Once connected, you can see real-time data under the "Analyze" tab — accelerometer readings, compass direction, GPS position if you have a GPS module. The "Parameters" tab lets you change how the flight controller responds to stick input, how fast it climbs, and dozens of other settings. Changes take effect immediately but are not saved to the board until you click "Write".

Using a terminal program for direct serial access

If you want to see raw diagnostic messages or test commands directly, use a terminal program instead of QGroundControl. On Windows, download PuTTY (putty.org). On macOS and Linux, you can use the built-in Terminal.

In PuTTY, select "Serial" as the connection type, enter your COM port (COM3), set the speed to 57600, and click "Open". You should see text scrolling past — these are PX4's startup messages and sensor readings. If you see only garbage characters, the baud rate is wrong; try 115200 instead.

On macOS, type screen /dev/tty.usbserial-14201 57600 (replace with your actual port). On Linux, type screen /dev/ttyUSB0 57600. To exit, press Ctrl+A, then Ctrl+D. A terminal program is useful for debugging because you see every message the flight controller sends, not just the ones QGroundControl displays.

Uploading firmware over serial

Firmware is the software that runs on the flight controller itself. To upload new firmware, you need QGroundControl and a serial connection. Plug in your board, open QGroundControl, and click the "Q" icon, then "Vehicle Setup". Select "Firmware" on the left.

QGroundControl will detect your board type automatically. Choose the firmware version you want (usually the latest stable release), and click "OK". The software will download the firmware file and upload it to your board. This takes one to three minutes. Do not unplug the board during this time.

When the upload finishes, the board will restart automatically. You'll see new startup messages in the terminal or in QGroundControl's message log. If the upload fails, check that your USB cable is plugged in firmly, try a different USB port on your computer, and try again.

Troubleshooting a connection that will not work

If your board does not appear in Device Manager, QGroundControl, or Terminal, start with the cable. Try a different USB cable — many cables are designed for charging only and do not carry data. Plug the board into a different USB port on your computer, preferably a port directly on the motherboard rather than a hub.

If you see a COM port in Device Manager but QGroundControl will not connect, the baud rate is usually the problem. Open QGroundControl's Comm Links settings and try both 57600 and 115200. If neither works, unplug the board, wait five seconds, and plug it back in.

On Windows, if Device Manager shows an unknown device with a yellow triangle, you need to install the USB driver. Download and run the driver for your board's USB chip (CP210x or CH340), restart your computer, and plug in the board again. On macOS or Linux, if the port does not appear in Terminal, the board may be in bootloader mode — unplug it, hold the boot button (if your board has one) while plugging it back in, then release the button.

Using a dedicated serial header instead of USB

Some PX4 boards have a 6-pin or 4-pin serial header instead of a USB port. This header has pins labeled TX (transmit), RX (receive), and GND (ground). To connect to your computer, you need a USB-to-serial adapter — a small device with a USB plug on one end and loose wires on the other.

Common adapters use the FTDI FT232 chip or the CH340 chip. Plug the adapter into your computer's USB port. Connect the adapter's TX wire to the board's RX pin, the adapter's RX wire to the board's TX pin, and the adapter's GND wire to the board's GND pin. The TX and RX are crossed — TX on the adapter goes to RX on the board, not the other way around.

Once connected, your computer will see a new serial port (COM4, /dev/ttyUSB1, etc.). Use this port in QGroundControl or your terminal program just as you would with a USB board. If the adapter does not appear, install its driver — search for "FTDI driver" or "CH340 driver" and your operating system.

Frequently Asked Questions

What baud rate should I use?

Most PX4 boards use 57600 baud. Some newer boards or custom firmware may use 115200. If you see garbage text in your terminal, try the other rate. QGroundControl usually detects the correct rate automatically.

Can I connect multiple flight controllers to one computer?

Yes. Each board will appear as a separate COM port (COM3, COM4, etc.) or serial device (/dev/ttyUSB0, /dev/ttyUSB1, etc.). Open a separate instance of QGroundControl or your terminal program for each board, and select the correct port in each one.

Do I need to disconnect the battery before connecting over serial?

No. Serial connection draws very little power and will not damage the board. However, if you are uploading firmware, it is safer to disconnect the battery so the board cannot accidentally arm motors during the upload.

Why does my connection drop after a few seconds?

This usually means the board is resetting. Check that your USB cable is plugged in firmly and that you are not touching the board while it is connected. If the board keeps resetting, it may be in a boot loop — try uploading fresh firmware using QGroundControl's Firmware tab.

Can I use a wireless connection instead of serial?

Yes, but not for initial setup or firmware uploads. Once your board is running, you can use a telemetry radio (like the 3DR Radio) or a WiFi module to connect wirelessly. Serial is required for the first connection and for troubleshooting.