Adding support for nrfutil and Adafruit nRF52 Feather

I have been working on adding support for the Adafruit nRF52 Feather and I need to add the nrfutil package to allow upload via the DFU bootloader.

I can find very little info or example for how to integrate new tools, can any one give me some pointers?

As a secondary problem to upload the .hex file it requires two commands:

nrfutil dfu genpkg --dev-type 0x0052 --sd-req 0x00A5 --application .pioenvs/bluefruit_nrf52/firmware.hex .pioenvs/bluefruit_nrf52/firmware.zip
nrfutil dfu serial -pkg .pioenvs/bluefruit_nrf52/firmware.zip -p /dev/ttyUSB0 -b 115200

What is the best way to integrate the generation of the .zip in the Scons/Platform IO framework?

3 Likes