From 510e53de708f75e7866fc87965d4e565f4a8a7e1 Mon Sep 17 00:00:00 2001 From: Otto Winter Date: Sun, 26 May 2019 10:31:29 +0200 Subject: [PATCH] Add core version 2.5.2 --- esphome/components/pulse_width/sensor.py | 2 +- esphome/components/status/status_binary_sensor.cpp | 1 + esphome/const.py | 1 + esphome/core_config.py | 5 +++-- 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/esphome/components/pulse_width/sensor.py b/esphome/components/pulse_width/sensor.py index 0227adffce..8328da2ac0 100644 --- a/esphome/components/pulse_width/sensor.py +++ b/esphome/components/pulse_width/sensor.py @@ -10,7 +10,7 @@ PulseWidthSensor = pulse_width_ns.class_('PulseWidthSensor', sensor.Sensor, cg.P CONFIG_SCHEMA = sensor.sensor_schema(UNIT_SECOND, ICON_TIMER, 3).extend({ cv.GenerateID(): cv.declare_id(PulseWidthSensor), - cv.Required(CONF_PIN): cv.All(pins.internal_gpio_input_pullup_pin_schema, + cv.Required(CONF_PIN): cv.All(pins.internal_gpio_input_pin_schema, pins.validate_has_interrupt), }).extend(cv.polling_component_schema('60s')) diff --git a/esphome/components/status/status_binary_sensor.cpp b/esphome/components/status/status_binary_sensor.cpp index d004c70b95..7fbeb8c171 100644 --- a/esphome/components/status/status_binary_sensor.cpp +++ b/esphome/components/status/status_binary_sensor.cpp @@ -1,6 +1,7 @@ #include "status_binary_sensor.h" #include "esphome/core/log.h" #include "esphome/core/util.h" +#include "esphome/core/defines.h" #ifdef USE_MQTT #include "esphome/components/mqtt/mqtt_client.h" diff --git a/esphome/const.py b/esphome/const.py index d58ed406c7..d3da18448e 100644 --- a/esphome/const.py +++ b/esphome/const.py @@ -19,6 +19,7 @@ ARDUINO_VERSION_ESP8266_DEV = 'https://github.com/platformio/platform-espressif8 '/stage' ARDUINO_VERSION_ESP8266_2_5_0 = 'espressif8266@2.0.0' ARDUINO_VERSION_ESP8266_2_5_1 = 'espressif8266@2.1.0' +ARDUINO_VERSION_ESP8266_2_5_2 = 'espressif8266@2.2.0' ARDUINO_VERSION_ESP8266_2_3_0 = 'espressif8266@1.5.0' SOURCE_FILE_EXTENSIONS = {'.cpp', '.hpp', '.h', '.c', '.tcc', '.ino'} HEADER_FILE_EXTENSIONS = {'.h', '.hpp', '.tcc'} diff --git a/esphome/core_config.py b/esphome/core_config.py index a2663b8db8..d02b7c98de 100644 --- a/esphome/core_config.py +++ b/esphome/core_config.py @@ -11,7 +11,7 @@ from esphome.const import ARDUINO_VERSION_ESP32_DEV, ARDUINO_VERSION_ESP8266_DEV CONF_NAME, CONF_ON_BOOT, CONF_ON_LOOP, CONF_ON_SHUTDOWN, CONF_PLATFORM, \ CONF_PLATFORMIO_OPTIONS, CONF_PRIORITY, CONF_TRIGGER_ID, \ CONF_ESP8266_RESTORE_FROM_FLASH, __version__, ARDUINO_VERSION_ESP8266_2_3_0, \ - ARDUINO_VERSION_ESP8266_2_5_0, ARDUINO_VERSION_ESP8266_2_5_1 + ARDUINO_VERSION_ESP8266_2_5_0, ARDUINO_VERSION_ESP8266_2_5_1, ARDUINO_VERSION_ESP8266_2_5_2 from esphome.core import CORE, coroutine_with_priority from esphome.pins import ESP8266_FLASH_SIZES, ESP8266_LD_SCRIPTS @@ -44,6 +44,7 @@ def validate_board(value): validate_platform = cv.one_of('ESP32', 'ESP8266', upper=True) PLATFORMIO_ESP8266_LUT = { + '2.5.2': 'espressif8266@2.2.0', '2.5.1': 'espressif8266@2.1.0', '2.5.0': 'espressif8266@2.0.1', '2.4.2': 'espressif8266@1.8.0', @@ -193,7 +194,7 @@ def to_code(config): 'espressif8266@1.6.0'): ld_script = ld_scripts[0] elif CORE.arduino_version in (ARDUINO_VERSION_ESP8266_DEV, ARDUINO_VERSION_ESP8266_2_5_0, - ARDUINO_VERSION_ESP8266_2_5_1): + ARDUINO_VERSION_ESP8266_2_5_1, ARDUINO_VERSION_ESP8266_2_5_2): ld_script = ld_scripts[1] if ld_script is not None: