Go Down

Topic: Show Sensor Value on Android (App Inventor) (Read 1 time) previous topic - next topic


Hi, guys. I'm a brazilian user, so forgive my english. I have an Arduino UNO R3 with a Gas Methane MQ-4 sensor and a bluetooth module. I developed a app to turn on and off a LED. I configured the Arduino code with SoftwareSerial, set the RX and TX pins and it work. The wire connections is good.
After i built a app to show the sensor value. I tested the sensor in the Serial Monitor and it showed the value. So i just changed the "Serial.println" to "bluetooth.println". But don't work. The app freeze and the most strange is: when i turn off the Arduino, the app say that the connection was interrupted and just there show the sensor values on background screen. Sugestions?


Arduino Code


this might not be very helpful...but why don't you try "blue.print(Valor_Gas)"  since i'm understanding "Valor_Gas" is the variable that has the data of the sensor read.

and i'm not sure if the right command is .print or .write when using bluetooth


Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131