How do I send a message to Serial Bluetooth Terminal app

UNO 4 WiFi board (Freenove Version).
moto g8 power lite phone,
IDE 2.3.3.

I have successfully coded to receive codes from the mobile phone but cannot find a way to send messages to the mobile phone.

There are several examples in the Documentation but they concentrate on receiving from the phone but I have only found one example of sending text to the phone. Unfortunately none of them give an example using Kai's app.
(I have found his app to be far more flexible than the recommended app.)

I eventually found the answer after a month of on/off reading the documentation:

BLEService ledService("19B10000-E8F2-537E-4F6C-D104768A1214");  // Bluetooth® Low Energy LED Service
// Bluetooth® Low Energy LED Switch Characteristic - custom 128-bit UUID, read and writable by central
BLECharacteristic switchCharacteristic("19B10001-E8F2-537E-4F6C-D104768A1214", BLERead | BLEWrite | BLENotify | BLEBroadcast, 40);
......
......
    voltagestring = "\nVoltage: " +  String(voltage,4) + "\n"+ String(adcValue) +  "\n";
    int n = voltagestring.length();
    char characteristicValue[n + 1];
    strcpy(characteristicValue, voltagestring.c_str());
    switchCharacteristic.writeValue(characteristicValue, sizeof(characteristicValue));
   

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