Reads analog A0 AND A2 and transmit them thorugh lora (no encryption)
Dependencies: BufferedSerial SX1276GenericLib mbed
Diff: Transmitter/Transmitter.cpp
- Revision:
- 5:2ac61718bfd8
- Parent:
- 4:182eacdfbf7d
--- a/Transmitter/Transmitter.cpp Wed May 30 14:30:17 2018 +0000 +++ b/Transmitter/Transmitter.cpp Thu May 31 13:13:41 2018 +0000 @@ -211,8 +211,7 @@ while(1){ //ANALOG0 READ AND SEND - readed = analog0.read(); - int t = snprintf(readed_tostr,sizeof(readed_tostr),"ALGG A0:%f A2:%f",analog0.read(),analog2.read()); + int t = snprintf(readed_tostr,sizeof(readed_tostr),"ALGG A0:%f A2:%f",10-analog0.read()*10, (analog2.read()*14.5)-1 ); dprintf("sending:%s",readed_tostr);