Merge pull request #19 from arendst/development

Change led multiple color sep from dot to space
This commit is contained in:
Adrian 2018-04-01 09:37:13 -03:00 committed by GitHub
commit d6b0680199
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -4,7 +4,7 @@
* Add optional Timer configuration webpage to be enabled in user_config.h with define USE_TIMERS_WEB * Add optional Timer configuration webpage to be enabled in user_config.h with define USE_TIMERS_WEB
* Add Home Assistant MQTT Discovery for Buttons and change SetOption19 response (#2277) * Add Home Assistant MQTT Discovery for Buttons and change SetOption19 response (#2277)
* Add support for SGP30 gas and air quality sensor (#2307) * Add support for SGP30 gas and air quality sensor (#2307)
* Add multiple color entry support for command Led like Led2 120000.001200.000012 setting led2 as Red, Led3 as Green and Led4 as Blue (#2303) * Add multiple color entry support for command Led like Led2 120000 001200 000012 setting led2 as Red, Led3 as Green and Led4 as Blue (#2303)
* Change webpage parameter communication * Change webpage parameter communication
* Change Timer parameter Device to more obvious Output * Change Timer parameter Device to more obvious Output
* Change max number of commands in Backlog from 15 to 30 and ignore commands overflowing * Change max number of commands in Backlog from 15 to 30 and ignore commands overflowing

View File

@ -1116,7 +1116,7 @@ boolean LightCommand()
if (XdrvMailbox.data_len > 0) { if (XdrvMailbox.data_len > 0) {
char *p; char *p;
uint16_t idx = XdrvMailbox.index; uint16_t idx = XdrvMailbox.index;
for (char *color = strtok_r(XdrvMailbox.data, ".", &p); color; color = strtok_r(NULL, ".", &p)) { for (char *color = strtok_r(XdrvMailbox.data, " ", &p); color; color = strtok_r(NULL, " ", &p)) {
if (LightColorEntry(color, strlen(color))) { if (LightColorEntry(color, strlen(color))) {
Ws2812SetColor(idx, light_entry_color[0], light_entry_color[1], light_entry_color[2], light_entry_color[3]); Ws2812SetColor(idx, light_entry_color[0], light_entry_color[1], light_entry_color[2], light_entry_color[3]);
idx++; idx++;