This wiki documents Piksi v2.3.1 which was discontinued April 1st, 2017.
Visit support.swiftnav.com for newer products including Piksi Multi.

HOW-TO: Flashing the Piksi firmware using the bootloader

From Swift Navigation Wiki
Jump to: navigation, search

The Piksi ships with a bootloader pre-installed on the on-board microcontroller. This allows users to update or change the microcontroller firmware over USB without needing a JTAG programmer.

If anything in this guide is incorrect or unclear, please email our mailing list.

Prerequisites

Complete the instructions for your architecture at HOW-TO: Setting up developer tools for Piksi before proceeding.

Obtaining the latest firmware

The latest firmware (.hex) for the microcontroller can be obtained from our downloads page:

http://download.swift-nav.com/piksi_v2.3.1/stm_fw/

The microcontroller firmware can also be built from source from our GitHub repository. If you wish to build the firmware from source, please follow the Piksi Developer Getting Started Guide.

Getting the bootload script source

Clone the Piksi tools repository, which contains the bootload script source, using Git:

$ cd ~
$ git clone https://github.com/swift-nav/piksi_tools.git

Running the bootloader script

Enter the piksi_firmware/scripts directory

$ cd ~/piksi_tools/piksi_tools/

Unplug your Piksi if it is plugged into your computer via USB cable.

Execute the bootload.py python script with the -s (STM flash) option. If you've downloaded the firmware from download.swift-nav.com/piksi_v2.3.1/stm_fw/ to your piksi_tools folder, the command will be the following, where vX.Y is the latest firmware version.

$ python bootload.py -s piksi_v2.3.1_stm_fw_vX.Y.hex


Plug in the Piksi via USB, the script will automatically connect and update the firmware.

More usage information is available by running:

$ python bootload.py --help

The default USB serial device used is /dev/ttyUSB0, to use a different device (e.g. under OS X) you may specify the -p option:

$ python bootload.py -p /dev/tty.usbserial1234 -s piksi_v2.3.1_stm_fw_vX.Y.hex

or on Windows:

$ python bootload.py -p COM3 -s piksi_v2.3.1_stm_fw_vX.Y.hex

Updating the SwiftNAP (FPGA) firmware

The bootloader script is also used to flash the SwiftNAP (FPGA) firmware to Piksi.

The latest firmware (.hex) for the SwiftNAP can be obtained from our downloads page:

http://download.swift-nav.com/piksi_v2.3.1/nap_fw/

Use the -m (instead of -s) option to update the SwiftNAP firmware. If you've downloaded the firmware from download.swift-nav.com/piksi_v2.3.1/nap_fw/ to your piksi_firmware/scripts folder, the command will be the following, where vX.Y is the latest firmware version.

$ python bootload.py -m piksi_v2.3.1_nap_fw_vX.Y.hex

Firmware Update Video Tutorial

The video below shows the process. Please note the video refers to the bootload.py script residing in the piksi_firmware repository, but the script now resides in the piksi_tools repository.

https://github.com/swift-nav/piksi_tools