Fork of the espurna firmware for `mhsw` switches
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

141 lines
4.4 KiB

6 years ago
  1. #pragma once
  2. //------------------------------------------------------------------------------
  3. // Do not change this file unless you know what you are doing
  4. // Configuration settings are in the general.h file
  5. //------------------------------------------------------------------------------
  6. #if DEBUG_TELNET_SUPPORT
  7. #undef TELNET_SUPPORT
  8. #define TELNET_SUPPORT 1
  9. #endif
  10. #if not WEB_SUPPORT
  11. #undef DEBUG_WEB_SUPPORT
  12. #define DEBUG_WEB_SUPPORT 0
  13. #endif
  14. #if not WEB_SUPPORT
  15. #undef API_SUPPORT
  16. #define API_SUPPORT 0 // API support requires web support
  17. #endif
  18. #if not WEB_SUPPORT
  19. #undef SSDP_SUPPORT
  20. #define SSDP_SUPPORT 0 // SSDP support requires web support
  21. #endif
  22. #if UART_MQTT_SUPPORT
  23. #define MQTT_SUPPORT 1
  24. #undef TERMINAL_SUPPORT
  25. #define TERMINAL_SUPPORT 0
  26. #undef DEBUG_SERIAL_SUPPORT
  27. #define DEBUG_SERIAL_SUPPORT 0
  28. #endif
  29. #if ALEXA_SUPPORT
  30. #undef BROKER_SUPPORT
  31. #define BROKER_SUPPORT 1 // If Alexa enabled enable BROKER
  32. #endif
  33. #if RPN_RULES_SUPPORT
  34. #undef BROKER_SUPPORT
  35. #define BROKER_SUPPORT 1 // If RPN Rules enabled enable BROKER
  36. #undef WEB_SUPPORT
  37. #define WEB_SUPPORT 1
  38. #undef MQTT_SUPPORT
  39. #define MQTT_SUPPORT 1
  40. #endif
  41. #if LED_SUPPORT
  42. #undef BROKER_SUPPORT
  43. #define BROKER_SUPPORT 1 // If LED is enabled enable BROKER to supply status changes
  44. #endif
  45. #if INFLUXDB_SUPPORT
  46. #undef BROKER_SUPPORT
  47. #define BROKER_SUPPORT 1 // If InfluxDB enabled enable BROKER
  48. #endif
  49. #if DOMOTICZ_SUPPORT
  50. #undef MQTT_SUPPORT
  51. #define MQTT_SUPPORT 1 // If Domoticz enabled enable MQTT
  52. #undef BROKER_SUPPORT
  53. #define BROKER_SUPPORT 1 // If Domoticz enabled enable BROKER
  54. #endif
  55. #if HOMEASSISTANT_SUPPORT
  56. #undef MQTT_SUPPORT
  57. #define MQTT_SUPPORT 1 // If Home Assistant enabled enable MQTT
  58. #endif
  59. #if THINGSPEAK_SUPPORT
  60. #undef BROKER_SUPPORT
  61. #define BROKER_SUPPORT 1 // If Thingspeak enabled enable BROKER
  62. #endif
  63. #if SCHEDULER_SUPPORT
  64. #undef NTP_SUPPORT
  65. #define NTP_SUPPORT 1 // Scheduler needs NTP
  66. #endif
  67. #if LWIP_VERSION_MAJOR != 1
  68. #undef MDNS_CLIENT_SUPPORT
  69. #define MDNS_CLIENT_SUPPORT 0 // default resolver already handles this
  70. #endif
  71. #if not defined(ARDUINO_ESP8266_RELEASE_2_3_0)
  72. #undef TELNET_SERVER_ASYNC_BUFFERED
  73. #define TELNET_SERVER_ASYNC_BUFFERED 1 // enable buffered telnet by default on latest Cores
  74. #endif
  75. #if LLMNR_SUPPORT && defined(ARDUINO_ESP8266_RELEASE_2_3_0)
  76. #undef LLMNR_SUPPORT
  77. #define LLMNR_SUPPORT 0
  78. #endif
  79. #if NETBIOS_SUPPORT && defined(ARDUINO_ESP8266_RELEASE_2_3_0)
  80. #undef NETBIOS_SUPPORT
  81. #define NETBIOS_SUPPORT 0
  82. #endif
  83. #if SSDP_SUPPORT && defined(ARDUINO_ESP8266_RELEASE_2_3_0)
  84. #undef SSDP_SUPPORT
  85. #define SSDP_SUPPORT 0
  86. #endif
  87. #if LIGHT_PROVIDER == LIGHT_PROVIDER_TUYA
  88. #undef TUYA_SUPPORT
  89. #define TUYA_SUPPORT 1 // Need base Tuya module for this to work
  90. #undef LIGHT_USE_TRANSITIONS
  91. #define LIGHT_USE_TRANSITIONS 0 // TODO: temporary, maybe slower step instead?
  92. #endif
  93. #if TUYA_SUPPORT
  94. #undef BROKER_SUPPORT
  95. #define BROKER_SUPPORT 1 // Broker is required to process relay & lights events
  96. #endif
  97. // TODO: clean-up SSL_ENABLED and USE_SSL settings for 1.15.0
  98. #if ASYNC_TCP_SSL_ENABLED && SECURE_CLIENT == SECURE_CLIENT_NONE
  99. #undef SECURE_CLIENT
  100. #define SECURE_CLIENT SECURE_CLIENT_AXTLS
  101. #endif
  102. #if THINGSPEAK_USE_SSL && THINGSPEAK_USE_ASYNC && (!ASYNC_TCP_SSL_ENABLED)
  103. #warning "Thingspeak in ASYNC mode requires a globally defined ASYNC_TCP_SSL_ENABLED=1"
  104. #undef THINGSPEAK_SUPPORT
  105. #define THINGSPEAK_SUPPORT 0 // Thingspeak in ASYNC mode requires ASYNC_TCP_SSL_ENABLED
  106. #endif
  107. #if WEB_SUPPORT && WEB_SSL_ENABLED && (!ASYNC_TCP_SSL_ENABLED)
  108. #warning "WEB_SUPPORT with SSL requires a globally defined ASYNC_TCP_SSL_ENABLED=1"
  109. #undef WEB_SSL_ENABLED
  110. #define WEB_SSL_ENABLED 0 // WEB_SUPPORT mode th SSL requires ASYNC_TCP_SSL_ENABLED
  111. #endif
  112. #if not DEBUG_SUPPORT
  113. #undef DEBUG_LOG_BUFFER_SUPPORT
  114. #define DEBUG_LOG_BUFFER_SUPPORT 0 // Can't buffer if there is no debugging enabled.
  115. // Helps to avoid checking twice for both DEBUG_SUPPORT and BUFFER_LOG_SUPPORT
  116. #endif