Wierd serial issue with the BLE Sense

Hello everybody,

I bought an Arduino Nano BLE 33 Sense, which I'm trying to get the serial monitor to work.
Sadly, everytime I upload a sketch it says the COM port is busy, after I restart my PC, and upload the sketch again, it uploads succesfully but when I wanna access the serial monitor it says COM port busy. I then need to restart my computer again, to be able to open up the serial port, but it shows no data.

Here is what I tried already;

  • Trying another USB cable.
  • Entering bootloader mode, and uploading the sketch 'bareMinimum', I then upload my sketch, you can find down below (which sometimes also isn't working as the COM port is busy), after which I still can't open the serial port until I restart the PC.
  • Using the online editor, to upload an sketch.

Whatever I try, it keeps saying COM7 port busy. Here is the code I'm trying to upload:

void setup() {
 Serial.begin(9600);
}

void loop() {
  Serial.println("Hello world!");
  delay(500);
}

Does somebody knows what the problem might be? I'm trying all day to get this to work, and its driving me insane.

Edit:
I found the solution, NZXT CAM was using the COM port.
I found it by using the following tutorial: Root Causing Arduino COM Port Busy Error – Michael Bergeron

Thank you to everybody who helped.

The nano33 BLE (and sense) is a bit tricky to program. It actually has two com ports, COM7 and COM6 on my pc.
When I plug it in COM7 comes up (the IDE monitor connection)
but when I program it uses COM6.
Some times things get stuck.
In those case I close the IDE monitor (COM7) when programming and then afterwards I have to reselect it as the com port to open the IDE monitor
If that fails I close the IDE monitor unplug the board and plug it in again and leave the IDE monitor closed.
Double clicking the reset button sometimes solves the problem as well :frowning:

Adding

void setup() {
  Serial.begin(9600);
  for (int i = 10; i > 0; i--) {
    Serial.print(i); Serial.print(' ');
    delay(500);
  }
  Serial.println();

at the top of Setup gives me a few seconds to do the change over.

Which operating system are you using on your computer?

Just FYI, the Arduino Nano 33 BLE and IoT have native USB. The same processor that handles your sketch also handles USB every now and then. If your software does something stupid the USB connection can fail. As drmpf said Double click will set the Arduino into Bootloader mode and you can reprogram your device.

The IDE struggles a bit with these native USB devices. I close all Serial Monitor or Plotter windows before I upload a new sketch and on a bad day I double click the Reset button. And always check the port setting in the IDE before you recompile or very quickly when you started the compilation.

Once you get this into muscle memory it works quite reliably (on Windows 10).

Thanks for your advice!
I've changed my code, and added the code you have described.

When I plugin the board to my PC, it comes up as COM7, when I program the board, it switches to COM6.

I've double clicked the reset button, and switched to COM6, and then uploaded the same sketch with your suggestions in it, the arduino reboots, and switches to COM7 as do I, when I open up the serial monitor, it says;

Error opening serial port 'COM7'. (Port busy)

Even after closing the IDE, unplugging the board, restart the IDE and plugging the board back in it > Error opening serial port 'COM7'. (Port busy)

If I restart my PC, everything works fine, until I close the serial monitor or upload an new sketch. It then comes up with the same error.

Hello Klaus,

I'm using Windows 10 as OS, and I close all the serial and plotter windows before uploading an new sketch. If I double press the reset button to get into the bootloader and select COM6 and upload the sketch, the arduino reboots, and switches to COM7 as do I, when I open up the serial monitor, it says;

Error opening serial port ‘COM7’. (Port busy).

Even after closing the IDE, unplugging the board, restart the IDE and plugging the board back in it > Error opening serial port ‘COM7’. (Port busy)

If I restart my PC, everything works fine, until I close the serial monitor or upload an new sketch. It then comes up with the same error.

Can you check your driver for the COM port? Mine is from Arduino SA, Date: 29.07.2018, Version 10.0.0.0.
Do you get any warning in the properties dialog that could point to an issue?

Hello Klaus,

I found the solution, NZXT CAM was using the COM port.
I found it by using the following tutorial: Root Causing Arduino COM Port Busy Error – Michael Bergeron

Thank you for you help.

3 Likes

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