Why do I keep bricking my Nano 33 BLEs?

Hi!

During the course of the last week, I bricked two Nano 33 BLEs.

The first one stopped responding when I was using Visual Studio Code to develop, and opened the serial monitor while uploading the sketch. Programming stopped, and the device never responded thereafter. On closer examination, it was rapidly connecting and disconnecting as a USB device with my Linux OS.
I then used my MKR Zero and the DAP library to flash the bootloader. After that, at least I now have a USB device with the correct name (Nano 33 BLE) again, but uploading a sketch still fails with "No device found". So that was only half a fix.

I then switched to a second device, but that also didn't last long. As a precaution, I had stopped using VS Code for my Arduino work and switched to arduino 1.8.13. I'm not 100% certain what happened this time, but in the end, I'm left with a device that once more quickly disconnects from USB.

The system log says

usb 1-5.3: new full-speed USB device number 120 using xhci_hcd

usb 1-5.3: Device not responding to setup address.

usb 1-5.3: device not accepting address 120, error -71

usb 1-5.3: new full-speed USB device number 121 using xhci_hcd

usb 1-5.3: New USB device found, idVendor=2341, idProduct=005a, bcdDevice= 0.11

usb 1-5.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3

usb 1-5.3: Product: Arduino Nano 33 BLE

cdc_acm 1-5.3:1.0: ttyACM0: USB ACM device

usb 1-5.3: USB disconnect, device number 121

within less than a second.

I don't have access to the MKR Zero right now, so I didn't try uploading the bootloader to the second device, yet. But bricking two devices to quickly gave me enough concern already to post here.

For uploading the bootloader, I'm using the program() method of the Adafruit_DAP_nRF5x class. It takes some three seconds and no errors are reported. The file I'm uploading is packages/arduino/hardware/mbed/1.3.2/bootloaders/nano33ble/bootloader.bin
to address 0. Since the situation with the first device at least improved, that can't be too wrong…

When just uploading the bootloaded didn't work, I added calls to programUICR for the UICR_BOOTLOADER and UICR_MBR_PARAM_PAGE addresses as seen in other upload routines. This led to no observable changes.

So the obvious questions I have:

Why is this happening so often?
How do I fix it for good?

Michael

If you press and releasing the reset button on your bricked and semi-bricked boards quickly twice, do you then see the “L” LED pulsing?

For uploading the bootloader, I'm using the program() method of the Adafruit_DAP_nRF5x class. It takes some three seconds and no errors are reported. The file I'm uploading is packages/arduino/hardware/mbed/1.3.2/bootloaders/nano33ble/bootloader.bin
to address 0. Since the situation with the first device at least improved, that can't be too wrong…

Thanks for sharing this information. I have been meaning to do an investigation into using the Adafruit_DAP library with the Nano 33 BLE. I often recommend it for the SAMD boards, but it's not clear from the Adafruit documentation and code whether the library's support for the nRF5x chips was ever finalized. It would certainly be nice to have an "Arduino as ISP" equivalent for the Nano 33 BLE boards as well!

pert:
If you press and releasing the reset button on your bricked and semi-bricked boards quickly twice, do you then see the “L” LED pulsing?

Right, I should have mentioned this: Yes, it does make a small difference. When I press the button twice really quick, I do get a "Bus 001 Device 018: ID 2341:005a Arduino SA" device, and also /dev/ttyACM0. But uploading is still not possible: "No device found on ttyACM0
An error occurred while uploading the sketch"
The orange LED is slowly fading in and out in this mode.

Are there any recommendations how to proceed from here?

My initial plan was to dump the memory content of the second device to identify differences that might be important. Now that the second device failed so soon, I can no longer do this myself. Would anybody be willing to send me a memory readback via SWD? I'm not sure how to access the UICR register for readback, though. Given that I just uploaded the bootloader, I consider this a likely location of the problem.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.