Created
October 12, 2021 18:28
-
-
Save dmslabsbr/adbea397bce1c6dee0891017a273383b to your computer and use it in GitHub Desktop.
ESPHome Somfy Blind - Hass.io
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
esphome: | |
name: esp_somfy | |
platform: ESP8266 | |
board: d1_mini_lite | |
arduino_version: [email protected] | |
includes: | |
- RFsomfy.h | |
- SomfyRts.h | |
- SomfyRts.cpp | |
# libraries: | |
# - Ticker | |
comment: versao 2 - 10/abr/2020 | |
wifi: | |
ssid: !secret wifi_ssid | |
password: !secret wifi_pass | |
use_address: 192.168.50.12 | |
manual_ip: | |
static_ip: 192.168.50.12 | |
gateway: 192.168.50.1 | |
subnet: 255.255.255.0 | |
web_server: | |
port: 80 | |
# Enable logging | |
logger: | |
level: DEBUG | |
esp8266_store_log_strings_in_flash: False | |
baud_rate: 115200 | |
api: | |
password: !secret api_pass | |
ota: | |
password: !secret ota_pass | |
cover: | |
- platform: custom | |
lambda: |- | |
std::vector<Cover *> covers; | |
auto rfSomfy0 = new RFsomfy(0); | |
rfSomfy0->set_code(1); // Set initial rolling code. After it works, remove these lines. | |
App.register_component(rfSomfy0); | |
auto rfSomfy1 = new RFsomfy(1); | |
App.register_component(rfSomfy1); | |
auto rfSomfy2 = new RFsomfy(2); | |
App.register_component(rfSomfy2); | |
covers.push_back(rfSomfy0); | |
covers.push_back(rfSomfy1); | |
covers.push_back(rfSomfy2); | |
return {covers}; | |
covers: | |
- name: "Blind 2" | |
device_class: shade | |
id: somfy0 | |
- name: "Veneziana casal" | |
device_class: shutter | |
id: somfy1 | |
- name: "Veneziana roxo" | |
device_class: shutter | |
id: somfy2 | |
text_sensor: | |
- platform: version | |
name: "RFsomfy version" | |
- platform: custom | |
lambda: |- | |
auto rfSomfyInfo = new RFsomfyInfo(); | |
App.register_component(rfSomfyInfo); | |
return {rfSomfyInfo}; | |
text_sensors: | |
name: "RFsomfy info" | |
binary_sensor: | |
- platform: status | |
name: "RFsomfy status" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment