1
0
mirror of https://github.com/DCC-EX/CommandStation-EX.git synced 2024-11-27 01:56:14 +01:00

Warn for broken configs

This commit is contained in:
Harald Barth 2021-11-22 00:41:47 +01:00
parent 1807189183
commit a4f746c00c
2 changed files with 27 additions and 12 deletions

View File

@ -1 +1,2 @@
#define GITHUB_SHA "37904b5" #define GITHUB_SHA "disable-eeprom-20211122-00:00"

View File

@ -39,19 +39,29 @@
#if (defined(ARDUINO_AVR_MEGA) || defined(ARDUINO_AVR_MEGA2560) || defined(ARDUINO_SAMD_ZERO) || defined(TEENSYDUINO)) #if (defined(ARDUINO_AVR_MEGA) || defined(ARDUINO_AVR_MEGA2560) || defined(ARDUINO_SAMD_ZERO) || defined(TEENSYDUINO))
#define BIG_RAM #define BIG_RAM
#endif #endif
#if ENABLE_WIFI && defined(BIG_RAM) #if ENABLE_WIFI
#define WIFI_ON true #if defined(BIG_RAM)
#ifndef WIFI_CHANNEL #define WIFI_ON true
#define WIFI_CHANNEL 1 #ifndef WIFI_CHANNEL
#endif #define WIFI_CHANNEL 1
#endif
#else
#warning You have defined that you want WIFI but your hardware has not enough memory to do that, so WIFI DISABLED
#define WIFI_ON false
#endif
#else #else
#define WIFI_ON false #define WIFI_ON false
#endif #endif
#if ENABLE_ETHERNET && defined(BIG_RAM) #if ENABLE_ETHERNET
#define ETHERNET_ON true #if defined(BIG_RAM)
#define ETHERNET_ON true
#else
#warning You have defined that you want ETHERNET but your hardware has not enough memory to do that, so ETHERNET DISABLED
#define ETHERNET_ON false
#endif
#else #else
#define ETHERNET_ON false #define ETHERNET_ON false
#endif #endif
#if WIFI_ON && ETHERNET_ON #if WIFI_ON && ETHERNET_ON
@ -65,8 +75,12 @@
// //
#define WIFI_SERIAL_LINK_SPEED 115200 #define WIFI_SERIAL_LINK_SPEED 115200
#if __has_include ( "myAutomation.h") && (defined(BIG_RAM) || defined(DISABLE_EEPROM)) #if __has_include ( "myAutomation.h")
#define RMFT_ACTIVE #if defined(BIG_RAM) || defined(DISABLE_EEPROM)
#define RMFT_ACTIVE
#else
#warning You have myAutomation.h but your hardware has not enough memory to do that, so EX-RAIL DISABLED
#endif
#endif #endif
#endif #endif