fix api
This commit is contained in:
parent
29e1c1b73a
commit
830d40a777
@ -119,6 +119,5 @@ bool API::sendValue(String val, String poubelleID, String valUnit, bool full){
|
|||||||
this->client->println("Connection: close");
|
this->client->println("Connection: close");
|
||||||
this->client->println();
|
this->client->println();
|
||||||
|
|
||||||
this->token = "";//XXX: on rm le token a chaque fois car on sais pas si la requet a bien aboutie et donc si il y est encore bon
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
@ -33,15 +33,14 @@ void Program::loop(){
|
|||||||
this->screen->printVal(distance, poid, humitemp);
|
this->screen->printVal(distance, poid, humitemp);
|
||||||
|
|
||||||
this->api->sendValue(distance, TRASHCAN_ONE, this->ultrasonic->getValType(), this->ultrasonic->isFull());
|
this->api->sendValue(distance, TRASHCAN_ONE, this->ultrasonic->getValType(), this->ultrasonic->isFull());
|
||||||
Serial.print("Distance in CM = " + distance);
|
|
||||||
Serial.println(this->ultrasonic->isFull()?" true":" false");
|
Serial.println(this->ultrasonic->isFull()?" true":" false");
|
||||||
|
|
||||||
|
Serial.println("humiTemp = " + humitemp);
|
||||||
this->api->sendValue(humitemp, TRASHCAN_TWO, this->dht->getValType(), this->dht->isFull());
|
this->api->sendValue(humitemp, TRASHCAN_TWO, this->dht->getValType(), this->dht->isFull());
|
||||||
Serial.print("humiTemp = " + humitemp);
|
|
||||||
Serial.println(this->dht->isFull()?" true":" false");
|
Serial.println(this->dht->isFull()?" true":" false");
|
||||||
|
|
||||||
|
Serial.println("poid = " + poid);
|
||||||
this->api->sendValue(poid, TRASHCAN_THREE, this->balance->getValType(), this->balance->isFull());
|
this->api->sendValue(poid, TRASHCAN_THREE, this->balance->getValType(), this->balance->isFull());
|
||||||
Serial.print("poid = " + poid);
|
|
||||||
Serial.println(this->balance->isFull()?" true":" false");
|
Serial.println(this->balance->isFull()?" true":" false");
|
||||||
|
|
||||||
Serial.println();
|
Serial.println();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user