From e4e315f723c745dd81ceea27f018d63ce14a8fec Mon Sep 17 00:00:00 2001 From: Otto Winter Date: Mon, 11 Feb 2019 16:50:10 +0100 Subject: [PATCH] Revert "Upgrade espressif32 package to 1.6.0 (#355)" (#422) * Revert "Upgrade espressif32 package to 1.6.0 (#355)" This reverts commit e347cb538d428c48e7661a327ddff0b1a08d6792. * Fix revert * Fix --- esphomeyaml/components/api.py | 2 +- esphomeyaml/core_config.py | 2 +- esphomeyaml/dashboard/static/favicon.ico | Bin 15086 -> 15086 bytes esphomeyaml/dashboard/templates/index.html | 10 --- esphomeyaml/pins.py | 45 ++---------- esphomeyaml/writer.py | 78 +++++++++++++-------- tests/test2.yaml | 6 ++ 7 files changed, 62 insertions(+), 81 deletions(-) diff --git a/esphomeyaml/components/api.py b/esphomeyaml/components/api.py index 5a7cfd9cfc..4775ef626a 100644 --- a/esphomeyaml/components/api.py +++ b/esphomeyaml/components/api.py @@ -42,7 +42,7 @@ BUILD_FLAGS = '-DUSE_API' def lib_deps(config): if CORE.is_esp32: - return 'AsyncTCP@1.0.3' + return 'AsyncTCP@1.0.1' if CORE.is_esp8266: return 'ESPAsyncTCP@1.1.3' raise NotImplementedError diff --git a/esphomeyaml/core_config.py b/esphomeyaml/core_config.py index 4d413407b7..1bd510a9e4 100644 --- a/esphomeyaml/core_config.py +++ b/esphomeyaml/core_config.py @@ -123,7 +123,7 @@ PLATFORMIO_ESP8266_LUT = { PLATFORMIO_ESP32_LUT = { '1.0.0': 'espressif32@1.4.0', - 'RECOMMENDED': 'espressif32@1.6.0', + 'RECOMMENDED': 'espressif32@1.5.0', 'LATEST': 'espressif32', 'DEV': ARDUINO_VERSION_ESP32_DEV, } diff --git a/esphomeyaml/dashboard/static/favicon.ico b/esphomeyaml/dashboard/static/favicon.ico index 5aaaf3fb2495fb042ffc7d2bffca926d7d6f85d2..88dcd7e2d1ad8943943707409de2a8eb8089924e 100644 GIT binary patch literal 15086 zcmeHO2XvHG7M_qw4IPx0P_t5`NT?e6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`)B)#apuPUbIfUA z7=hX;X8i`!tgnL&W{gGM2|_`-&YW7m)7)9VkKY?vZ`PaDM!;M?c#gTXeS)_NC$0As z>5vDF?0(p!ISg%;uajj{Af5 z9E1OJNnwvG!oCD9Ca$(wLi#%P677r9>3pm;{XzDyv7AAz{K|vPr_}Q`dnpy35C{tNh0}g;s1EG-Wx?lMKKCFTLcuA zl$69cI#+(}x6b(@Kt1F2Y$#_c;bfRZd>Y|IaCDQ=Jw%&2t6Y!#n6$p5YG2bHC={P- zhf2?fN(d%;cHN*0XpEi*+M_fjr7HmGw0E6x(K}6tWAyUTZ@HwQo0SVZErsU#2AltK K5|NE#uke2>FT?o& diff --git a/esphomeyaml/dashboard/templates/index.html b/esphomeyaml/dashboard/templates/index.html index a3a330e8ae..42e6ab8162 100644 --- a/esphomeyaml/dashboard/templates/index.html +++ b/esphomeyaml/dashboard/templates/index.html @@ -295,16 +295,6 @@ - - - - - - - - - - diff --git a/esphomeyaml/pins.py b/esphomeyaml/pins.py index f16c9fed57..2a8fb7ec06 100644 --- a/esphomeyaml/pins.py +++ b/esphomeyaml/pins.py @@ -127,18 +127,9 @@ ESP32_BOARD_PINS = { 'SW2': 2, 'SW3': 0, 'POT1': 32, 'POT2': 33, 'PIEZO1': 19, 'PIEZO2': 18, 'PHOTO': 25, 'DHT_PIN': 26, 'S1': 4, 'S2': 16, 'S3': 18, 'S4': 19, 'S5': 21, 'SDA': 27, 'SCL': 14, 'SS': 19, 'MOSI': 21, 'MISO': 22, 'SCK': 23}, - 'bpi-bit': {'BUZZER': 25, 'BUTTON_A': 35, 'BUTTON_B': 27, 'RGB_LED': 4, 'LIGHT_SENSOR1': 36, - 'LIGHT_SENSOR2': 39, 'TEMPERATURE_SENSOR': 34, 'MPU9250_INT': 0, 'P0': 25, 'P1': 32, - 'P2': 33, 'P3': 13, 'P4': 15, 'P5': 35, 'P6': 12, 'P7': 14, 'P8': 16, 'P9': 17, - 'P10': 26, 'P11': 27, 'P12': 2, 'P13': 18, 'P14': 19, 'P15': 23, 'P16': 5, - 'P19': 22, 'P20': 21, 'DAC1': 26}, - 'd-duino-32': {'SDA': 5, 'SCL': 4, 'SS ': 15, 'MOSI ': 13, 'MISO ': 12, 'SCK ': 14, 'D1': 5, - 'D2': 4, 'D3': 0, 'D4': 2, 'D5': 14, 'D6': 12, 'D7': 13, 'D8': 15, 'D9': 3, - 'D10': 1}, 'esp-wrover-kit': {}, 'esp32-evb': {'BUTTON': 34, 'SDA': 13, 'SCL': 16, 'SS': 17, 'MOSI': 2, 'MISO': 15, 'SCK': 14}, 'esp32-gateway': {'LED': 33, 'BUTTON': 34, 'SCL': 16, 'SDA': 17}, - 'esp32-poe': {'BUTTON': 34, 'SDA': 13, 'SCL': 16, 'MOSI': 2, 'MISO': 15, 'SCK': 14}, 'esp320': {'LED': 5, 'SDA': 2, 'SCL': 14, 'SS': 15, 'MOSI': 13, 'MISO': 12, 'SCK': 14}, 'esp32dev': {}, 'esp32doit-devkit-v1': {'LED': 2}, @@ -151,15 +142,12 @@ ESP32_BOARD_PINS = { 'A0': 26, 'A1': 25, 'A2': 34, 'A4': 36, 'A5': 4, 'A6': 14, 'A7': 32, 'A8': 15, 'A9': 33, 'A10': 27, 'A11': 12, 'A12': 13, 'A13': 35}, 'firebeetle32': {'LED': 2}, - 'fm-devkit': {'LED': 5, 'SW1': 4, 'SW2': 18, 'SW3': 19, 'SW4': 21, 'I2S_MCLK': 2, - 'I2S_LRCLK': 25, 'I2S_SCLK': 26, 'I2S_DOUT': 22, 'D0': 34, 'D1': 35, 'D2': 32, - 'D3': 33, 'D4': 27, 'D5': 14, 'D6': 12, 'D7': 13, 'D8': 15, 'D9': 23, 'D10': 0, - 'SDA': 16, 'SCL': 17}, 'heltec_wifi_kit_32': {'LED': 25, 'BUTTON': 0, 'A1': 37, 'A2': 38}, 'heltec_wifi_lora_32': {'LED': 25, 'BUTTON': 0, 'SDA': 4, 'SCL': 15, 'SS': 18, 'MOSI': 27, - 'SCK': 5, 'A1': 37, 'A2': 38, 'OLED_SCL': 15, 'OLED_SDA': 4, - 'OLED_RST': 16, 'LORA_SCK': 5, 'LORA_MOSI': 27, 'LORA_MISO': 19, - 'LORA_CS': 18, 'LORA_RST': 14, 'LORA_IRQ': 26}, + 'SCK': 5, 'A1': 37, 'A2': 38, 'T8': 32, 'T9': 33, 'DAC1': 26, + 'DAC2': 25, 'OLED_SCL': 15, 'OLED_SDA': 4, 'OLED_RST': 16, + 'LORA_SCK': 5, 'LORA_MOSI': 27, 'LORA_MISO': 19, 'LORA_CS': 18, + 'LORA_RST': 14, 'LORA_IRQ': 26}, 'hornbill32dev': {'LED': 13, 'BUTTON': 0}, 'hornbill32minima': {'SS': 2}, 'intorobot': {'LED': 4, 'LED_RED': 27, 'LED_GREEN': 21, 'LED_BLUE': 22, @@ -171,12 +159,6 @@ ESP32_BOARD_PINS = { 'lolin_d32': {'LED': 5, 'VBAT': 35}, 'lolin_d32_pro': {'LED': 5, 'VBAT': 35, 'TF_CS': 4, 'TS_CS': 12, 'TFT_CS': 14, 'TFT_LED': 32, 'TFT_RST': 33, 'TFT_DC': 27}, - 'lopy': {'LORA_SCK': 5, 'LORA_MISO': 19, 'LORA_MOSI': 27, 'LORA_CS': 17, 'LORA_RST': 18, - 'LORA_IRQ': 23, 'LED': 0, 'ANT_SELECT': 16, 'SDA': 12, 'SCL': 13, 'SS': 17, - 'MOSI': 22, 'MISO': 37, 'SCK': 13, 'A1': 37, 'A2': 38}, - 'lopy4': {'LORA_SCK': 5, 'LORA_MISO': 19, 'LORA_MOSI': 27, 'LORA_CS': 18, 'LORA_IRQ': 23, - 'LED': 0, 'ANT_SELECT': 21, 'SDA': 12, 'SCL': 13, 'SS': 18, 'MOSI': 22, 'MISO': 37, - 'SCK': 13, 'A1': 37, 'A2': 38}, 'm5stack-core-esp32': {'TXD2': 17, 'RXD2': 16, 'G23': 23, 'G19': 19, 'G18': 18, 'G3': 3, 'G16': 16, 'G21': 21, 'G2': 2, 'G12': 12, 'G15': 15, 'G35': 35, 'G36': 36, 'G25': 25, 'G26': 26, 'G1': 1, 'G17': 17, 'G22': 22, 'G5': 5, @@ -202,27 +184,14 @@ ESP32_BOARD_PINS = { 'nodemcu-32s': {'LED': 2, 'BUTTON': 0}, 'odroid_esp32': {'LED': 2, 'SDA': 15, 'SCL': 4, 'SS': 22, 'ADC1': 35, 'ADC2': 36}, 'onehorse32dev': {'LED': 5, 'BUTTON': 0, 'A1': 37, 'A2': 38}, - 'oroca_edubot': {'LED': 13, 'TX': 17, 'RX': 16, 'SDA': 23, 'SS': 2, 'MOSI': 18, 'SCK': 5, - 'A0': 34, 'A1': 39, 'A2': 36, 'A3': 33, 'D0': 4, 'D1': 16, 'D2': 17, 'D3': 22, - 'D4': 23, 'D5': 5, 'D6': 18, 'D7': 19, 'D8': 33, 'VBAT': 35}, 'pico32': {}, 'pocket_32': {'LED': 16}, 'quantum': {}, 'ttgo-lora32-v1': {'LED': 2, 'BUTTON': 0, 'SS': 18, 'MOSI': 27, 'SCK': 5, 'A1': 37, 'A2': 38, - 'OLED_SDA': 4, 'OLED_SCL': 15, 'OLED_RST': 16, 'LORA_SCK': 5, - 'LORA_MISO': 19, 'LORA_MOSI': 27, 'LORA_CS': 18, 'LORA_RST': 14, - 'LORA_IRQ': 26}, - 'ttgo-t-beam': {'LORA_SCK': 5, 'LORA_MISO': 19, 'LORA_MOSI': 27, 'LORA_CS': 18, 'LORA_RST': 23, - 'LORA_IRQ': 26, 'LORA_IO1': 33, 'LORA_IO2': 32, 'SS': 18, 'MOSI': 27, 'SCK': 5, - 'T8': 32, 'T9': 33, 'DAC2': 25}, - 'turta_iot_node': {'LED': 13, 'TX': 10, 'RX': 9, 'SDA': 23, 'SS': 21, 'MOSI': 18, 'SCK': 5, - 'A0': 4, 'A1': 25, 'A2': 26, 'A3': 27, 'A8': 38, 'T1': 25, 'T2': 26, - 'T3': 27, 'T4': 32, 'T5': 33, 'T6': 34, 'T7': 35, 'T8': 22, 'T9': 23, - 'T10': 10, 'T11': 9, 'T12': 21, 'T13': 5, 'T14': 18, 'T15': 19, - 'T16': 37, 'T17': 14, 'T18': 2, 'T19': 38}, + 'T8': 32, 'T9': 33, 'DAC1': 26, 'DAC2': 25, 'OLED_SDA': 4, 'OLED_SCL': 15, + 'OLED_RST': 16, 'LORA_SCK': 5, 'LORA_MISO': 19, 'LORA_MOSI': 27, + 'LORA_CS': 18, 'LORA_RST': 14, 'LORA_IRQ': 26}, 'wemosbat': 'pocket_32', - 'wesp32': {'SCL': 4, 'SDA': 2, 'MISO': 32, 'ETH_PHY_ADDR': 0, 'ETH_PHY_MDC': 16, - 'ETH_PHY_MDIO': 17}, 'widora-air': {'LED': 25, 'BUTTON': 0, 'SDA': 23, 'SCL': 19, 'MOSI': 16, 'MISO': 17, 'A1': 39, 'A2': 35, 'A3': 25, 'A4': 26, 'A5': 14, 'A6': 12, 'A7': 15, 'A8': 13, 'A9': 2, 'D0': 19, 'D1': 23, 'D2': 18, 'D3': 17, 'D4': 16, 'D5': 5, 'D6': 4, 'T0': 19, diff --git a/esphomeyaml/writer.py b/esphomeyaml/writer.py index 60de4353dc..575d57db3c 100644 --- a/esphomeyaml/writer.py +++ b/esphomeyaml/writer.py @@ -8,10 +8,10 @@ import re import shutil from esphomeyaml.config import iter_components -from esphomeyaml.const import CONF_ARDUINO_VERSION, CONF_BRANCH, CONF_COMMIT, \ - CONF_ESPHOMELIB_VERSION, CONF_ESPHOMEYAML, CONF_LOCAL, CONF_REPOSITORY, CONF_TAG, \ - CONF_USE_CUSTOM_CODE, CONF_PLATFORMIO_OPTIONS, CONF_BOARD_FLASH_MODE, \ - ARDUINO_VERSION_ESP8266_DEV +from esphomeyaml.const import ARDUINO_VERSION_ESP32_DEV, CONF_ARDUINO_VERSION, \ + CONF_BRANCH, CONF_COMMIT, CONF_ESPHOMELIB_VERSION, CONF_ESPHOMEYAML, \ + CONF_LOCAL, CONF_REPOSITORY, CONF_TAG, CONF_USE_CUSTOM_CODE, CONF_PLATFORMIO_OPTIONS, \ + CONF_BOARD_FLASH_MODE, ARDUINO_VERSION_ESP8266_DEV from esphomeyaml.core import CORE, EsphomeyamlError from esphomeyaml.core_config import VERSION_REGEX, LIBRARY_URI_REPO, GITHUB_ARCHIVE_ZIP from esphomeyaml.helpers import mkdir_p, run_system_command @@ -279,9 +279,27 @@ def gather_lib_deps(): if CORE.is_esp32: lib_deps |= { 'Preferences', # Preferences helper + 'AsyncTCP@1.0.1', # Pin AsyncTCP version } + lib_deps.discard('AsyncTCP@1.0.3') + + # Manual fix for AsyncTCP + if CORE.config[CONF_ESPHOMEYAML].get(CONF_ARDUINO_VERSION) == ARDUINO_VERSION_ESP32_DEV: + lib_deps.add('AsyncTCP@1.0.3') + lib_deps.discard('AsyncTCP@1.0.1') + elif CORE.is_esp8266: + lib_deps.add('ESPAsyncTCP@1.1.3') # avoid changing build flags order - return list(sorted(x for x in lib_deps if x)) + lib_deps_l = list(lib_deps) + lib_deps_l.sort() + + # Move AsyncTCP to front, see https://github.com/platformio/platformio-core/issues/2115 + if 'AsyncTCP@1.0.3' in lib_deps_l: + lib_deps_l.insert(0, lib_deps_l.pop(lib_deps_l.index('AsyncTCP@1.0.3'))) + if 'AsyncTCP@1.0.1' in lib_deps_l: + lib_deps_l.insert(0, lib_deps_l.pop(lib_deps_l.index('AsyncTCP@1.0.1'))) + + return lib_deps_l def gather_build_flags(): @@ -344,32 +362,30 @@ def get_ini_content(): data['board_build.flash_mode'] = flash_mode if not CORE.config[CONF_ESPHOMEYAML][CONF_USE_CUSTOM_CODE]: - if CORE.is_esp8266: - # On ESP8266, we can disable LDF - data['lib_ldf_mode'] = 'off' - elif CORE.is_esp32: - # On ESP32, we need to enable LDF - # and can manually remove all libraries we don't need - data['lib_ldf_mode'] = 'chain' - REMOVABLE_LIBRARIES = [ - 'ArduinoOTA', - 'ESPmDNS', - 'Update', - 'Wire', - 'FastLED', - 'NeoPixelBus', - 'ESP Async WebServer', - 'AsyncMqttClient', - ] - ignore = [] - for x in REMOVABLE_LIBRARIES: - for o in lib_deps: - if x in o: - break - else: - ignore.append(x) - if ignore: - data['lib_ignore'] = ignore + # Ignore libraries that are not explicitly used, but may + # be added by LDF + data['lib_ldf_mode'] = 'chain' + REMOVABLE_LIBRARIES = [ + 'ArduinoOTA', + 'ESPmDNS', + 'Update', + 'Wire', + 'FastLED', + 'NeoPixelBus', + 'ESP Async WebServer', + 'AsyncMqttClient', + 'AsyncTCP', + 'ESPAsyncTCP', + ] + ignore = [] + for x in REMOVABLE_LIBRARIES: + for o in lib_deps: + if o.startswith(x): + break + else: + ignore.append(x) + if ignore: + data['lib_ignore'] = ignore data.update(CORE.config[CONF_ESPHOMEYAML].get(CONF_PLATFORMIO_OPTIONS, {})) diff --git a/tests/test2.yaml b/tests/test2.yaml index 40c00b2355..93e54fb8fb 100644 --- a/tests/test2.yaml +++ b/tests/test2.yaml @@ -47,6 +47,8 @@ ota: logger: level: DEBUG +web_server: + deep_sleep: run_duration: 20s sleep_duration: 50s @@ -161,6 +163,10 @@ binary_sensor: entity_id: binary_sensor.hello_world id: ha_hello_world_binary +remote_receiver: + pin: GPIO32 + dump: [] + esp32_ble_tracker: scan_interval: 300s