Étape 5: Émetteur Software :
#include
#define BT_SERIAL_TX 6
#define BT_SERIAL_RX 7
SoftwareSerial BluetoothSerial(BT_SERIAL_TX, BT_SERIAL_RX) ;
int tempsensor = 0 ;
int val ;
int temp ;
void setup()
{
Serial.Begin(9600) ;
BluetoothSerial.begin(9600) ;
}
void loop()
{
Val = analogRead(tempsensor) ;
Temp = carte (val, 205, 0, 0, 100) ;
BluetoothSerial.print(temp) ;
Delay(100) ;
}
Plus d’informations: lcd température bluetooth