This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

pca10059, replacing stock bootloader with Adafruit UF2, using USB dfua signature. I can generate a zip file with nrfutil, but what key should I use? I tried to use just a private key, and flash that generated packet with nrfutil, but nrfutil crashes when I

pca10059, replacing stock bootloader with Adafruit UF2, using USB dfu

Hi. I currently don't have a J-Link at hand, so I tried to flash the UF2 bootloader using the stock DFU bootloader over USB. nRF Connect can flash an application to the dongle, but when trying to overwrite the bootloader, it complains that the init packet does not contain a signature. I can generate a zip file with nrfutil, but what key should I use? I tried to use just a private key, and flash that generated packet with nrfutil, but nrfutil crashes when I try to flash it.
Any help?
Link to Adafruit bootloader is: github.com/.../Adafruit_nRF52_Bootloader

  • Hung,

    I already imagined, that you signed the bootloader to prevent accidential overwriting.

    But:

    - It would've been nice if you told us that in the documentation

    - it would've been even nicer if you gave us the key

    Don't get me wrong, It's very kind of you to sell this dongle at that incredibly low price. I bought 5 of them, because I'm a hardware guy, and connect lots of things to microcontrollers, so I break some here and there. At that price, I don't even bother replacing a damaged micro.

    I have a ton of different programmers and debuggers here, but unfortunately no J-Link (yet).

    I might buy a nRF52 DK, if I keep developing for nRF52. I could also use an OpenOCD programmer, like the BlackMagicProbe, to flash the bootloder, but for that I would have to dig into the memory layout of the nRF52840 in detail, and I just didn't have the time for this.

    But, there are a lot of people that are just starting into the world of microcontrollers, and can afford a nRF52840 dongle, but not a J-Link programmer. This dongle is, just to name an example, a good device to start with Micropython or Circuitpython.

    And it would be even better, if beginners without a programmer could replace the bootloader.

    But nevermind, thanks for your effort, and have a nice day.

  • I see your point. But in my opinion it's worth it to get a nRF52DK. You have full GPIO, NFC, LED to play with. And please be aware that you can use the nRF52DK as a Jlink programmer to flash the dongle. 

    You can get the nRF52DK as low as $39. 

  • You're right.

    I wasn't planning on buying one, because I thought that I would mostly play around with micropython, and only a little bit of C, but it now seems that I have to fully dive into SDK and bootloader development, so I folded and ordered one.

    I already had ordered a full J-Link, because I always wanted one.

  • Yeah, I think you are on the right track. Let us know (by creating new question) if you have any problem. 

    Happy coding :) 

Related