rusel1989 / react-native-bluetooth-serial

Port of https://github.com/don/BluetoothSerial for react native
475 stars 291 forks source link

Data read from arduino HC05 is always empty #134

Open damodharanj opened 1 year ago

damodharanj commented 1 year ago
BluetoothSerial.withDelimiter('\r\n').then(() => {
          setInterval(() => {
            // BluetoothSerial.readUntilDelimiter("\n").then((v: any) => {
            //   setVal(JSON.stringify(v));
            // })
            BluetoothSerial.available().then((a: any) => {
                setVal(a);
            })
          }, 3000);
        })

The data i read from arduino HC05 is always empty. But bluetooth terminal app shows correct text

CS-Usman commented 9 months ago

Did your problem got solved ? I am also working on HC-05 module need your help

damodharanj commented 9 months ago

You gotta connect to the device before you read. Its a clutch unless you see the example code.