When the upload is successful, I get this on the Arduino console (in the case of 'Blink'):
Code: Select all
Sketch uses 35964 bytes (4%) of program storage space. Maximum is 815104 bytes.
Global variables use 6612 bytes (2%) of dynamic memory, leaving 230956 bytes for local variables. Maximum is 237568 bytes.
Upgrading target on /dev/ttyACM0 with DFU package /tmp/arduino_build_319615/Blink.ino.zip. Flow control is disabled, Single bank, Touch disabled
########################################
################################
Activating new firmware
Device programmed.
Loading pre-compiled UF2 Arduino code directly -- such as UF2 CLUE_TEST.UF2 and CLUE_gifplayer.UF2 -- work fine.
Running Arduino 1.8.12 IDE, running on Linux, with adafruit-nrfutil
I've tried changing the basic example code slightly just to recompile and re-upload to see if it makes any difference, it doesn't seem to (same black screen), when it uploads. More often it results in this error, not sure if it's related, but I'm also getting this constantly:
Code: Select all
Failed to upgrade target. Error is: Serial port could not be opened on /dev/ttyACM0. Reason: [Errno 16] could not open port /dev/ttyACM0: [Errno 16] Device or resource busy: '/dev/ttyACM0'
Traceback (most recent call last):
File "/usr/lib/python3.7/site-packages/serial/serialposix.py", line 265, in open
self.fd = os.open(self.portstr, os.O_RDWR | os.O_NOCTTY | os.O_NONBLOCK)
OSError: [Errno 16] Device or resource busy: '/dev/ttyACM0'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/tlp/.local/lib/python3.7/site-packages/nordicsemi/dfu/dfu_transport_serial.py", line 113, in open
self.serial_port = Serial(port=self.com_port, baudrate=self.baud_rate, rtscts=self.flow_control, timeout=self.timeout)
File "/usr/lib/python3.7/site-packages/serial/serialutil.py", line 240, in __init__
self.open()
File "/usr/lib/python3.7/site-packages/serial/serialposix.py", line 268, in open
raise SerialException(msg.errno, "could not open port {}: {}".format(self._port, msg))
serial.serialutil.SerialException: [Errno 16] could not open port /dev/ttyACM0: [Errno 16] Device or resource busy: '/dev/ttyACM0'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/tlp/.local/lib/python3.7/site-packages/nordicsemi/__main__.py", line 294, in serial
dfu.dfu_send_images()
File "/home/tlp/.local/lib/python3.7/site-packages/nordicsemi/dfu/dfu.py", line 235, in dfu_send_images
self._dfu_send_image(HexType.APPLICATION, self.manifest.application)
File "/home/tlp/.local/lib/python3.7/site-packages/nordicsemi/dfu/dfu.py", line 157, in _dfu_send_image
self.dfu_transport.open()
File "/home/tlp/.local/lib/python3.7/site-packages/nordicsemi/dfu/dfu_transport_serial.py", line 115, in open
raise NordicSemiException("Serial port could not be opened on {0}. Reason: {1}".format(self.com_port, e))
nordicsemi.exceptions.NordicSemiException: Serial port could not be opened on /dev/ttyACM0. Reason: [Errno 16] could not open port /dev/ttyACM0: [Errno 16] Device or resource busy: '/dev/ttyACM0'
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.