When you receive your Meadow board, it will need to have the latest Meadow.OS uploaded, or flashed, to it. To do this, you’ll need to:
- Download the latest Meadow.OS files.
- Put the device into Device Firmware Upgrade (DFU) mode.
- Upload the files to the device.
The following video walks you through all that using a Mac:
Alternatively, you can follow this step by step guide for both macOS and Windows:
Step 1: Install dfu-util
We’ll use the dfu-util app to flash the firmware files to Meadow.
You can download dfu-util from Sourceforge.
Extract the zip to a convenient location that you can access using the Terminal/Command Prompt.
For macOS, you’ll first need to install Brew, if you don’t already have it. Once brew is installed, you can use it install dfu-util:
- Open the terminal.
- Execute the following command:
brew install dfu-util
You can install dfu-util using the apt package manager.
- Open the terminal.
sudo apt-get install dfu-util
Step 2: Put the device into DFU Bootloader mode.
To update the OS, Meadow must be in DFU bootloader mode. To enter this mode, the
BOOT button needs to be held down while the board boots up. This can be accomplished one of two ways.
If the board is disconnected: hold the
BOOT button down and connect the board to your computer via a Micro USB Cable.
If the board is connected: hold the
BOOT button down, and then press and release the
RST (Reset) button. Then release the
Step 3: Upload Meadow.OS
The instructions are essentially the same on all supported platforms (Windows, macOS, Linux).
On Windows, you’ll need to make the
dfu-util.exe executable accessible. You can either:
- Add it’s location to the PATH.
libusb.dllto your working folder.
Use a full qualified path when launching dfu-util. (e.g.
To flash Meadow to the board:
- Unzip the Meadow.OS.zip package. It should contain
- Open the Command Prompt (Windows) or Terminal (macOS/Linux).
- Navigate to the folder the contains the Meadow bin files.
dfu-util --listto see a list of dfu enabled devices:
Note: Meadow will show four (4) DFU devices when in bootloader mode. All four devices will have the same serial number.
Help for Windows error: “Cannot open DFU device 0483:df11” This error can occur when Windows uses a default driver for the USB device that doesn’t support the commands needed for DFU. Use Zadig to replace the default driver with a WinUSB driver. Refer to Scott Hanselman’s blog for more details.
- Select and copy the serial number of your Meadow board.
- Execute the following command, replacing
[DEVICE_SERIAL]with the serial number you found in the previous step. Each command should complete with
File downloaded successfully
dfu-util -a 0 -S [DEVICE_SERIAL] -D Meadow.OS_Kernel.bin -s 0x08000000 && dfu-util -a 0 -S [DEVICE_SERIAL] -D Meadow.OS_Runtime.bin -s 0x08040000
When the flash is complete, press the reset (RST) button to exit DFU bootloader mode and boot into Meadow.OS.
Your board is now ready to have a Meadow application deployed to it!
- If you only have one dfu enabled device connected to your PC, you can omit
- Linux may require
sudoto access USB devices.