Add logic to test for tempreture
This commit is contained in:
parent
bade5afa40
commit
1b60d35130
@ -1,4 +1,4 @@
|
||||
const int tmp_aufw =9;
|
||||
2212const int tmp_aufw =9;
|
||||
const int tmp_abw =10;
|
||||
|
||||
const int tmp_sens = A7;
|
||||
@ -42,16 +42,20 @@ void kaelter(){
|
||||
|
||||
void loop() {
|
||||
Serial.println(analogRead(tmp_sens));
|
||||
kaelter();
|
||||
//kaelter();
|
||||
delay(1000);
|
||||
//warmer();
|
||||
|
||||
if(analogRead(tmp_sens) > ){
|
||||
|
||||
}else if(analogRead(tmp_sens) >){
|
||||
|
||||
if(analogRead(tmp_sens) > 152 ){ // 12°C
|
||||
warmer();
|
||||
Serial.println("To Cold -> Warmer");
|
||||
}else if(analogRead(tmp_sens) < 150 ){ // 14°C
|
||||
kaelter();
|
||||
Serial.println("To warm -> Colder");
|
||||
} else{
|
||||
Serial.println("Wihin Margen");
|
||||
|
||||
}
|
||||
delay(1000);
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user