diff --git a/docs/en/compile_coverage.md b/docs/en/compile_coverage.md index aec744b..2966d13 100644 --- a/docs/en/compile_coverage.md +++ b/docs/en/compile_coverage.md @@ -4,7 +4,7 @@ * common.yaml * power_meter_fronius.yaml * regulator_triac.yaml -* engine.yaml +* engine_progressive.yaml * energy_counter_theorical.yaml * temperature_limiter_DS18B20.yaml @@ -17,7 +17,7 @@ * regulator_mecanical_relay.yaml * temperature_limiter_home_assistant.yaml -## esp32-proxy-client +## esp8266-proxy-client * power_meter_proxy_client.yaml -* engine.yaml +* engine_progressive_with_bypass.yaml * regulator_solid_state_relay.yaml \ No newline at end of file diff --git a/docs/en/engine.md b/docs/en/engine_progressive.md similarity index 100% rename from docs/en/engine.md rename to docs/en/engine_progressive.md diff --git a/docs/en/engine_regulator_with_bypass.md b/docs/en/engine_progressive_with_bypass.md similarity index 100% rename from docs/en/engine_regulator_with_bypass.md rename to docs/en/engine_progressive_with_bypass.md diff --git a/docs/fr/engine.md b/docs/fr/engine_progressive.md similarity index 100% rename from docs/fr/engine.md rename to docs/fr/engine_progressive.md diff --git a/docs/fr/engine_regulator_with_bypass.md b/docs/fr/engine_progressive_with_bypass.md similarity index 100% rename from docs/fr/engine_regulator_with_bypass.md rename to docs/fr/engine_progressive_with_bypass.md diff --git a/esp32-proxy-client.yaml b/esp32-proxy-client.yaml index 3f67c26..29ddea7 100644 --- a/esp32-proxy-client.yaml +++ b/esp32-proxy-client.yaml @@ -53,9 +53,6 @@ substitutions: # Define ip address of Proxy Power Meter power_meter_ip_address: "192.168.1.30" - # Regulator -------------------------------------------------------------------- - regulator: "ac_dimmer" - # Regulator configuration # Define GPIO pin connected to AC Dimmer for gate and zero crossing detection. regulator_gate_pin: GPIO22 @@ -72,11 +69,15 @@ packages: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ file: solar_router/power_meter_proxy_client.yaml refresh: 1d + engine: + url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ + file: solar_router/engine_progressive_with_bypass.yaml + refresh: 1d regulator: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ file: solar_router/regulator_solid_state_relay.yaml refresh: 1d - solar_router: + bypass: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ - file: solar_router/engine.yaml + file: solar_router/regulator_mecanical_relay.yaml refresh: 1d diff --git a/esp32-standalone.yaml b/esp32-standalone.yaml index fabf97c..337244c 100644 --- a/esp32-standalone.yaml +++ b/esp32-standalone.yaml @@ -91,6 +91,6 @@ packages: refresh: 1d engine: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ - file: solar_router/engine.yaml + file: solar_router/engine_progressive.yaml refresh: 1d diff --git a/esp32-standalone_DS18B20.yaml b/esp32-standalone_DS18B20.yaml index 5ec706a..a9251d0 100644 --- a/esp32-standalone_DS18B20.yaml +++ b/esp32-standalone_DS18B20.yaml @@ -95,7 +95,7 @@ packages: refresh: 1d solar_router: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ - file: solar_router/engine.yaml + file: solar_router/engine_progressive.yaml refresh: 1d energy_counter: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ diff --git a/esp8266-proxy-client.yaml b/esp8266-proxy-client.yaml new file mode 100644 index 0000000..cdc3aae --- /dev/null +++ b/esp8266-proxy-client.yaml @@ -0,0 +1,73 @@ +# ---------------------------------------------------------------------------------------------------- +# ESPHome configuration - This part depends on your hardware target +# ---------------------------------------------------------------------------------------------------- + +esphome: + name: "esp8266" + friendly_name: ESP8266 + +esp8266: + board: esp01_1m + restore_from_flash: true + +# Enable logging +logger: + baud_rate: 115200 + level: INFO + logs: + component: ERROR + http_request.arduino: ERROR + +# Enable Home Assistant API +api: + encryption: + key: !secret proxy_api_encryption_key + +# WiFi connection +wifi: + ssid: !secret wifi_ssid + password: !secret wifi_password + # If you have a WiFi activity plannification, you may have to update the reboot timeout (Default: 15min) + reboot_timeout: 24h + +# ---------------------------------------------------------------------------------------------------- +# Customisation +# ---------------------------------------------------------------------------------------------------- + +# This part of the script is designed to be use for customisation. It shouldn't be necessary to +# edit other part of the script to perform configuration. +substitutions: + # Power meter source ----------------------------------------------------------- + # Define ip address of Proxy Power Meter + power_meter_ip_address: "192.168.1.28" + + # Regulator configuration + # Define GPIO pin connected to AC Dimmer for gate and zero crossing detection. + regulator_gate_pin: GPIO4 + + # LEDs ------------------------------------------------------------------------- + # Green LED is reflecting regulation status + # Yellow LED is reflecting power meter status + green_led_pin: GPIO1 + yellow_led_pin: GPIO2 + + relay_regulator_gate_pin: GPIO0 + bypass_timer_threshold: "30" + +packages: + power_meter: + url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ + file: solar_router/power_meter_proxy_client.yaml + refresh: 1d + engine: + url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ + file: solar_router/engine_progressive_with_bypass.yaml + refresh: 1d + regulator: + url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ + file: solar_router/regulator_solid_state_relay.yaml + refresh: 1d + bypass: + url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ + file: solar_router/regulator_mecanical_relay.yaml + refresh: 1d diff --git a/esp8266-standalone_on_off.yaml b/esp8266-standalone_on_off.yaml index 0084625..85c9907 100644 --- a/esp8266-standalone_on_off.yaml +++ b/esp8266-standalone_on_off.yaml @@ -56,10 +56,6 @@ substitutions: red_led_pin: GPIO4 packages: - common: - url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ - file: solar_router/common.yaml - refresh: 1d power_meter: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ file: solar_router/power_meter_home_assistant.yaml @@ -68,7 +64,7 @@ packages: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ file: solar_router/regulator_mecanical_relay.yaml refresh: 1d - solar_router: + engine: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ file: solar_router/engine_on_off.yaml refresh: 1d diff --git a/mkdocs.yml b/mkdocs.yml index 4e69c38..9e7f51d 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -26,7 +26,8 @@ nav: - Solid State Relay: regulator_solid_state_relay.md - Mecanical relay: regulator_mecanical_relay.md - Engine: - - Progressive regulation: engine.md + - Progressive regulation: engine_progressive.md + - Progressive with bypass: engine_progressive_with_bypass.md - ON/OFF regulation: engine_on_off.md - Energy Counter: - Theorical: energy_counter_theorical.md diff --git a/solar_router/engine.yaml b/solar_router/engine_progressive.yaml similarity index 100% rename from solar_router/engine.yaml rename to solar_router/engine_progressive.yaml diff --git a/solar_router/engine_regulator_with_bypass.yaml b/solar_router/engine_progressive_with_bypass.yaml similarity index 100% rename from solar_router/engine_regulator_with_bypass.yaml rename to solar_router/engine_progressive_with_bypass.yaml diff --git a/solar_router/regulator_solid_state_relay.yaml b/solar_router/regulator_solid_state_relay.yaml index 00801a6..29ca685 100644 --- a/solar_router/regulator_solid_state_relay.yaml +++ b/solar_router/regulator_solid_state_relay.yaml @@ -8,9 +8,9 @@ script: mode: single then: # Apply opening level on relay ldec output - - output.turn_on: relay_output + - output.turn_on: ssr_output - output.set_level: - id: relay_output + id: ssr_output level: !lambda return id(regulator_opening).state/100.0; # ---------------------------------------------------------------------------------------------------- @@ -20,6 +20,6 @@ script: # Control the relay through GPIO output: - platform: slow_pwm - id: relay_output + id: ssr_output pin: ${regulator_gate_pin} period: 330ms diff --git a/wt32-eth01-solar-water-heater.yaml b/wt32-eth01-solar-water-heater.yaml index 380a039..c1f68b7 100644 --- a/wt32-eth01-solar-water-heater.yaml +++ b/wt32-eth01-solar-water-heater.yaml @@ -99,9 +99,9 @@ packages: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ file: solar_router/regulator_triac.yaml refresh: 1d - solar_router: + engine: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/ - file: solar_router/engine.yaml + file: solar_router/engine_progressive.yaml refresh: 1d energy_counter: url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/