0

Cannot 'Upload' sketch from Arduino IDE to nRF52832 feather
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Cannot 'Upload' sketch from Arduino IDE to nRF52832 feather

by walkabout on Fri Jul 09, 2021 5:43 am

Initially in the win10 device mgr I see:
Silicon Labs CP210x USB to UART Bridge (COM4) under Ports category, and it states this device is working correctly.

Arduino IDE is pointing to COM4, Board selected is Adafruit Feather nRF52832

When try to upload... no errors, but see the following (pasted below). Red and blue LEDS on Feather toggling on/off. Eventually win10 throws an error USB device not recognized.

Ideas? Thanks...

Sketch uses 36292 bytes (12%) of program storage space. Maximum is 290816 bytes.
Global variables use 3592 bytes (6%) of dynamic memory, leaving 48632 bytes for local variables. Maximum is 52224 bytes.
C:\Users\bkell\AppData\Local\Arduino15\packages\adafruit\hardware\nrf52\0.24.0/tools/adafruit-nrfutil/win32/adafruit-nrfutil.exe --verbose dfu serial -pkg C:\Users\bkell\AppData\Local\Temp\arduino_build_891289/display_oled_test1.ino.zip -p COM4 -b 115200 --singlebank
Upgrading target on COM4 with DFU package C:\Users\bkell\AppData\Local\Temp\arduino_build_891289\display_oled_test1.ino.zip. Flow control is disabled, Single bank, Touch disabled
Opened serial port COM4
Starting DFU upgrade of type 4, SoftDevice size: 0, bootloader size: 0, application size: 36300
Sending DFU start packet
Sending DFU init packet
Timed out waiting for acknowledgement from device.
Sending firmware file

Failed to upgrade target. Error is: Attempting to use a port that is not open
Traceback (most recent call last):
File "__main__.py", line 296, in serial
File "dfu\dfu.py", line 235, in dfu_send_images
File "dfu\dfu.py", line 206, in _dfu_send_image
File "dfu\dfu_transport_serial.py", line 213, in send_firmware
File "dfu\dfu_transport_serial.py", line 241, in send_packet
File "serial\serialwin32.py", line 306, in write
serial.serialutil.PortNotOpenError: Attempting to use a port that is not open

Possible causes:
- Selected Bootloader version does not match the one on Bluefruit device.
Please upgrade the Bootloader or select correct version in Tools->Bootloader.
- Baud rate must be 115200, Flow control must be off.
- Target is not in DFU mode. Ground DFU pin and RESET and release both to enter DFU mode.
walkabout
 
Posts: 18
Joined: Tue Nov 12, 2013 5:47 am

Re: Cannot 'Upload' sketch from Arduino IDE to nRF52832 feat

by mikeysklar on Fri Jul 09, 2021 5:23 pm

This error looks related to our FAQ entry. You might need to update the bootloader. Before doing so I would also try to attempt an upload with the 'reset' button being pressed just before hitting the upload button in the Arduino IDE.

https://learn.adafruit.com/bluefruit-nr ... aq-3026483

what should I do when Arduino failed to upload sketch to my Feather ?
If you get this error:
Timed out waiting for acknowledgement from device.

Failed to upgrade target. Error is: No data received on serial port. Not able to proceed.
Traceback (most recent call last):
File "nordicsemi\__main__.py", line 294, in serial
File "nordicsemi\dfu\dfu.py", line 235, in dfu_send_images
File "nordicsemi\dfu\dfu.py", line 203, in _dfu_send_image
File "nordicsemi\dfu\dfu_transport_serial.py", line 155, in send_init_packet
File "nordicsemi\dfu\dfu_transport_serial.py", line 243, in send_packet
File "nordicsemi\dfu\dfu_transport_serial.py", line 282, in get_ack_nr
nordicsemi.exceptions.NordicSemiException: No data received on serial port. Not able to proceed.
This is probably caused by the bootloader version mismatched on your feather and installed BSP. Due to the difference in flash layout (more details) and Softdevice API (which is bundled with bootloader), sketch built with selected bootloader can only upload to board having the same version. In short, you need to upgrade/burn bootloader to match on your Feather, follow above Update The Bootloader guide
It only has to be done once to update your Feather

mikeysklar
 
Posts: 5483
Joined: Mon Aug 01, 2016 8:10 pm

Re: Cannot 'Upload' sketch from Arduino IDE to nRF52832 feat

by walkabout on Sun Aug 01, 2021 7:57 pm

Sorry for my delay of response, was on vacation:

It was said:
Before doing so I would also try to attempt an upload with the 'reset' button being pressed just before hitting the upload button in the Arduino IDE.

Indeed I did this... about a bazillion times. I have 4 different Feathers where model numbers are:
Adafruit Feather nRF52832
Adafruit Feather STM32F405
Adafruit Feather HUZZAH ESP8266
etc.

And NONE of them work... I have followed Adafruit's posted instructions. And in some cases drivers appear to be dated, if not obsolete. This has not been a good experience.

So not knowing what else to do at this point, I'll try to upload the bootloader on this new Feather I just received (why is this necessary?), but I'm kinda frustrated and about to mail them all back to Adafruit and request a refund.

Thanks...
walkabout
 
Posts: 18
Joined: Tue Nov 12, 2013 5:47 am

Re: Cannot 'Upload' sketch from Arduino IDE to nRF52832 feat

by mikeysklar on Mon Aug 02, 2021 7:01 pm

@walkabout,

Do you have any controllers that are currently working with your Win10 machine over USB?

Three significantly models not working sounds more like a USB port or cable issue. Can you describe you USB setup further (USB2 vs USB3, connector/adapters, hubs, monitor or keyboard USB, etc.)?

If we could focus on the Feather nRF52832 and not the other two controllers for this thread that will make be easier to diagnose the cause of failure.

Please let us know if bootloader upgrade resolves this for you and what version was installed.

mikeysklar
 
Posts: 5483
Joined: Mon Aug 01, 2016 8:10 pm

Please be positive and constructive with your questions and comments.