Luminosite fonctionnelle
This commit is contained in:
parent
7c8c1d204d
commit
5922e4e7b5
4 changed files with 25 additions and 25 deletions
|
@ -63,16 +63,16 @@ void IntelligentDigitalActuatorLED::run(){
|
|||
if (state==LOW ){
|
||||
cout << "((((eteint))))\n";
|
||||
if(state != previousState){
|
||||
//AnalogSensorLuminosity::luminosite_environnement-= 50;
|
||||
luminosite_environnement-= 50;
|
||||
}
|
||||
previousState = LOW;
|
||||
previousState = state;
|
||||
}
|
||||
else{ //state == HIGH
|
||||
cout << "((((allume))))\n";
|
||||
if(state != previousState){
|
||||
//AnalogSensorLuminosity::luminosite_environnement+= 50;
|
||||
luminosite_environnement+= 50;
|
||||
}
|
||||
previousState = HIGH;
|
||||
previousState = state;
|
||||
}
|
||||
sleep(temps);
|
||||
}
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
#include <string.h>
|
||||
#include "core_simulation.h"
|
||||
|
||||
int luminosite_environnement = 200;
|
||||
static int luminosite_environnement = 200;
|
||||
|
||||
|
||||
// exemple de capteur analogique de temperature, ne pas oublier d'heriter de Device
|
||||
|
|
Loading…
Reference in a new issue