Merge branch '0_14' of https://github.com/Aircoookie/WLED into dev
This commit is contained in:
commit
bfe16bb254
@ -264,6 +264,7 @@ board_build.ldscript = ${common.ldscript_4m1m}
|
||||
build_unflags = ${common.build_unflags}
|
||||
build_flags = ${common.build_flags_esp8266} -D WLED_RELEASE_NAME=ESP8266
|
||||
lib_deps = ${esp8266.lib_deps}
|
||||
monitor_filters = esp8266_exception_decoder
|
||||
|
||||
[env:esp8266_2m]
|
||||
board = esp_wroom_02
|
||||
|
@ -653,8 +653,8 @@ function populateInfo(i)
|
||||
}
|
||||
}
|
||||
var vcn = "Kuuhaku";
|
||||
if (i.ver.startsWith("0.13.")) vcn = "Toki";
|
||||
if (i.ver.includes("-bl")) vcn = "Ryujin";
|
||||
if (i.ver.startsWith("0.14.")) vcn = "Hoshi";
|
||||
if (i.ver.includes("-bl")) vcn = "Supāku";
|
||||
if (i.cn) vcn = i.cn;
|
||||
|
||||
cn += `v${i.ver} "${vcn}"<br><br><table>
|
||||
|
@ -505,8 +505,8 @@ function populateInfo(i)
|
||||
}
|
||||
}
|
||||
var vcn = "Kuuhaku";
|
||||
if (i.ver.startsWith("0.13.")) vcn = "Toki";
|
||||
if (i.ver.includes("-bl")) vcn = "Ryujin";
|
||||
if (i.ver.startsWith("0.14.")) vcn = "Hoshi";
|
||||
if (i.ver.includes("-bl")) vcn = "Supāku";
|
||||
if (i.cn) vcn = i.cn;
|
||||
|
||||
cn += `v${i.ver} "${vcn}"<br><br><table>
|
||||
|
1498
wled00/html_other.h
1498
wled00/html_other.h
File diff suppressed because it is too large
Load Diff
@ -8,7 +8,7 @@
|
||||
// Autogenerated from wled00/data/style.css, do not edit!!
|
||||
const uint16_t PAGE_settingsCss_length = 824;
|
||||
const uint8_t PAGE_settingsCss[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xad, 0x55, 0x5d, 0x8b, 0x9c, 0x30,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0xad, 0x55, 0x5d, 0x8b, 0x9c, 0x30,
|
||||
0x14, 0xfd, 0x2b, 0x96, 0x61, 0x61, 0x0b, 0xa3, 0xa8, 0xa3, 0xb3, 0xd3, 0x48, 0xa1, 0xf4, 0xbd,
|
||||
0x6f, 0xa5, 0x14, 0xca, 0x3e, 0x44, 0x73, 0x1d, 0xc3, 0xe4, 0x43, 0x92, 0xd8, 0x75, 0x2a, 0xfe,
|
||||
0xf7, 0x26, 0x7e, 0xac, 0xce, 0xac, 0x6c, 0x5f, 0xca, 0xe0, 0xa0, 0xde, 0x98, 0x7b, 0xee, 0xb9,
|
||||
@ -66,7 +66,7 @@ const uint8_t PAGE_settingsCss[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_length = 985;
|
||||
const uint8_t PAGE_settings[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xad, 0x56, 0x6d, 0x6f, 0xdb, 0x36,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0xad, 0x56, 0x6d, 0x6f, 0xdb, 0x36,
|
||||
0x10, 0xfe, 0xee, 0x5f, 0xc1, 0xb0, 0x58, 0x23, 0xa1, 0xb2, 0xec, 0x38, 0xc3, 0xb0, 0xc9, 0x96,
|
||||
0x8b, 0x35, 0x2f, 0x9d, 0x87, 0x04, 0x0d, 0x90, 0xa4, 0xdd, 0x80, 0x7d, 0xa1, 0xc9, 0x93, 0xcc,
|
||||
0x46, 0x22, 0x05, 0xf2, 0xe4, 0xc4, 0x73, 0xf3, 0xdf, 0x77, 0x94, 0x9d, 0xb7, 0x36, 0xd8, 0x8a,
|
||||
@ -134,7 +134,7 @@ const uint8_t PAGE_settings[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_wifi.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_wifi_length = 1557;
|
||||
const uint8_t PAGE_settings_wifi[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xad, 0x57, 0xff, 0x4f, 0xdb, 0x38,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0xad, 0x57, 0xff, 0x4f, 0xdb, 0x38,
|
||||
0x14, 0xff, 0x3d, 0x7f, 0x85, 0xf1, 0x49, 0x53, 0xa3, 0x85, 0x94, 0xb6, 0xc7, 0x6e, 0x62, 0x49,
|
||||
0x76, 0x5d, 0xdb, 0x0d, 0xee, 0x18, 0xeb, 0x29, 0x68, 0xe8, 0xa4, 0x93, 0x26, 0x37, 0x79, 0x6d,
|
||||
0x3d, 0x9c, 0x38, 0x17, 0x3b, 0x2d, 0x88, 0xf1, 0xbf, 0xdf, 0xb3, 0x93, 0x96, 0x16, 0xe8, 0x36,
|
||||
@ -238,7 +238,7 @@ const uint8_t PAGE_settings_wifi[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_leds.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_leds_length = 7357;
|
||||
const uint8_t PAGE_settings_leds[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xdd, 0x3c, 0xed, 0x76, 0xe2, 0xc6,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0xdd, 0x3c, 0xed, 0x76, 0xe2, 0xc6,
|
||||
0x92, 0xff, 0x79, 0x8a, 0x76, 0x27, 0x71, 0xa4, 0x8b, 0x0c, 0x12, 0x1f, 0x8e, 0x07, 0x10, 0xac,
|
||||
0xb1, 0x3d, 0x13, 0xdf, 0x6b, 0xc7, 0x3e, 0xc6, 0xc9, 0xdc, 0x3d, 0x93, 0x39, 0x19, 0x21, 0x1a,
|
||||
0xd0, 0x58, 0x48, 0xba, 0x92, 0xb0, 0x87, 0xb5, 0xd9, 0x67, 0xda, 0x67, 0xd8, 0x27, 0xdb, 0xaa,
|
||||
@ -704,7 +704,7 @@ const uint8_t PAGE_settings_leds[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_dmx.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_dmx_length = 1612;
|
||||
const uint8_t PAGE_settings_dmx[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0x95, 0x57, 0xdb, 0x72, 0xdb, 0x36,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0x95, 0x57, 0xdb, 0x72, 0xdb, 0x36,
|
||||
0x10, 0x7d, 0xd7, 0x57, 0x20, 0x78, 0x88, 0xc9, 0x31, 0x43, 0x4a, 0x4e, 0x95, 0x36, 0x32, 0x49,
|
||||
0x37, 0x56, 0x5c, 0xdb, 0x1d, 0xdb, 0xf5, 0x44, 0x49, 0xd3, 0x4e, 0xd3, 0xe9, 0x40, 0xe4, 0x4a,
|
||||
0x44, 0x4c, 0x02, 0x2c, 0x00, 0x4a, 0x76, 0x2e, 0xff, 0xde, 0x05, 0x48, 0x5d, 0xec, 0xd8, 0x69,
|
||||
@ -811,7 +811,7 @@ const uint8_t PAGE_settings_dmx[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_ui.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_ui_length = 3090;
|
||||
const uint8_t PAGE_settings_ui[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xad, 0x59, 0x6b, 0x73, 0xda, 0x48,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0xad, 0x59, 0x6b, 0x73, 0xda, 0x48,
|
||||
0x16, 0xfd, 0xce, 0xaf, 0xe8, 0x74, 0x52, 0x1e, 0x54, 0x56, 0x04, 0x4e, 0x66, 0x6b, 0x13, 0x40,
|
||||
0x78, 0x63, 0xc7, 0x93, 0x78, 0xca, 0xd9, 0x64, 0x83, 0xbd, 0x99, 0xad, 0xac, 0xcb, 0x23, 0xa4,
|
||||
0x06, 0x3a, 0x16, 0x92, 0x46, 0xdd, 0x32, 0x66, 0x09, 0xff, 0x7d, 0xcf, 0xed, 0x96, 0x40, 0x60,
|
||||
@ -1011,7 +1011,7 @@ const uint8_t PAGE_settings_ui[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_sync.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_sync_length = 3153;
|
||||
const uint8_t PAGE_settings_sync[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0x9d, 0x5a, 0x6d, 0x77, 0xda, 0xb8,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0x9d, 0x5a, 0x6d, 0x77, 0xda, 0xb8,
|
||||
0x12, 0xfe, 0xee, 0x5f, 0xa1, 0xf8, 0xc3, 0x2e, 0x6c, 0x08, 0x18, 0x12, 0xd2, 0x94, 0x62, 0xf7,
|
||||
0x86, 0x90, 0x26, 0xec, 0x36, 0x0d, 0x85, 0x64, 0x5f, 0xce, 0xb9, 0xe7, 0xec, 0x11, 0xb6, 0x00,
|
||||
0x25, 0xb6, 0xe5, 0xb5, 0xe5, 0xbc, 0x9c, 0x6e, 0xff, 0xfb, 0x9d, 0x91, 0x6c, 0x03, 0x06, 0x02,
|
||||
@ -1215,7 +1215,7 @@ const uint8_t PAGE_settings_sync[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_time.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_time_length = 3302;
|
||||
const uint8_t PAGE_settings_time[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xd5, 0x1a, 0x6b, 0x57, 0xdb, 0x3a,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0xd5, 0x1a, 0x6b, 0x57, 0xdb, 0x3a,
|
||||
0xf2, 0x7b, 0x7e, 0x85, 0x50, 0x7b, 0xb8, 0xf1, 0xc5, 0x79, 0x42, 0x5a, 0x48, 0x62, 0x77, 0x43,
|
||||
0x48, 0x0b, 0x2d, 0x09, 0x9c, 0x26, 0xbd, 0xec, 0xf6, 0x71, 0x6e, 0x15, 0x5b, 0x49, 0x0c, 0x8e,
|
||||
0xe4, 0xb5, 0x65, 0x02, 0x4b, 0xf9, 0xef, 0x3b, 0x92, 0x1c, 0xe7, 0x85, 0x81, 0xf6, 0xde, 0xfd,
|
||||
@ -1428,7 +1428,7 @@ const uint8_t PAGE_settings_time[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_sec.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_sec_length = 2406;
|
||||
const uint8_t PAGE_settings_sec[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xa5, 0x58, 0x6d, 0x53, 0xdb, 0x48,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0xa5, 0x58, 0x6d, 0x53, 0xdb, 0x48,
|
||||
0x12, 0xfe, 0xee, 0x5f, 0x31, 0x4c, 0xaa, 0x58, 0xeb, 0x22, 0x2c, 0x43, 0x72, 0x5b, 0x09, 0x20,
|
||||
0xe7, 0x20, 0x90, 0x0d, 0x57, 0x10, 0x28, 0x6c, 0x36, 0x77, 0x95, 0x4b, 0xa5, 0xc6, 0xd2, 0xd8,
|
||||
0x9a, 0x58, 0xd6, 0x68, 0x67, 0x46, 0x38, 0xbe, 0xec, 0xfe, 0xf7, 0x7b, 0x7a, 0x24, 0xd9, 0x86,
|
||||
@ -1585,7 +1585,7 @@ const uint8_t PAGE_settings_sec[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_um.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_um_length = 2514;
|
||||
const uint8_t PAGE_settings_um[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0xdd, 0x58, 0xdb, 0x72, 0xdb, 0x38,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0xdd, 0x58, 0xdb, 0x72, 0xdb, 0x38,
|
||||
0x12, 0x7d, 0xd7, 0x57, 0xd0, 0x88, 0xcb, 0x26, 0x4b, 0x34, 0x25, 0xc7, 0x3b, 0xb3, 0x89, 0x24,
|
||||
0xc8, 0x93, 0x38, 0xc9, 0x44, 0x9b, 0x8b, 0x5d, 0xa5, 0xb9, 0xd4, 0x96, 0xd7, 0x35, 0xa6, 0x44,
|
||||
0x48, 0x42, 0x4c, 0x81, 0x5c, 0x00, 0xf4, 0x65, 0x65, 0xfd, 0xfb, 0x9e, 0x06, 0x49, 0x5d, 0x1c,
|
||||
@ -1749,7 +1749,7 @@ const uint8_t PAGE_settings_um[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_2D.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_2D_length = 1754;
|
||||
const uint8_t PAGE_settings_2D[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0x8d, 0x58, 0x6d, 0x73, 0xdb, 0x36,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0x8d, 0x58, 0x6d, 0x73, 0xdb, 0x36,
|
||||
0x12, 0xfe, 0xce, 0x5f, 0x01, 0x63, 0x3a, 0x2d, 0xd9, 0x50, 0x94, 0xe4, 0xde, 0x75, 0x3a, 0x16,
|
||||
0x49, 0x37, 0x6e, 0xdc, 0xda, 0x1d, 0x7b, 0xe2, 0x89, 0x72, 0xce, 0xdc, 0x5c, 0x3a, 0x29, 0x44,
|
||||
0xae, 0x44, 0xc4, 0x24, 0xc0, 0x01, 0x20, 0xd9, 0xae, 0xe2, 0xff, 0x7e, 0x0b, 0x90, 0x12, 0x25,
|
||||
@ -1865,7 +1865,7 @@ const uint8_t PAGE_settings_2D[] PROGMEM = {
|
||||
// Autogenerated from wled00/data/settings_pin.htm, do not edit!!
|
||||
const uint16_t PAGE_settings_pin_length = 471;
|
||||
const uint8_t PAGE_settings_pin[] PROGMEM = {
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x13, 0x5d, 0x52, 0x4d, 0x6f, 0x13, 0x31,
|
||||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x0a, 0x5d, 0x52, 0x4d, 0x6f, 0x13, 0x31,
|
||||
0x10, 0xbd, 0xef, 0xaf, 0x30, 0x73, 0x69, 0x82, 0x92, 0x6c, 0xa8, 0xa8, 0x04, 0xaa, 0xbd, 0x42,
|
||||
0x81, 0x1e, 0xb8, 0x94, 0x48, 0xe5, 0x52, 0x55, 0x55, 0xe5, 0xd8, 0xb3, 0x89, 0x55, 0x7f, 0x2c,
|
||||
0xb6, 0x37, 0x21, 0x54, 0xfc, 0x77, 0xc6, 0xbb, 0xa1, 0xa0, 0x5c, 0xd6, 0x7e, 0x33, 0xe3, 0x37,
|
||||
|
2241
wled00/html_simple.h
2241
wled00/html_simple.h
File diff suppressed because it is too large
Load Diff
3718
wled00/html_ui.h
3718
wled00/html_ui.h
File diff suppressed because it is too large
Load Diff
111
wled00/json.cpp
111
wled00/json.cpp
@ -79,8 +79,8 @@ void deserializeSegment(JsonObject elem, byte it, byte presetId)
|
||||
uint16_t grp = elem["grp"] | seg.grouping;
|
||||
uint16_t spc = elem[F("spc")] | seg.spacing;
|
||||
uint16_t of = seg.offset;
|
||||
uint8_t soundSim = elem[F("ssim")] | seg.soundSim;
|
||||
uint8_t map1D2D = elem[F("mp12")] | seg.map1D2D;
|
||||
uint8_t soundSim = elem["ssim"] | seg.soundSim;
|
||||
uint8_t map1D2D = elem["mp12"] | seg.map1D2D;
|
||||
|
||||
if ((spc>0 && spc!=seg.spacing) || seg.map1D2D!=map1D2D) seg.fill(BLACK); // clear spacing gaps
|
||||
|
||||
@ -162,12 +162,12 @@ void deserializeSegment(JsonObject elem, byte it, byte presetId)
|
||||
}
|
||||
#endif
|
||||
|
||||
seg.selected = elem["sel"] | seg.selected;
|
||||
seg.reverse = elem["rev"] | seg.reverse;
|
||||
seg.mirror = elem[F("mi")] | seg.mirror;
|
||||
seg.selected = elem["sel"] | seg.selected;
|
||||
seg.reverse = elem["rev"] | seg.reverse;
|
||||
seg.mirror = elem["mi"] | seg.mirror;
|
||||
#ifndef WLED_DISABLE_2D
|
||||
seg.reverse_y = elem[F("rY")] | seg.reverse_y;
|
||||
seg.mirror_y = elem[F("mY")] | seg.mirror_y;
|
||||
seg.reverse_y = elem["rY"] | seg.reverse_y;
|
||||
seg.mirror_y = elem["mY"] | seg.mirror_y;
|
||||
seg.transpose = elem[F("tp")] | seg.transpose;
|
||||
#endif
|
||||
|
||||
@ -185,17 +185,17 @@ void deserializeSegment(JsonObject elem, byte it, byte presetId)
|
||||
if (elem[F("fxdef")])
|
||||
{
|
||||
int16_t sOpt;
|
||||
sOpt = extractModeDefaults(fx, SET_F("sx")); if (sOpt >= 0) seg.speed = sOpt;
|
||||
sOpt = extractModeDefaults(fx, SET_F("ix")); if (sOpt >= 0) seg.intensity = sOpt;
|
||||
sOpt = extractModeDefaults(fx, SET_F("c1")); if (sOpt >= 0) seg.custom1 = sOpt;
|
||||
sOpt = extractModeDefaults(fx, SET_F("c2")); if (sOpt >= 0) seg.custom2 = sOpt;
|
||||
sOpt = extractModeDefaults(fx, SET_F("c3")); if (sOpt >= 0) seg.custom3 = sOpt;
|
||||
sOpt = extractModeDefaults(fx, SET_F("mp12")); if (sOpt >= 0) seg.map1D2D = sOpt & 0x07;
|
||||
sOpt = extractModeDefaults(fx, SET_F("ssim")); if (sOpt >= 0) seg.soundSim = sOpt & 0x03;
|
||||
sOpt = extractModeDefaults(fx, "rev"); if (sOpt >= 0) seg.reverse = (bool)sOpt;
|
||||
sOpt = extractModeDefaults(fx, SET_F("mi")); if (sOpt >= 0) seg.mirror = (bool)sOpt; // NOTE: setting this option is a risky business
|
||||
sOpt = extractModeDefaults(fx, SET_F("rY")); if (sOpt >= 0) seg.reverse_y = (bool)sOpt;
|
||||
sOpt = extractModeDefaults(fx, SET_F("mY")); if (sOpt >= 0) seg.mirror_y = (bool)sOpt; // NOTE: setting this option is a risky business
|
||||
sOpt = extractModeDefaults(fx, "sx"); if (sOpt >= 0) seg.speed = sOpt;
|
||||
sOpt = extractModeDefaults(fx, "ix"); if (sOpt >= 0) seg.intensity = sOpt;
|
||||
sOpt = extractModeDefaults(fx, "c1"); if (sOpt >= 0) seg.custom1 = sOpt;
|
||||
sOpt = extractModeDefaults(fx, "c2"); if (sOpt >= 0) seg.custom2 = sOpt;
|
||||
sOpt = extractModeDefaults(fx, "c3"); if (sOpt >= 0) seg.custom3 = sOpt;
|
||||
sOpt = extractModeDefaults(fx, "mp12"); if (sOpt >= 0) seg.map1D2D = sOpt & 0x07;
|
||||
sOpt = extractModeDefaults(fx, "ssim"); if (sOpt >= 0) seg.soundSim = sOpt & 0x03;
|
||||
sOpt = extractModeDefaults(fx, "rev"); if (sOpt >= 0) seg.reverse = (bool)sOpt;
|
||||
sOpt = extractModeDefaults(fx, "mi"); if (sOpt >= 0) seg.mirror = (bool)sOpt; // NOTE: setting this option is a risky business
|
||||
sOpt = extractModeDefaults(fx, "rY"); if (sOpt >= 0) seg.reverse_y = (bool)sOpt;
|
||||
sOpt = extractModeDefaults(fx, "mY"); if (sOpt >= 0) seg.mirror_y = (bool)sOpt; // NOTE: setting this option is a risky business
|
||||
sOpt = extractModeDefaults(fx, "pal");
|
||||
if (sOpt >= 0 && sOpt < strip.getPaletteCount() + strip.customPalettes.size()) {
|
||||
if (sOpt != seg.palette) {
|
||||
@ -206,8 +206,8 @@ void deserializeSegment(JsonObject elem, byte it, byte presetId)
|
||||
}
|
||||
|
||||
//getVal also supports inc/decrementing and random
|
||||
getVal(elem[F("sx")], &seg.speed);
|
||||
getVal(elem[F("ix")], &seg.intensity);
|
||||
getVal(elem["sx"], &seg.speed);
|
||||
getVal(elem["ix"], &seg.intensity);
|
||||
uint8_t pal = seg.palette;
|
||||
if (getVal(elem["pal"], &pal, 1, strip.getPaletteCount())) {
|
||||
if (pal != seg.palette) {
|
||||
@ -215,15 +215,15 @@ void deserializeSegment(JsonObject elem, byte it, byte presetId)
|
||||
seg.palette = pal;
|
||||
}
|
||||
}
|
||||
getVal(elem[F("c1")], &seg.custom1);
|
||||
getVal(elem[F("c2")], &seg.custom2);
|
||||
getVal(elem["c1"], &seg.custom1);
|
||||
getVal(elem["c2"], &seg.custom2);
|
||||
uint8_t cust3 = seg.custom3;
|
||||
getVal(elem[F("c3")], &cust3); // we can't pass reference to bifield
|
||||
getVal(elem["c3"], &cust3); // we can't pass reference to bifield
|
||||
seg.custom3 = cust3;
|
||||
|
||||
seg.check1 = elem[F("o1")] | seg.check1;
|
||||
seg.check2 = elem[F("o2")] | seg.check2;
|
||||
seg.check3 = elem[F("o3")] | seg.check3;
|
||||
seg.check1 = elem["o1"] | seg.check1;
|
||||
seg.check2 = elem["o2"] | seg.check2;
|
||||
seg.check3 = elem["o3"] | seg.check3;
|
||||
|
||||
JsonArray iarr = elem[F("i")]; //set individual LEDs
|
||||
if (!iarr.isNull()) {
|
||||
@ -496,26 +496,26 @@ void serializeSegment(JsonObject& root, Segment& seg, byte id, bool forPreset, b
|
||||
strcat(colstr, "]");
|
||||
root["col"] = serialized(colstr);
|
||||
|
||||
root["fx"] = seg.mode;
|
||||
root[F("sx")] = seg.speed;
|
||||
root[F("ix")] = seg.intensity;
|
||||
root["pal"] = seg.palette;
|
||||
root[F("c1")] = seg.custom1;
|
||||
root[F("c2")] = seg.custom2;
|
||||
root[F("c3")] = seg.custom3;
|
||||
root[F("sel")] = seg.isSelected();
|
||||
root["rev"] = seg.reverse;
|
||||
root[F("mi")] = seg.mirror;
|
||||
root["fx"] = seg.mode;
|
||||
root["sx"] = seg.speed;
|
||||
root["ix"] = seg.intensity;
|
||||
root["pal"] = seg.palette;
|
||||
root["c1"] = seg.custom1;
|
||||
root["c2"] = seg.custom2;
|
||||
root["c3"] = seg.custom3;
|
||||
root["sel"] = seg.isSelected();
|
||||
root["rev"] = seg.reverse;
|
||||
root["mi"] = seg.mirror;
|
||||
if (strip.isMatrix) {
|
||||
root[F("rY")] = seg.reverse_y;
|
||||
root[F("mY")] = seg.mirror_y;
|
||||
root["rY"] = seg.reverse_y;
|
||||
root["mY"] = seg.mirror_y;
|
||||
root[F("tp")] = seg.transpose;
|
||||
}
|
||||
root[F("o1")] = seg.check1;
|
||||
root[F("o2")] = seg.check2;
|
||||
root[F("o3")] = seg.check3;
|
||||
root[F("ssim")] = seg.soundSim;
|
||||
root[F("mp12")] = seg.map1D2D;
|
||||
root["o1"] = seg.check1;
|
||||
root["o2"] = seg.check2;
|
||||
root["o3"] = seg.check3;
|
||||
root["ssim"] = seg.soundSim;
|
||||
root["mp12"] = seg.map1D2D;
|
||||
}
|
||||
|
||||
void serializeState(JsonObject root, bool forPreset, bool includeBri, bool segmentBounds)
|
||||
@ -920,12 +920,13 @@ void serializeNodes(JsonObject root)
|
||||
|
||||
void serializeModeData(JsonArray fxdata)
|
||||
{
|
||||
char lineBuffer[128];
|
||||
for (size_t i = 0; i < strip.getModeCount(); i++) {
|
||||
String lineBuffer = FPSTR(strip.getModeData(i));
|
||||
if (lineBuffer.length() > 0) {
|
||||
uint8_t endPos = lineBuffer.indexOf('@');
|
||||
if (endPos>0) fxdata.add(lineBuffer.substring(endPos));
|
||||
else fxdata.add("");
|
||||
strncpy_P(lineBuffer, strip.getModeData(i), 127);
|
||||
if (lineBuffer[0] != 0) {
|
||||
char* dataPtr = strchr(lineBuffer,'@');
|
||||
if (dataPtr) fxdata.add(dataPtr);
|
||||
else fxdata.add("");
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -933,12 +934,13 @@ void serializeModeData(JsonArray fxdata)
|
||||
// deserializes mode names string into JsonArray
|
||||
// also removes WLED-SR extensions (@...) from deserialised names
|
||||
void serializeModeNames(JsonArray arr) {
|
||||
char lineBuffer[128];
|
||||
for (size_t i = 0; i < strip.getModeCount(); i++) {
|
||||
String lineBuffer = FPSTR(strip.getModeData(i));
|
||||
if (lineBuffer.length() > 0) {
|
||||
uint8_t endPos = lineBuffer.indexOf('@');
|
||||
if (endPos>0) arr.add(lineBuffer.substring(0, endPos));
|
||||
else arr.add(lineBuffer);
|
||||
strncpy_P(lineBuffer, strip.getModeData(i), 127);
|
||||
if (lineBuffer[0] != 0) {
|
||||
char* dataPtr = strchr(lineBuffer,'@');
|
||||
if (dataPtr) *dataPtr = 0; // terminate mode data after name
|
||||
arr.add(lineBuffer);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -969,7 +971,6 @@ void serveJson(AsyncWebServerRequest* request)
|
||||
request->send(response);
|
||||
releaseJSONBufferLock();
|
||||
} else {
|
||||
//request->send_P(200, "application/json", JSON_mode_names);
|
||||
request->send(503, "application/json", F("{\"error\":3}"));
|
||||
}
|
||||
return;
|
||||
@ -1013,11 +1014,11 @@ void serveJson(AsyncWebServerRequest* request)
|
||||
serializeInfo(info);
|
||||
if (subJson != 3)
|
||||
{
|
||||
//lDoc[F("effects")] = serialized((const __FlashStringHelper*)JSON_mode_names);
|
||||
JsonArray effects = lDoc.createNestedArray(F("effects"));
|
||||
serializeModeNames(effects); // remove WLED-SR extensions from effect names
|
||||
lDoc[F("palettes")] = serialized((const __FlashStringHelper*)JSON_palette_names);
|
||||
}
|
||||
//lDoc["m"] = lDoc.memoryUsage(); // JSON buffer usage, for remote debugging
|
||||
}
|
||||
|
||||
DEBUG_PRINTF("JSON buffer size: %u for request: %d\n", lDoc.memoryUsage(), subJson);
|
||||
|
@ -665,6 +665,9 @@ void sendSysInfoUDP()
|
||||
#define DDP_FLAGS1_STORAGE 0x08
|
||||
#define DDP_FLAGS1_TIME 0x10
|
||||
|
||||
#define DDP_TYPE_RGB24 0x0A
|
||||
#define DDP_TYPE_RGBW32 0x1A // proposal, this is still not an official part of the DDP spec
|
||||
|
||||
#define DDP_ID_DISPLAY 1
|
||||
#define DDP_ID_CONFIG 250
|
||||
#define DDP_ID_STATUS 251
|
||||
@ -724,7 +727,7 @@ uint8_t realtimeBroadcast(uint8_t type, IPAddress client, uint16_t length, uint8
|
||||
// write the header
|
||||
/*0*/ddpUdp.write(flags);
|
||||
/*1*/ddpUdp.write(sequenceNumber++ & 0x0F); // sequence may be unnecessary unless we are sending twice (as requested in Sync settings)
|
||||
/*2*/ddpUdp.write(0);
|
||||
/*2*/ddpUdp.write(0); // data type, this is not fully defined by the DDP spec and thus left at "undefined" which is assumed to be 24-bit RGB
|
||||
/*3*/ddpUdp.write(DDP_ID_DISPLAY);
|
||||
// data offset in bytes, 32-bit number, MSB first
|
||||
/*4*/ddpUdp.write(0xFF & (channel >> 24));
|
||||
|
@ -355,17 +355,22 @@ uint8_t extractModeSlider(uint8_t mode, uint8_t slider, char *dest, uint8_t maxL
|
||||
}
|
||||
|
||||
|
||||
// extracts mode parameter defaults from last section of mode data (e.g. "Juggle@!,Trail;!,!,;!;sx=16,ix=240,1d")
|
||||
int16_t extractModeDefaults(uint8_t mode, const char *segVar)
|
||||
{
|
||||
if (mode < strip.getModeCount()) {
|
||||
String lineBuffer = FPSTR(strip.getModeData(mode));
|
||||
if (lineBuffer.length() > 0) {
|
||||
int16_t start = lineBuffer.lastIndexOf(';');
|
||||
if (start<0) return -1;
|
||||
char lineBuffer[128] = "";
|
||||
strncpy_P(lineBuffer, strip.getModeData(mode), 127);
|
||||
lineBuffer[127] = '\0'; // terminate string
|
||||
if (lineBuffer[0] != 0) {
|
||||
char* startPtr = strrchr(lineBuffer, ';'); // last ";" in FX data
|
||||
if (!startPtr) return -1;
|
||||
|
||||
int16_t stop = lineBuffer.indexOf(segVar, start+1);
|
||||
if (stop<0) return -1;
|
||||
return atoi(lineBuffer.substring(stop+strlen(segVar)+1).c_str());
|
||||
char* stopPtr = strstr(startPtr, segVar);
|
||||
if (!stopPtr) return -1;
|
||||
|
||||
stopPtr += strlen(segVar) +1; // skip "="
|
||||
return atoi(stopPtr);
|
||||
}
|
||||
}
|
||||
return -1;
|
||||
|
@ -8,7 +8,7 @@
|
||||
*/
|
||||
|
||||
// version code in format yymmddb (b = daily build)
|
||||
#define VERSION 2208301
|
||||
#define VERSION 2208310
|
||||
|
||||
//uncomment this if you have a "my_config.h" file you'd like to use
|
||||
//#define WLED_USE_MY_CONFIG
|
||||
@ -222,7 +222,7 @@ using PSRAMDynamicJsonDocument = BasicJsonDocument<PSRAM_Allocator>;
|
||||
|
||||
// Global Variable definitions
|
||||
WLED_GLOBAL char versionString[] _INIT(TOSTRING(WLED_VERSION));
|
||||
#define WLED_CODENAME "Toki"
|
||||
#define WLED_CODENAME "Hoshi"
|
||||
|
||||
// AP and OTA default passwords (for maximum security change them!)
|
||||
WLED_GLOBAL char apPass[65] _INIT(DEFAULT_AP_PASS);
|
||||
|
@ -414,10 +414,10 @@ void deEEP() {
|
||||
for (byte j = 0; j < numChannels; j++) colX.add(EEPROM.read(memloc + j));
|
||||
}
|
||||
|
||||
segObj["fx"] = EEPROM.read(i+10);
|
||||
segObj[F("sx")] = EEPROM.read(i+11);
|
||||
segObj[F("ix")] = EEPROM.read(i+16);
|
||||
segObj["pal"] = EEPROM.read(i+17);
|
||||
segObj["fx"] = EEPROM.read(i+10);
|
||||
segObj["sx"] = EEPROM.read(i+11);
|
||||
segObj["ix"] = EEPROM.read(i+16);
|
||||
segObj["pal"] = EEPROM.read(i+17);
|
||||
} else {
|
||||
Segment* seg = strip.getSegments();
|
||||
memcpy(seg, EEPROM.getDataPtr() +i+2, 240);
|
||||
|
Loading…
Reference in New Issue
Block a user