minimal changes

This commit is contained in:
MrBesen 2019-03-21 21:19:35 +01:00
parent 03b66fc9ac
commit 0127bd7caf
Signed by: MrBesen
GPG Key ID: 596B2350DCD67504
2 changed files with 10 additions and 9 deletions

View File

@ -38,10 +38,10 @@ void setup() {
}
void reportStatus() {
ser.print("s");
ser.print(statusbits & STATUS_WLAN ? "W" : "w");
ser.print(statusbits & STATUS_SERVICE ? "S" : "s");
ser.print("\0");//EOT
ser.print('s');
ser.print(statusbits & STATUS_WLAN ? 'W' : 'w');
ser.print(statusbits & STATUS_SERVICE ? 'S' : 's');
ser.print('\0');//EOT
}
void setStatus(unsigned char mask, bool newstat) {
@ -62,9 +62,9 @@ void handleSerial() {
if (in == 's') {
reportStatus();
} else if(in == 'r') {//report
//TODO forword to Service
} else if(in == 'a') {
//TODO: forword to Service
}
}
}

View File

@ -36,7 +36,7 @@ void setup() {
delay(1000);
tsensor.begin();
//Serial.begin(115200);//DEBUG
Serial.begin(115200);//DEBUG
wlan.begin(9600);
updateLCD();
@ -122,6 +122,9 @@ void handleWLAN() {
char new_ = ' ';
if (wlan.available() && ava) {
new_ = wlan.read();
Serial.print(new_);
Serial.print(new_, DEC);
Serial.println(new_, HEX);
if (new_ == '\0') {
ava = false;
new_ = ' ';
@ -212,5 +215,3 @@ void setheater(bool on) {
digitalWrite(13, on);
lcdchanged = true;
}