From 39d81182d5f24468cd9808e74df67f45606b1aac Mon Sep 17 00:00:00 2001 From: Theo Arends <11044339+arendst@users.noreply.github.com> Date: Fri, 15 Mar 2019 14:53:19 +0100 Subject: [PATCH] Prep for 6.5 Prep for 6.5 --- RELEASENOTES.md | 184 ++++++++++++++++++----------------- sonoff/_changelog.ino | 3 + sonoff/my_user_config.h | 10 -- sonoff/sonoff.ino | 4 +- sonoff/sonoff_post.h | 2 - sonoff/sonoff_version.h | 2 +- sonoff/support_features.ino | 6 +- sonoff/xdrv_01_webserver.ino | 18 ++-- sonoff/xdrv_02_mqtt.ino | 160 ------------------------------ sonoff/xdrv_07_domoticz.ino | 1 - 10 files changed, 114 insertions(+), 276 deletions(-) diff --git a/RELEASENOTES.md b/RELEASENOTES.md index c90d62e06..21885e970 100644 --- a/RELEASENOTES.md +++ b/RELEASENOTES.md @@ -107,100 +107,106 @@ Core version **2.4.2** binaries can be found at http://thehackbox.org/tasmota/ ### Available Features and Sensors -| Feature or Sensor | minimal | basic | classic | sonoff | knx | sensors | Remarks -|--------------------------------|---------|-------|---------|--------|------|---------|-------- -| MY_LANGUAGE en-GB | x | x | x | x | x | x | -| MQTT_LIBRARY_TYPE PUBSUBCLIENT | x | x | x | x | x | x | -| USE_WPS | - | - | x | - | - | - | WPS -| USE_SMARTCONFIG | - | - | x | - | - | - | SmartConfig -| USE_ARDUINO_OTA | - | - | - | - | - | - | -| USE_DOMOTICZ | - | - | x | x | x | x | -| USE_HOME_ASSISTANT | - | - | - | x | x | x | -| USE_MQTT_TLS | - | - | - | - | - | - | -| USE_KNX | - | - | - | - | x | - | -| USE_WEBSERVER | x | x | x | x | x | x | WifiManager -| USE_EMULATION | - | x | x | x | - | x | -| USE_DISCOVERY | - | - | x | x | x | x | -| WEBSERVER_ADVERTISE | - | - | x | x | x | x | -| MQTT_HOST_DISCOVERY | - | - | x | x | x | x | -| USE_TIMERS | - | x | - | x | x | x | -| USE_TIMERS_WEB | - | x | - | x | x | x | -| USE_SUNRISE | - | x | - | x | x | x | -| USE_RULES | - | x | - | x | x | x | -| USE_EXPRESSION | - | - | - | - | - | - | -| | | | | | | -| USE_ADC_VCC | x | x | x | x | x | - | -| USE_DS18B20 | - | - | - | - | - | - | Single sensor -| USE_DS18x20 | - | - | x | x | x | x | Multiple sensors -| USE_DS18x20_LEGACY | - | - | - | - | - | - | Multiple sensors -| | | | | | | | -| Feature or Sensor | minimal | basic | classic | sonoff | knx | sensors | -| USE_I2C | - | - | - | x | x | x | -| USE_SHT | - | - | - | x | x | x | -| USE_HTU | - | - | - | x | x | x | -| USE_BMP | - | - | - | x | x | x | -| USE_BME680 | - | - | - | - | - | x | -| USE_BH1750 | - | - | - | x | x | x | -| USE_VEML6070 | - | - | - | - | - | x | -| USE_ADS1115 | - | - | - | - | - | x | -| USE_ADS1115_I2CDEV | - | - | - | - | - | - | -| USE_INA219 | - | - | - | - | - | x | -| USE_SHT3X | - | - | - | x | x | x | -| USE_TSL2561 | - | - | - | - | - | x | -| USE_MGS | - | - | - | - | - | x | -| USE_SGP30 | - | - | - | x | x | x | -| USE_SI1145 | - | - | - | - | - | - | -| USE_LM75AD | - | - | - | x | x | x | -| USE_APDS9960 | - | - | - | - | - | - | -| USE_MCP230xx | - | - | - | - | - | - | -| USE_PCA9685 | - | - | - | - | - | - | -| USE_MPR121 | - | - | - | - | - | - | -| USE_CCS811 | - | - | - | - | - | - | -| USE_MPU6050 | - | - | - | - | - | - | -| USE_DS3231 | - | - | - | - | - | - | -| USE_MGC3130 | - | - | - | - | - | - | -| USE_MAX44009 | - | - | - | - | - | - | -| USE_SCD30 | - | - | - | - | - | x | -| | | | | | | | -| Feature or Sensor | minimal | basic | classic | sonoff | knx | sensors | -| USE_SPI | - | - | - | - | - | - | -| USE_MHZ19 | - | - | - | x | x | x | -| USE_SENSEAIR | - | - | - | x | x | x | -| USE_PMS5003 | - | - | - | x | x | x | -| USE_NOVA_SDS | - | - | - | x | x | x | -| USE_PZEM004T | - | - | - | x | x | x | -| USE_PZEM_AC | - | - | - | x | x | x | -| USE_PZEM_DC | - | - | - | x | x | x | -| USE_MCP39F501 | - | x | - | x | x | x | -| USE_SERIAL_BRIDGE | - | - | - | x | x | x | -| USE_SDM120 | - | - | - | - | - | x | -| USE_SDM630 | - | - | - | - | - | x | -| USE_MP3_PLAYER | - | - | - | - | - | x | -| USE_TUYA_DIMMER | - | x | - | x | x | x | -| USE_ARMTRONIX_DIMMERS | - | x | - | x | x | x | -| USE_PS_16_DZ | - | x | - | x | x | x | -| USE_AZ7798 | - | - | - | - | - | - | -| USE_PN532_HSU | - | - | - | - | - | x | -| USE_IR_REMOTE | - | - | - | x | x | x | -| USE_IR_HVAC | - | - | - | - | - | x | -| USE_IR_RECEIVE | - | - | - | x | x | x | -| USE_WS2812 | - | - | x | x | x | x | -| USE_WS2812_DMA | - | - | - | - | - | - | -| USE_ARILUX_RF | - | - | - | x | x | x | -| USE_SR04 | - | - | - | x | x | x | -| USE_TM1638 | - | - | - | - | - | x | -| USE_HX711 | - | - | - | x | x | x | -| USE_RF_FLASH | - | - | - | x | x | x | -| USE_TX20_WIND_SENSOR | - | - | - | x | x | x | -| USE_RC_SWITCH | - | - | - | x | x | x | -| USE_RF_SENSOR | - | - | - | - | - | x | AlectoV2 only -| USE_SM16716 | - | x | x | x | x | x | -| USE_DISPLAY | - | - | - | - | - | - | +| Feature or Sensor | minimal | basic | classic | sonoff | knx | sensors | display | Remarks +|-----------------------|---------|-------|---------|--------|------|---------|---------|-------- +| MY_LANGUAGE en-GB | x | x | x | x | x | x | x | +| USE_WPS | - | - | x | - | - | - | - | WPS +| USE_SMARTCONFIG | - | - | x | - | - | - | - | SmartConfig +| USE_ARDUINO_OTA | - | - | - | - | - | - | - | +| USE_DOMOTICZ | - | - | x | x | x | x | - | +| USE_HOME_ASSISTANT | - | - | - | x | x | x | - | +| USE_MQTT_TLS | - | - | - | - | - | - | - | +| USE_KNX | - | - | - | - | x | - | - | +| USE_WEBSERVER | x | x | x | x | x | x | x | WifiManager +| USE_EMULATION | - | x | x | x | - | x | - | +| USE_DISCOVERY | - | - | x | x | x | x | x | +| WEBSERVER_ADVERTISE | - | - | x | x | x | x | x | +| MQTT_HOST_DISCOVERY | - | - | x | x | x | x | x | +| USE_TIMERS | - | x | - | x | x | x | x | +| USE_TIMERS_WEB | - | x | - | x | x | x | x | +| USE_SUNRISE | - | x | - | x | x | x | x | +| USE_RULES | - | x | - | x | x | x | x | +| USE_EXPRESSION | - | - | - | - | - | - | - | +| | | | | | | | | +| USE_ADC_VCC | x | x | x | x | x | - | x | +| USE_DS18B20 | - | - | - | - | - | - | - | Single sensor +| USE_DS18x20 | - | - | x | x | x | x | x | Multiple sensors +| USE_DS18x20_LEGACY | - | - | - | - | - | - | - | Multiple sensors +| | | | | | | | | +| Feature or Sensor | minimal | basic | classic | sonoff | knx | sensors | display | Remarks +| USE_I2C | - | - | - | x | x | x | x | +| USE_SHT | - | - | - | x | x | x | x | +| USE_HTU | - | - | - | x | x | x | x | +| USE_BMP | - | - | - | x | x | x | x | +| USE_BME680 | - | - | - | - | - | x | - | +| USE_BH1750 | - | - | - | x | x | x | x | +| USE_VEML6070 | - | - | - | - | - | x | - | +| USE_ADS1115 | - | - | - | - | - | x | - | +| USE_ADS1115_I2CDEV | - | - | - | - | - | - | - | +| USE_INA219 | - | - | - | - | - | x | - | +| USE_SHT3X | - | - | - | x | x | x | x | +| USE_TSL2561 | - | - | - | - | - | x | - | +| USE_MGS | - | - | - | - | - | x | - | +| USE_SGP30 | - | - | - | x | x | x | x | +| USE_SI1145 | - | - | - | - | - | - | - | +| USE_LM75AD | - | - | - | x | x | x | x | +| USE_APDS9960 | - | - | - | - | - | - | - | +| USE_MCP230xx | - | - | - | - | - | - | - | +| USE_PCA9685 | - | - | - | - | - | - | - | +| USE_MPR121 | - | - | - | - | - | - | - | +| USE_CCS811 | - | - | - | - | - | - | - | +| USE_MPU6050 | - | - | - | - | - | - | - | +| USE_DS3231 | - | - | - | - | - | - | - | +| USE_MGC3130 | - | - | - | - | - | - | - | +| USE_MAX44009 | - | - | - | - | - | - | - | +| USE_SCD30 | - | - | - | - | - | x | - | +| | | | | | | | | +| Feature or Sensor | minimal | basic | classic | sonoff | knx | sensors | display | Remarks +| USE_SPI | - | - | - | - | - | - | x | +| USE_MHZ19 | - | - | - | x | x | x | x | +| USE_SENSEAIR | - | - | - | x | x | x | x | +| USE_PMS5003 | - | - | - | x | x | x | x | +| USE_NOVA_SDS | - | - | - | x | x | x | x | +| USE_ENERGY_SENSOR | - | x | x | x | x | x | - | +| USE_PZEM004T | - | - | - | x | x | x | - | +| USE_PZEM_AC | - | - | - | x | x | x | - | +| USE_PZEM_DC | - | - | - | x | x | x | - | +| USE_MCP39F501 | - | x | - | x | x | x | - | +| USE_SERIAL_BRIDGE | - | - | - | x | x | x | x | +| USE_SDM120 | - | - | - | - | - | x | - | +| USE_SDM630 | - | - | - | - | - | x | - | +| USE_MP3_PLAYER | - | - | - | - | - | x | - | +| USE_TUYA_DIMMER | - | x | - | x | x | x | x | +| USE_ARMTRONIX_DIMMERS | - | x | - | x | x | x | x | +| USE_PS_16_DZ | - | x | - | x | x | x | x | +| USE_AZ7798 | - | - | - | - | - | - | - | +| USE_PN532_HSU | - | - | - | - | - | x | - | +| USE_IR_REMOTE | - | - | - | x | x | x | x | +| USE_IR_HVAC | - | - | - | - | - | x | - | +| USE_IR_RECEIVE | - | - | - | x | x | x | x | +| USE_WS2812 | - | - | x | x | x | x | x | +| USE_WS2812_DMA | - | - | - | - | - | - | - | +| USE_ARILUX_RF | - | - | - | x | x | x | - | +| USE_SR04 | - | - | - | x | x | x | x | +| USE_TM1638 | - | - | - | - | - | x | - | +| USE_HX711 | - | - | - | x | x | x | x | +| USE_RF_FLASH | - | - | - | x | x | x | - | +| USE_TX20_WIND_SENSOR | - | - | - | x | x | x | x | +| USE_RC_SWITCH | - | - | - | x | x | x | x | +| USE_RF_SENSOR | - | - | - | - | - | x | - | AlectoV2 only +| USE_SM16716 | - | x | x | x | x | x | x | +| USE_DISPLAY | - | - | - | - | - | - | x | +| USE_DISPLAY_LCD | - | - | - | - | - | - | x | +| USE_DISPLAY_SSD1306 | - | - | - | - | - | - | x | +| USE_DISPLAY_MATRIX | - | - | - | - | - | - | x | +| USE_DISPLAY_ILI9341 | - | - | - | - | - | - | x | +| USE_DISPLAY_EPAPER_29 | - | - | - | - | - | - | x | ## Changelog Version 6.5.0 20190319 * Remove commands SetOption14 and SetOption63 as it has been superseded by command Interlock * Remove command SetOption35 0-255 for mDNS start-up delay (#4793) + * Remove support for MQTT_LIBRARY_TYPE, MQTT_ARDUINOMQTT and MQTT_TASMOTAMQTT (#5474) * Change webserver content handling from single String to small Chunks increasing RAM * Change code use of boolean to bool and byte to uint8_t * Change code uint8_t flags to bool flags diff --git a/sonoff/_changelog.ino b/sonoff/_changelog.ino index 58ead17cd..e0770b742 100644 --- a/sonoff/_changelog.ino +++ b/sonoff/_changelog.ino @@ -1,6 +1,9 @@ /* 6.5.0 20190319 * New Release * + * 6.4.2.22 20190315 + * Remove support for MQTT_LIBRARY_TYPE, MQTT_ARDUINOMQTT and MQTT_TASMOTAMQTT (#5474) + * * 6.4.1.21 20190309 * Fix exception on GUI Configure Logging and Configure Other (#5424) * Add support for sensor SCD30 (#5434) diff --git a/sonoff/my_user_config.h b/sonoff/my_user_config.h index 5214ad46c..b7e0846e4 100644 --- a/sonoff/my_user_config.h +++ b/sonoff/my_user_config.h @@ -230,16 +230,6 @@ // -- OTA ----------------------------------------- //#define USE_ARDUINO_OTA // Add optional support for Arduino OTA (+13k code) -/*-------------------------------------------------------------------------------------------*\ - * Select ONE of possible MQTT library types below -\*-------------------------------------------------------------------------------------------*/ - // Default MQTT driver for both non-TLS and TLS connections. Latest library version (20181016) does not block network if MQTT server is unavailable. -#define MQTT_LIBRARY_TYPE MQTT_PUBSUBCLIENT // Use PubSubClient library - // Alternative MQTT driver does not block network when MQTT server is unavailable. No TLS support -//#define MQTT_LIBRARY_TYPE MQTT_TASMOTAMQTT // Use TasmotaMqtt library (+4k4 (core 2.3.0), +14k4 (core 2.4.2 lwip2) code, +4k mem) - non-TLS only - // Alternative MQTT driver does not block network when MQTT server is unavailable. TLS should work but needs to be tested. -//#define MQTT_LIBRARY_TYPE MQTT_ARDUINOMQTT // Use arduino-mqtt (lwmqtt) library (+3k3 code, +2k mem) - // -- MQTT ---------------------------------------- #define MQTT_TELE_RETAIN 0 // Tele messages may send retain flag (0 = off, 1 = on) diff --git a/sonoff/sonoff.ino b/sonoff/sonoff.ino index 39f180c0b..bccd057cf 100755 --- a/sonoff/sonoff.ino +++ b/sonoff/sonoff.ino @@ -1682,8 +1682,8 @@ void PublishStatus(uint8_t payload) } if (((0 == payload) || (6 == payload)) && Settings.flag.mqtt_enabled) { - snprintf_P(mqtt_data, sizeof(mqtt_data), PSTR("{\"" D_CMND_STATUS D_STATUS6_MQTT "\":{\"" D_CMND_MQTTHOST "\":\"%s\",\"" D_CMND_MQTTPORT "\":%d,\"" D_CMND_MQTTCLIENT D_JSON_MASK "\":\"%s\",\"" D_CMND_MQTTCLIENT "\":\"%s\",\"" D_CMND_MQTTUSER "\":\"%s\",\"MqttType\":%d,\"" D_JSON_MQTT_COUNT "\":%d,\"MAX_PACKET_SIZE\":%d,\"KEEPALIVE\":%d}}"), - Settings.mqtt_host, Settings.mqtt_port, Settings.mqtt_client, mqtt_client, Settings.mqtt_user, MqttLibraryType(), MqttConnectCount(), MQTT_MAX_PACKET_SIZE, MQTT_KEEPALIVE); + snprintf_P(mqtt_data, sizeof(mqtt_data), PSTR("{\"" D_CMND_STATUS D_STATUS6_MQTT "\":{\"" D_CMND_MQTTHOST "\":\"%s\",\"" D_CMND_MQTTPORT "\":%d,\"" D_CMND_MQTTCLIENT D_JSON_MASK "\":\"%s\",\"" D_CMND_MQTTCLIENT "\":\"%s\",\"" D_CMND_MQTTUSER "\":\"%s\",\"" D_JSON_MQTT_COUNT "\":%d,\"MAX_PACKET_SIZE\":%d,\"KEEPALIVE\":%d}}"), + Settings.mqtt_host, Settings.mqtt_port, Settings.mqtt_client, mqtt_client, Settings.mqtt_user, MqttConnectCount(), MQTT_MAX_PACKET_SIZE, MQTT_KEEPALIVE); MqttPublishPrefixTopic_P(option, PSTR(D_CMND_STATUS "6")); } diff --git a/sonoff/sonoff_post.h b/sonoff/sonoff_post.h index fe5c5c08d..bcbc8f2ad 100755 --- a/sonoff/sonoff_post.h +++ b/sonoff/sonoff_post.h @@ -158,8 +158,6 @@ void KNX_CB_Action(message_t const &msg, void *arg); #ifndef USE_SMARTCONFIG #define USE_SMARTCONFIG // Add support for Wifi SmartConfig as initial wifi configuration tool (+23k code, +0.6k mem) #endif -#undef MQTT_LIBRARY_TYPE -#define MQTT_LIBRARY_TYPE MQTT_PUBSUBCLIENT // Use PubSubClient library #undef USE_ARDUINO_OTA // Disable support for Arduino OTA //#undef USE_DOMOTICZ // Disable Domoticz #undef USE_HOME_ASSISTANT // Disable Home Assistant diff --git a/sonoff/sonoff_version.h b/sonoff/sonoff_version.h index 0e9c322ac..b9516367a 100644 --- a/sonoff/sonoff_version.h +++ b/sonoff/sonoff_version.h @@ -20,7 +20,7 @@ #ifndef _SONOFF_VERSION_H_ #define _SONOFF_VERSION_H_ -#define VERSION 0x06050000 +#define VERSION 0x06040116 #define D_PROGRAMNAME "Sonoff-Tasmota" #define D_AUTHOR "Theo Arends" diff --git a/sonoff/support_features.ino b/sonoff/support_features.ino index c69b8e671..f5229e81f 100644 --- a/sonoff/support_features.ino +++ b/sonoff/support_features.ino @@ -56,10 +56,10 @@ void GetFeatures(void) feature_drv1 |= 0x00000400; // xdrv_01_mqtt.ino #endif #if (MQTT_LIBRARY_TYPE == MQTT_TASMOTAMQTT) - feature_drv1 |= 0x00000800; // xdrv_01_mqtt.ino +// feature_drv1 |= 0x00000800; // xdrv_01_mqtt.ino #endif #if (MQTT_LIBRARY_TYPE == MQTT_ESPMQTTARDUINO) // Obsolete since 6.2.1.11 - feature_drv1 |= 0x00001000; // xdrv_01_mqtt.ino +// feature_drv1 |= 0x00001000; // xdrv_01_mqtt.ino #endif #ifdef MQTT_HOST_DISCOVERY feature_drv1 |= 0x00002000; // xdrv_01_mqtt.ino @@ -116,7 +116,7 @@ void GetFeatures(void) feature_drv1 |= 0x40000000; // support.ino #endif #if (MQTT_LIBRARY_TYPE == MQTT_ARDUINOMQTT) - feature_drv1 |= 0x80000000; // xdrv_01_mqtt.ino +// feature_drv1 |= 0x80000000; // xdrv_01_mqtt.ino #endif /*********************************************************************************************/ diff --git a/sonoff/xdrv_01_webserver.ino b/sonoff/xdrv_01_webserver.ino index f243b1b11..d8ab7b56e 100644 --- a/sonoff/xdrv_01_webserver.ino +++ b/sonoff/xdrv_01_webserver.ino @@ -294,9 +294,7 @@ const char HTTP_FORM_LOGIN[] PROGMEM = const char HTTP_FORM_TEMPLATE[] PROGMEM = "