Skip to content

Commit 35c8474

Browse files
committed
Merge branch 'mdev' into pixelforge_backport
2 parents eb55b4f + 4521ba8 commit 35c8474

File tree

5 files changed

+11
-7
lines changed

5 files changed

+11
-7
lines changed

wled00/FX_fcn.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1394,6 +1394,9 @@ uint8_t Segment::differs(Segment& b) const {
13941394
if (custom1 != b.custom1) d |= SEG_DIFFERS_FX;
13951395
if (custom2 != b.custom2) d |= SEG_DIFFERS_FX;
13961396
if (custom3 != b.custom3) d |= SEG_DIFFERS_FX;
1397+
if (check1 != b.check1) d |= SEG_DIFFERS_FX;
1398+
if (check2 != b.check2) d |= SEG_DIFFERS_FX;
1399+
if (check3 != b.check3) d |= SEG_DIFFERS_FX;
13971400
if (startY != b.startY) d |= SEG_DIFFERS_BOUNDS;
13981401
if (stopY != b.stopY) d |= SEG_DIFFERS_BOUNDS;
13991402

wled00/playlist.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,8 @@ int16_t loadPlaylist(JsonObject playlistObj, byte presetId) {
9090
it++;
9191
}
9292
}
93-
for (int i = it; i < playlistLen; i++) playlistEntries[i].dur = playlistEntries[it -1].dur;
93+
if (it > 0) // should never happen but just in case
94+
for (int i = it; i < playlistLen; i++) playlistEntries[i].dur = playlistEntries[it -1].dur;
9495

9596
it = 0;
9697
JsonArray tr = playlistObj[F("transition")];

wled00/udp.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -499,8 +499,8 @@ void handleNotifications()
499499
selseg.custom2 = udpIn[30+ofs];
500500
selseg.custom3 = udpIn[31+ofs] & 0x1F;
501501
selseg.check1 = (udpIn[31+ofs]>>5) & 0x1;
502-
selseg.check1 = (udpIn[31+ofs]>>6) & 0x1;
503-
selseg.check1 = (udpIn[31+ofs]>>7) & 0x1;
502+
selseg.check2 = (udpIn[31+ofs]>>6) & 0x1;
503+
selseg.check3 = (udpIn[31+ofs]>>7) & 0x1;
504504
}
505505
startY = (udpIn[32+ofs] << 8 | udpIn[33+ofs]);
506506
stopY = (udpIn[34+ofs] << 8 | udpIn[35+ofs]);

wled00/util.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -272,7 +272,7 @@ void releaseJSONBufferLock()
272272

273273

274274
// extracts effect mode (or palette) name from names serialized string
275-
// caller must provide large enough buffer for name (including SR extensions)!
275+
// caller must provide large enough buffer for name (including SR extensions)! maxLen is (buffersize - 1)
276276
uint8_t extractModeName(uint8_t mode, const char *src, char *dest, uint8_t maxLen)
277277
{
278278
if (src == JSON_mode_names || src == nullptr) {
@@ -294,7 +294,7 @@ uint8_t extractModeName(uint8_t mode, const char *src, char *dest, uint8_t maxLe
294294

295295
if (src == JSON_palette_names && mode > (GRADIENT_PALETTE_COUNT + 13)) {
296296
snprintf_P(dest, maxLen, PSTR("~ Custom %d ~"), 255-mode);
297-
dest[maxLen-1] = '\0';
297+
dest[maxLen] = '\0';
298298
return strlen(dest);
299299
}
300300

@@ -329,7 +329,7 @@ uint8_t extractModeName(uint8_t mode, const char *src, char *dest, uint8_t maxLe
329329
}
330330

331331

332-
// extracts effect slider data (1st group after @)
332+
// extracts effect slider data (1st group after @) -> maxLen is (buffersize - 1)
333333
uint8_t extractModeSlider(uint8_t mode, uint8_t slider, char *dest, uint8_t maxLen, uint8_t *var)
334334
{
335335
dest[0] = '\0'; // start by clearing buffer

wled00/wled.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*/
88

99
// version code in format yymmddb (b = daily build)
10-
#define VERSION 2512171
10+
#define VERSION 2512291
1111

1212
// WLEDMM - you can check for this define in usermods, to only enabled WLEDMM specific code in the "right" fork. Its not defined in AC WLED.
1313
#define _MoonModules_WLED_

0 commit comments

Comments
 (0)