Amending missing files in previous commit

pull/337/head
cschwinne 2019-10-29 01:19:56 +01:00
rodzic 4e4773a370
commit ddaaae46a6
6 zmienionych plików z 21 dodań i 16 usunięć

Wyświetl plik

@ -545,7 +545,7 @@ class WS2812FX {
//10 names per line //10 names per line
const char JSON_mode_names[] PROGMEM = R"=====([ const char JSON_mode_names[] PROGMEM = R"=====([
"Solid","Blink","Breathe","Wipe","Wipe Random","Random Colors","Sweep","Dynamic","Colorloop","Rainbow", "Solid","Blink","Breathe","Wipe","Wipe Random","Random Colors","Sweep","Dynamic","Colorloop","Rainbow",
"Scan","Dual Scan","Fade","Chase","Chase Rainbow","Running","Saw","Twinkle","Dissolve","Dissolve Rnd", "Scan","Dual Scan","Fade","Theater","Theater Rainbow","Running","Saw","Twinkle","Dissolve","Dissolve Rnd",
"Sparkle","Dark Sparkle","Sparkle+","Strobe","Strobe Rainbow","Mega Strobe","Blink Rainbow","Android","Chase","Chase Random", "Sparkle","Dark Sparkle","Sparkle+","Strobe","Strobe Rainbow","Mega Strobe","Blink Rainbow","Android","Chase","Chase Random",
"Chase Rainbow","Chase Flash","Chase Flash Rnd","Rainbow Runner","Colorful","Traffic Light","Sweep Random","Running 2","Red & Blue","Stream", "Chase Rainbow","Chase Flash","Chase Flash Rnd","Rainbow Runner","Colorful","Traffic Light","Sweep Random","Running 2","Red & Blue","Stream",
"Scanner","Lighthouse","Fireworks","Rain","Merry Christmas","Fire Flicker","Gradient","Loading","In Out","In In", "Scanner","Lighthouse","Fireworks","Rain","Merry Christmas","Fire Flicker","Gradient","Loading","In Out","In In",

Wyświetl plik

@ -52,7 +52,7 @@ mDNS address (leave empty for no mDNS):<br/>
http:// <input name="CM" maxlength="32"> .local<br> http:// <input name="CM" maxlength="32"> .local<br>
Client IP: <span class="sip"> Not connected </span><br> Client IP: <span class="sip"> Not connected </span><br>
<h3>Configure Access Point</h3> <h3>Configure Access Point</h3>
AP SSID (leave empty for no AP):<br><input name="AS" maxlength="32"><br> AP name (SSID):<br><input name="AS" maxlength="32"><br>
Hide AP name: <input type="checkbox" name="AH"><br> Hide AP name: <input type="checkbox" name="AH"><br>
AP password (leave empty for open):<br> <input type="password" name="AP" maxlength="63"><br> AP password (leave empty for open):<br> <input type="password" name="AP" maxlength="63"><br>
Access Point WiFi channel: <input name="AC" type="number" min="1" max="13" required><br> Access Point WiFi channel: <input name="AC" type="number" min="1" max="13" required><br>
@ -316,6 +316,7 @@ Time zone:
<option value="11">AEST/AEDT</option> <option value="11">AEST/AEDT</option>
<option value="12">NZST/NZDT</option> <option value="12">NZST/NZDT</option>
<option value="13">North Korea</option> <option value="13">North Korea</option>
<option value="14">IST (India)</option>
</select><br> </select><br>
UTC offset: <input name="UO" type="number" min="-65500" max="65500" required> seconds (max. 18 hours)<br> UTC offset: <input name="UO" type="number" min="-65500" max="65500" required> seconds (max. 18 hours)<br>
Current local time is <span class="times">unknown</span>. Current local time is <span class="times">unknown</span>.

Wyświetl plik

@ -100,7 +100,7 @@
//version code in format yymmddb (b = daily build) //version code in format yymmddb (b = daily build)
#define VERSION 1910255 #define VERSION 1910291
char versionString[] = "0.8.6"; char versionString[] = "0.8.6";
@ -409,7 +409,7 @@ time_t local = 0;
unsigned long ntpLastSyncTime = 999000000L; unsigned long ntpLastSyncTime = 999000000L;
unsigned long ntpPacketSentTime = 999000000L; unsigned long ntpPacketSentTime = 999000000L;
IPAddress ntpServerIP; IPAddress ntpServerIP;
unsigned int ntpLocalPort = 2390; uint16_t ntpLocalPort = 2390;
#define NTP_PACKET_SIZE 48 #define NTP_PACKET_SIZE 48
#define MAX_LEDS 1500 #define MAX_LEDS 1500

Wyświetl plik

@ -52,7 +52,10 @@ Timezone tzNZ(NZDT, NZST);
TimeChangeRule NKST = {Last, Sun, Mar, 1, 510}; //Pyongyang Time = UTC + 8.5 hours TimeChangeRule NKST = {Last, Sun, Mar, 1, 510}; //Pyongyang Time = UTC + 8.5 hours
Timezone tzNK(NKST, NKST); Timezone tzNK(NKST, NKST);
Timezone* timezones[] = {&tzUTC, &tzUK, &tzEUCentral, &tzEUEastern, &tzUSEastern, &tzUSCentral, &tzUSMountain, &tzUSArizona, &tzUSPacific, &tzChina, &tzJapan, &tzAUEastern, &tzNZ, &tzNK}; TimeChangeRule IST = {Last, Sun, Mar, 1, 330}; // India Standard Time = UTC + 5.5 hours
Timezone tzIndia(IST, IST);
Timezone* timezones[] = {&tzUTC, &tzUK, &tzEUCentral, &tzEUEastern, &tzUSEastern, &tzUSCentral, &tzUSMountain, &tzUSArizona, &tzUSPacific, &tzChina, &tzJapan, &tzAUEastern, &tzNZ, &tzNK, &tzIndia};
void handleNetworkTime() void handleNetworkTime()
{ {

Wyświetl plik

@ -102,7 +102,7 @@ char* buffer;
void sendHADiscoveryMQTT() void sendHADiscoveryMQTT()
{ {
//TODO: With LwIP 1 the ESP loses MQTT connection and causes memory leak when sending discovery packet
#if ARDUINO_ARCH_ESP32 || LWIP_VERSION_MAJOR > 1 #if ARDUINO_ARCH_ESP32 || LWIP_VERSION_MAJOR > 1
/* /*

Wyświetl plik

@ -77,21 +77,22 @@ bool deserializeState(JsonObject root)
} }
} }
byte fx = elem["fx"] | seg.mode;
if (fx != seg.mode && fx < strip.getModeCount()) strip.setMode(id, fx);
seg.speed = elem["sx"] | seg.speed;
seg.intensity = elem["ix"] | seg.intensity;
seg.palette = elem["pal"] | seg.palette;
//if (pal != seg.palette && pal < strip.getPaletteCount()) strip.setPalette(pal); //if (pal != seg.palette && pal < strip.getPaletteCount()) strip.setPalette(pal);
seg.setOption(0, elem["sel"] | seg.getOption(0)); //selected seg.setOption(0, elem["sel"] | seg.getOption(0)); //selected
seg.setOption(1, elem["rev"] | seg.getOption(1)); //reverse seg.setOption(1, elem["rev"] | seg.getOption(1)); //reverse
//int cln = seg_0["cln"]; //int cln = seg_0["cln"];
//temporary //temporary, strip object gets updated via colorUpdated()
if (id == 0) { if (id == 0) {
effectCurrent = seg.mode; effectCurrent = elem["fx"] | effectCurrent;
effectSpeed = seg.speed; effectSpeed = elem["sx"] | effectSpeed;
effectIntensity = seg.intensity; effectIntensity = elem["ix"] | effectIntensity ;
effectPalette = seg.palette; effectPalette = elem["pal"] | effectPalette;
} else { //permanent
byte fx = elem["fx"] | seg.mode;
if (fx != seg.mode && fx < strip.getModeCount()) strip.setMode(id, fx);
seg.speed = elem["sx"] | seg.speed;
seg.intensity = elem["ix"] | seg.intensity;
seg.palette = elem["pal"] | seg.palette;
} }
} }
it++; it++;