Fix a few compiler warnings

This commit is contained in:
cschwinne 2020-11-17 22:46:17 +01:00
parent a839ec4832
commit 074d53fa17
4 changed files with 12 additions and 4 deletions

View File

@ -125,6 +125,9 @@ build_flags =
-Wno-unused-but-set-variable
-Wno-return-type
-Wno-sequence-point
-Wno-narrowing
-Wno-reorder
-Wno-unused-local-typedefs
-DMQTT_MAX_PACKET_SIZE=1024
-DSECURE_CLIENT=SECURE_CLIENT_BEARSSL
-DBEARSSL_SSL_BASIC
@ -322,9 +325,10 @@ lib_ignore =
[env:esp32_poe]
board = esp32-poe
platform = espressif32@1.12.4
platform = espressif32@2.0
upload_speed = 921600
build_flags = ${common.build_flags_esp32} ${common.debug_flags} -D RLYPIN=-1 -D WLED_USE_ETHERNET
build_unflags = ${common.build_unflags}
build_flags = ${common.build_flags_esp32} -D RLYPIN=-1 -D WLED_USE_ETHERNET
lib_ignore =
ESPAsyncTCP
ESPAsyncUDP

View File

@ -40,8 +40,12 @@
#define DEFAULT_INTENSITY (uint8_t)128
#define DEFAULT_COLOR (uint32_t)0xFFAA00
#ifndef MIN
#define MIN(a,b) ((a)<(b)?(a):(b))
#endif
#ifndef MAX
#define MAX(a,b) ((a)>(b)?(a):(b))
#endif
/* Not used in all effects yet */
#define WLED_FPS 42

View File

@ -583,7 +583,7 @@ public:
return perc / 255;
}
~Espalexa(){delete devices;} //note: Espalexa is NOT meant to be destructed
~Espalexa(){} //note: Espalexa is NOT meant to be destructed
};
#endif

View File

@ -4,7 +4,7 @@
#include "Arduino.h"
#include <functional>
typedef class EspalexaDevice;
class EspalexaDevice;
typedef std::function<void(uint8_t b)> BrightnessCallbackFunction;
typedef std::function<void(EspalexaDevice* d)> DeviceCallbackFunction;