I've attached sensor to RFDuino and want to send readings over BLE to Android app.
const int sensorPin = 2;
int sensorValue = 0;
void setup() {
Serial.begin(9600);
RFduinoBLE.begin();
}
void loop() {
sensorValue = analogRead(sensorPin);
float voltage= sensorValue * (3.3 / 1023.0);
Serial.print("uv sensor = ");
Serial.println(voltage);
RFduinoBLE.sendFloat(voltage);
delay(1000);
}
In console I see values like 0.2
. But in app it translates to something like 00-00-A4-41
It's described here but I don't get what's the logic behind it. How do I properly convert the value sent from RFDuino?