We are using request-response over I2C, however, we were wondering if the IAP Host DFU payload transactions could be offloaded to an UART interface.
I see that there are two UART interfaces available on the Noteacard.
Is it true that only NODFU has the flexibility of choosing which interface to pick?
If that is the case, can we repurpose the existing NODFU mode (let’s say stm) to leverage the UART Host update, everything else being equal.
FYI our application runs on top of embedded linux which is configurable. We can easily take cues from Notecard’ BOOT & RESET pin interface to advance the DFU process.
It sounds like you might be working on some wild stuff!
If I understand correctly, you’re trying to leverage NODFU to replace a binary on a POSIX-based system (“embedded linux”)? Cool idea!
What have you tried so far? What SoC and what Notecarrier are you using? The Notecard is a super flexible device, so I’m interested to hear what you’ve tried and what, if any, limitations you’ve encountered.
For my project, we’ve implemented both IAP (dfu.get) and ISP (NOFU) updates.
Notecard has two DFU mechanisms:
IAP where the host controls the update process, fetching chunks from notecard and laying them down in memory. This works over I2C, LPUART (9600 baud serial) or AUX serial. Typically you don’t want to use the LPUART due to the low throughput.
ISP where the notecard primarily controls the DFU process once started. This uses the AUX pins (or AUX ALT pins where available and configured.) The process typically talks to a bootloader running on the device using an established UART protocol for STM, ESP32 or mcuboot.
IAP gives you flexibility - you can choose which interface to use, either the current primary Notecard interface (I2C/Serial) or aux serial. dfu.get supports streaming chunks using the card.binary protocol, which is particularly fast. (YMMV, but our boards successfully use 900kbaud over aux serial for binary transfers, although I haven’t specifically tried dfu.get yet.) Since the host code is always involved, you can manage the entire process - when the update is applied, user feedback, logging etc. But this is also a potential weakness - IAP requires running firmware on the host.
If you wanted to implement NOFU (ISP), communication is fixed to using the designated UART pins described in the NOFU hardware setup. Once the update starts, the update is controlled by Notecard for the duration of the update, without your host firmware being involved, so there’s little user feedback while the firmware update is happening, but this also means the update can flash to bare metal when a permanent bootloader is available (as is typical for STM and Espressif MCUs.)
Our solution is close to a Notecarrier XS type of configuration, but we have a custom board, but I was mainly wanting to get a confirmation on IAP stuff.