Feather nRF52840 Express - code upload has 20% failure rate

Please tell us which board you are using.
For CircuitPython issues, ask in the Adafruit CircuitPython forum.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
terbos
 
Posts: 11
Joined: Mon Apr 04, 2016 11:51 pm

Feather nRF52840 Express - code upload has 20% failure rate

Post by terbos »

I develop code for the nRF52840 using the Arduino IDE which is fully updated.

When I upload code, the upload works correctly 80% of the time. The other 20%, the upload hangs in the middle and prints a timeout message. After that, the feather is left in a state where it will mount as a flash drive, but it will not run my user code, nor can I simply restart the upload.

I have found that to recover from this state, I have to start the upload from the IDE and then hit the reset button on the feather at exactly the right time to get a successful upload and recovery. Failure to get the timing right puts the Arduino IDE into a state where it takes several minutes to rebuild the entire project (must have invalidated the cache) before I get another shot at the tiny window of opportunity to reset.

What is causing these upload timeouts? Can this be fixed in the bootloader? Aside from this upload issue, the device is fantastic.

Thanks,
Terry

User avatar
adafruit_support_mike
 
Posts: 67485
Joined: Thu Feb 11, 2010 2:51 pm

Re: Feather nRF52840 Express - code upload has 20% failure r

Post by adafruit_support_mike »

That's likely to be a problem with the USB cable.

USB cables are more like components than simple wiring, and they aren't all made the same. Sometimes you'll get one that interacts with the microcontroller in ways that cause unwanted noise.

Try a cable with built-in noise suppression ferrites (the big lump toward one end of the cable) if you have one.

User avatar
hathach
 
Posts: 1271
Joined: Tue Apr 23, 2013 1:02 am

Re: Feather nRF52840 Express - code upload has 20% failure r

Post by hathach »

Try to update bootloader to 0.5 version could help.

Code: Select all

 Update Bootloader with DFU

To upgrade to the latest Bootloader + Softdevice using the serial port within Arduino IDE.

Select Tools > Board > Adafruit Feather nRF52840
Select Tools > Programmer > Bootloader DFU for Bluefruit nRF52
Select Tools > Burn Bootloader
WAIT until the process complete ~30 seconds
Note: close the Serial Monitor before you click "Burn Bootloader". Afterwards, you shouldn't close the Arduino IDE, unplug the Feather, launch Serial Monitor etc ... to abort the process. There is a high chance it will brick your device! Do this with care and caution.

User avatar
terbos
 
Posts: 11
Joined: Mon Apr 04, 2016 11:51 pm

Re: Feather nRF52840 Express - code upload has 20% failure r

Post by terbos »

A bit of a delayed response, but it closes out this topic.

Upgrading to the 0.5 bootloader did fix the problem (or at least make it enough better that it hasn't failed yet).

Thanks for the help.

Locked
Please be positive and constructive with your questions and comments.

Return to “Feather - Adafruit's lightweight platform”