Skip to content

NimBLEStreamServer printf printing to USB serial terminal instead of BLE. #1149

Description

@FlyingThings

Slightly edited NimBLE_Stream_Server.
Using Adafruit nrf52840 Express with platform n-able.

Pretty sure this is supposed to print to the BLE connection:

// Using familiar Serial-like methods!
bleStream.print("Hello from BLE Server! Time: ");
bleStream.println(millis());
int heap = 1234;
// You can also use printf
bleStream.printf("Free heap: %d bytes\n", heap);

Serial.println("Sent data to client via BLE stream");

"Free heap" doesn't print to BLE, but instead shows up in the USB serial monitor.

Sent data to client via BLE stream
Free heap: 1234 bytes
Sent data to client via BLE stream
Free heap: 1234 bytes
Sent data to client via BLE stream

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions