Arduino Nano 33 BLE - External Power = No Bluetooth Broadcast

I have a pretty simple program on my Arduino Nano 33 BLE that works properly when connected to my laptop. By "properly" I mean that I can use Lightblue LE or nRF Connect and I can see my Arduino broadcasting as expected.

The issue is whenever I plug the USB into a non-computer source (USB charger, Powerboost 1000C the Arduino no longer shows up in Lightblue LE or nRF Connect. I have looked at the voltages and tried several power supplies that I know work and all produce the same result.

Strange (to me at least). Any ideas why the Bluetooth no longer seems to broadcast when connected to an external power supply?

Thank You

I need to amend my question. I thought it was the external power supply but here's what I've learned. Even when hooked up to my laptop, I need to go open Serial Monitor once before my Arduino will show up in Lightblue LE. Odd. I don't do anything in Serial Monitor, just open it and voila....the Arduino shows up as expected. My setup code is pretty simple and shown below if that helps.

void setup() {

  Serial.begin(115200);    // initialize serial communication

  while (!Serial);

  //Setup BNO055 IMU

  myIMU.begin();

  delay(1000);

  myIMU.setExtCrystalUse(true);

  
  pinMode(LED_BUILTIN, OUTPUT); // initialize the built-in LED pin to indicate when a central is connected

  // begin initialization

  if (!BLE.begin()) {

    // Serial.println("starting BLE failed!");

    while (1);

  }

  /* Set a local name for the BLE device

     This name will appear in advertising packets

     and can be used by remote devices to identify this BLE device

     The name can be changed but maybe be truncated based on space left in advertisement packet

  */

  BLE.setDeviceName( BLE_DEVICE_NAME );

  BLE.setLocalName( BLE_LOCAL_NAME );

  BLE.setAdvertisedService(mainService); // add the service UUID

  
  stringChar.setEventHandler(BLEWritten, writeHandler);

  mainService.addCharacteristic(stringChar); //Add characteristic to test writing 

  mainService.addCharacteristic(stringSensorDataChar); //Write quaternion data as a string for now

  mainService.addCharacteristic(structDataChar); //Characteristic that will send struct.

  

  // Add Descriptors to Improve readability on Blue Tooth Client Side

  BLEDescriptor stringDescriptor("2901", "StringReadWrite");

  stringChar.addDescriptor(stringDescriptor);

  

  BLEDescriptor quaternionDescriptor("2901", "IMU Quaternion & Calibration Data");

  stringSensorDataChar.addDescriptor(quaternionDescriptor);

  BLEDescriptor structdataDescriptor("2901", "IMU Data as a C Struct");

  structDataChar.addDescriptor(structdataDescriptor);

  //Add the Service

  BLE.addService(mainService);

  

  /* Start advertising BLE.  It will start continuously transmitting BLE

     advertising packets and will be visible to remote BLE central devices

     until it receives a new connection */

  // start advertising

  BLE.advertise();

  //Debugging


  // Serial.println("Bluetooth device active, waiting for connections...");

}

Any ideas? I tried commenting out all of the Serial.println() commands but no difference.

Thank You and apologies for the original misleading title.

Try without this line.

while (!Serial);

This line in your code stops the program until you open the serial monitor.

That means, when you don't open the Serial monitor, your program does not sets up until you open it (which isn't possible on an non-computer source).

Delete this line and it will work. :grinning:

1 Like

Ah, you guys are so smart!!!!! Thank you very much....works as expected.

Greatly appreciated.

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