test cli
Dependencies: mbed-os-example-mbed5-lorawan
Fork of Projet_de_bachelor_code by
Diff: main.cpp
- Revision:
- 24:f00666a1be3a
- Parent:
- 23:3dfaed332d89
--- a/main.cpp Fri Jun 08 18:13:32 2018 +0000 +++ b/main.cpp Wed Jun 13 07:03:47 2018 +0000 @@ -107,14 +107,19 @@ int courant , courant_1,courant_2 ; +DigitalOut led(PA_11); int tension_bat; int main (void) { + + /* tension_bat = capteur.vbat_sensor(); MSGtosend[0]=0x07; MSGtosend[1]=0x01; MSGtosend[2]= tension_bat ; + */ + /* courant = capteur.current_sensor(); courant_1 = ((courant) & MSK1) >>0; @@ -125,9 +130,17 @@ MSGtosend[3]=courant_1; */ - /* + pos = capteur.transducer_sensor(); - + if(pos<1600) + { + led = 1; + } + else + { + led = 0; + } + pos_1 = (pos & MSK1) >>0; pos_2 = (pos & MSK2) >>8; @@ -135,7 +148,7 @@ MSGtosend[1]=0x02; MSGtosend[2]=0x00; MSGtosend[3]=pos; - */ + /* QSD_value = qsd.read();