Metis Bootloader Sample Code and Application

Overview


Metis Bootloader is a simple application for downloading firmware using the Metis bootloader mode. (The companion Metis Programmer uses the command mode.)

The Metis Bootloader folder is included in the
Metis disk image, and includes a code signed application. You must set your security permission level to run signed applications (see Firewalls instruction.)

The program uses
NetworkInterfaces to find a list of available Ethernet interfaces. It then attempts to find out if there is a bootloader mode Metis device on that Ethernet interface (e.g., "en0") by sending a message to MAC address 11:22:33:44:55:66 that asks for a Metis device's MAC address. If the request times out, Metis Bootloader proceeds make a request at the next Ethernet interface (e.g., "en1"), etc.

Since the Metis device in bootloader mode uses a fixed MAC address (11:22:33:44:55:66) to receive and send raw packets, we only need to know with Ethernet interface it resides on.



Usage


When launched, the Metis Bootloader application looks for a Metis device (Hermes, Angelia, or a stand-alone Metis board) on all the Ethernet interfaces that are connected to the computer. For this reason, it is safest to power down all Metics devices that you do not intend to upgrade firmware.

If no Metis is found, the following alert will appear.

BootloaderNotFound

When using Metis Bootloader, the bootloader jumper must be installed. Metis will not appear as a Metis bootload device if the bootloader jumper is absent. The jumper header is labeled JP12 on a Hermes board, JP17 on an Angelia board, and JP1 on a stand-alone Metis board.

Allow 10 to 15 seconds after powering up the device before trying to reach it.

If the Metis device is found, you will see the Metis Bootloader window:

Bootloaderwindow

The MAC address that is displayed in the window is the MAC address that the device uses when it is not in bootloader mode.

Clicking on Download Firmware brings up a file open dialog which you use to navigate to the file that you wish to download to Metis. Programming starts immediately after a file (with .rbf file extension) is selected. The application goes through an
Erase cycle, followed by a Write cycle. Each cycle could take more than 10 seconds, so be patient.

Bootloaderwrite

If everything works properly, the final window will appear:

BootloaderDone

Power off the device and remove the bootloader jumper before attempting to use the device normally.