Skip to content
timm411 edited this page Nov 24, 2014 · 8 revisions

Welcome to the superbitrf-firmware wiki!

We collect some basic operational information here.

Getting started

Visit the paparazzi wiki page.

Flashing firmware

  1. Clone the superbitrf-firmware repository.
  • Open the terminal
  • Change directory into the superbitrf-firmware directory
  • run git submodule init to initialize the libopencm3 submodule
  • run git submodule update to download the libopencm3 submodule
  • run make
  • plug in your Superbit USBRF dongle while holding "the button" on the Superbit USBRF dongle, into your laptop (you should see the red and yellow LED blink alternating, indicating that the bootloader is active)
  • run make flash

Updating firmware

  1. Enter the superbitrf-firmware directory
  • run git pull to fetch newest changes from the superbitrf-firmware repository
  • run make clean to clean previous binaries
  • run make
  • plug in your Superbit USBRF dongle while holding "the button" on the Superbit USBRF dongle, into your laptop (you should see the red and yellow LED blink alternating, indicating that the bootloader is active)
  • run make flash

Binding your transmitter to the Superbit USBRF dongle

  1. Plug in the Superbit USBRF dongle into your computer
  • Press "the button" on the Superbit USBRF dongle (the orange led should light up)
  • Turn on your transmitter while holding the bind button. (for more information how to turn on your transmitter in bind mode refer to your transmitters documentation. This varies a lot depending on the version and maker of the transmitter. Spektrum DX6I and Orange RX transmitters you just hold the Trainer switch while you power it on. Others have a dedicated bind button on the back of the transmitter that you hold while turning on your transmitter.)
  • If binding was successful the orange led will turn off
  • Release the bind button on the transmitter
  • After few seconds another led will light up indicating that the dongle is seeing/receiving packets from the transmitter

Tip: sometimes the binding is not successful on the first try, you might need to turn off and on (while still holding the bind button) your transmitter several times before the dongle recognizes your transmitter and the orange LED turns off

Retreiving the MFG ID of your DSM2 transmitter.

This is a good way to keep the binding permanent. We do not support storing of the binding parameters in flash yet. This is work in progress #2 .

  • Clone the superbitrf-firmware repository.
  • Edit the src/modules/config.c file and adjust the settings to the following ones:
  • Increase the .version = 0x01 by One
-                       .debug_enable                           = false,
+                       .debug_enable                           = true,
  • Open the terminal
  • change into the superbitrf-firmware directory
  • run make
  • plug in your Superbit USBRF dongle while holding "the button" on your Superbitrf USBRF dongle, into your laptop (you should see the red and yellow LED blink alternating, indicating that the bootloader is active)
  • run firmware upload make flash
  • cycle power (unplug and plug in again) the USBRF dongle
  • connect to the virtual serial port using minicom or other serial terminal software. The virtual serial port on linux will usually be /dev/ttyACM0, on Mac OS X it will for example be /dev/cu.usbmodemURF0001 depending on your USBRF serial number. The baud rate setting does not matter, as it is being ignored by the virtual serial port.
  • enter at least one letter into the serial terminal
  • enter bind mode of the USBRF by pressing "the button" on USBRF (it should be confirmed with the orange LED getting lit)
  • switch on your RC transmitter in bind mode (it depends on your transmitter, check your manual if you are not sure)
  • When binding is successful you should get a debug output that looks something like this:
[button]: "Bind button pressed"
[protocol]: "DSM MITM start bind"
[protocol]: "Binded with values : mfg_id[0-3]=0x85; 0xE2; 0x76; 0x86, num_channel=0x06; protocol=0x03"
  • You can now enter the settings into the config.c file in the following lines:
.dsm_bind_mfg_id                        = {0x85, 0xE2, 0x76, 0x86},
.dsm_protocol                           = 0x03,
  • To add the transmitter to your paparazzi airframe file you have to convert the mfg_id to an integer in reverse order. To do that you would need to assemble the hex numbers from the example before like this: 0x8676E285 = 2255938181

We are working hard on simplifying the process. If you want to help out just join us on gitter: Gitter chat

Binding your transmitter to Lisa/S

This is not exactly the topic of the code here, but rather the paparazzi UAS side of the process. For convenience we include it here.

  1. Power on the Lisa/S autopilot while holding the bind button on the board
  • The Radio LED should be blinking in short blinks once a second
  • Turn on your transmitter while holding the bind button
  • The Radio LED should stop blinking
  • Now you will have to press the bind button again and the transmitter should get recognized and the data should be received