diff --git a/wled00/FX_2Dfcn.cpp b/wled00/FX_2Dfcn.cpp index 1546ca5d..a5507f23 100644 --- a/wled00/FX_2Dfcn.cpp +++ b/wled00/FX_2Dfcn.cpp @@ -335,7 +335,7 @@ void IRAM_ATTR_YN Segment::setPixelColorXY(int x, int y, uint32_t col) //WLEDMM: x *= glen_; // expand to physical pixels y *= glen_; // expand to physical pixels - if (x >= wid_ || y >= hei_) return; // if pixel would fall out of segment just exit + if (unsigned(x) >= wid_ || unsigned(y) >= hei_) return; // if pixel would fall out of segment just exit const int grp_ = grouping; // WLEDMM optimization for (int j = 0; j < grp_; j++) { // groupping vertically diff --git a/wled00/FX_fcn.cpp b/wled00/FX_fcn.cpp index 0d878310..47dbf4bd 100644 --- a/wled00/FX_fcn.cpp +++ b/wled00/FX_fcn.cpp @@ -1860,13 +1860,13 @@ void WS2812FX::finalizeInit(void) // problem: suspendStripService provides interlocking, but there’s a window before service() observes it, // and ESP32 is dual-core. A critical section closes that window so the pointer swap is atomic across cores. #if defined(ARDUINO_ARCH_ESP32) - taskENTER_CRITICAL(&s_wled_strip_mux); + portENTER_CRITICAL(&s_wled_strip_mux); #endif free(Segment::_globalLeds); Segment::_globalLeds = nullptr; purgeSegments(true); // WLEDMM moved here, because it seems to improve stability. #if defined(ARDUINO_ARCH_ESP32) - taskEXIT_CRITICAL(&s_wled_strip_mux); + portEXIT_CRITICAL(&s_wled_strip_mux); #endif } if (useLedsArray && getLengthTotal()>0) { // WLEDMM avoid malloc(0) diff --git a/wled00/ws.cpp b/wled00/ws.cpp index d475c6b0..52efd664 100644 --- a/wled00/ws.cpp +++ b/wled00/ws.cpp @@ -92,7 +92,7 @@ void wsEvent(AsyncWebSocket * server, AsyncWebSocketClient * client, AwsEventTyp handleE131Packet((e131_packet_t*)&data[offset], client->remoteIP(), P_ARTNET); break; case BINARY_PROTOCOL_DDP: - if (len < 10 + offset) return; // DDP header is 10 bytes (+1 protocol byte) + if (len < unsigned(10 + offset)) return; // DDP header is 10 bytes (+1 protocol byte) size_t ddpDataLen = (data[8+offset] << 8) | data[9+offset]; // data length in bytes from DDP header uint8_t flags = data[0+offset]; if ((flags & DDP_TIMECODE_FLAG) ) ddpDataLen += 4; // timecode flag adds 4 bytes to data length @@ -102,7 +102,7 @@ void wsEvent(AsyncWebSocket * server, AsyncWebSocketClient * client, AwsEventTyp } } } else { - DEBUG_PRINTF("WS multipart message: final %u index %u len %u total %u\n", info->final, info->index, len, (uint32_t)info->len); + DEBUG_PRINTF("WS multipart message: final %u index %u len %u total %u\n", info->final, uint32_t(info->index), len, (uint32_t)info->len); //message is comprised of multiple frames or the frame is split into multiple packets //if(info->index == 0){ //if (!wsFrameBuffer && len < 4096) wsFrameBuffer = new uint8_t[4096];