This example demonstrates Notecard Outboard Firmware Update, which lets you update a host MCU's firmware over-the-air from Notehub with no host code required to perform the download. The Notecard receives the new firmware image and reprograms the host over the DFU signals on a Notecarrier F.
The circuit-python/code.py sample:
- Configures the Notecard to enable Outboard Firmware Update for the host
(
card.dfu,card.aux, anddfu.status). - Blinks the built-in LED with a recognizable pattern. This is the "payload" you update over-the-air.
This example targets the Blues Swan on a Notecarrier F. Cygnet does not support CircuitPython.
- A Blues Swan running CircuitPython
- A Notecarrier F with a Notecard
- A Notehub account and project
- The
notecardpackage copied into thelib/notecarddirectory of your device (copy the contents of this repo'snotecard/directory), as described in the repo README
- Set the
ProductUIDon your Notecard (via the in-browser terminal or the Notecard CLI) so it reports to your Notehub project, or setproductUIDincode.py. - Copy
circuit-python/code.pyto your Swan (CircuitPython auto-runscode.pyon boot). The LED will blink and the Notecard will report firmware version1.0.0to Notehub.
- In
code.py, changeBLINK_DELAY(for example to0.1for a fast blink) and bumpFIRMWARE_VERSION(for example to2.0.0). - Build a firmware image and upload it to Notehub, then apply the DFU action to the host. See the Outboard Firmware Update guide for the full build-and-upload walkthrough.
- Once the update is applied, the LED blink speed changes and Notehub reports the new firmware version — confirming the over-the-air update succeeded.
