Hi, i made a project with an ESP32 WROOM 32D, the esp32 read the value of a sensor connected on one pin and then sends the data via bluetooth to an app created on app inventor with the bluetooth serial, but now i want to use the xiao nrf52840 because is smaller, but the problem is that i can´t make the xiao display on the bluetooth devices list of the android smartphone and i need it to connect it to the app, any ideas or examples of how can i do that? i tried a lot of codes and libraries but i failed, this is my code:
#include <BluetoothSerial.h>
BluetoothSerial SerialBT;
const int ledpin=2;
void setup() {
Serial.begin(115200);
pinMode(ledpin, OUTPUT);
SerialBT.begin("ESP32"); // Nombre del dispositivo Bluetooth
pinMode(34, INPUT); // Sensor conectado al pin 34
}
void loop() {
bool sensorValue = analogRead(34) < 2500;
SerialBT.println(sensorValue);
Serial.print(analogRead(34));
Serial.println("");
if (analogRead(34) < 2000.) {
digitalWrite(ledpin, HIGH); // Enciende el LED
} else {
digitalWrite(ledpin, LOW); // Apaga el LED
}
delay(1000);
}
`