commit
1821f39bc1
3 changed files with 5 additions and 4 deletions
|
@ -852,9 +852,7 @@ void webSocketEvent(uint8_t num, WStype_t type, uint8_t * payload, size_t lenght
|
||||||
}
|
}
|
||||||
|
|
||||||
if (root.containsKey("brightness")) {
|
if (root.containsKey("brightness")) {
|
||||||
const char * brightness_json = root["brightness"];
|
brightness = constrain((uint8_t) root["brightness"], 0, 255); //fix #224
|
||||||
uint8_t b = (uint8_t) strtol((const char *) &brightness_json[0], NULL, 10);
|
|
||||||
brightness = constrain(b, 0, 255);
|
|
||||||
mode = BRIGHTNESS;
|
mode = BRIGHTNESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
#define SKETCH_VERSION "2.1.4"
|
#define SKETCH_VERSION "2.1.5"
|
||||||
|
|
|
@ -17,4 +17,7 @@
|
||||||
*
|
*
|
||||||
* 10 Jul 2018 v 2.1.4
|
* 10 Jul 2018 v 2.1.4
|
||||||
* - Fixes measureJson() as pointed in #206
|
* - Fixes measureJson() as pointed in #206
|
||||||
|
*
|
||||||
|
* 2 Oct 2018 v 2.1.5
|
||||||
|
* - Try fixing #224 HA brightness causes reboot
|
||||||
*/
|
*/
|
||||||
|
|
Loading…
Reference in a new issue