Streamline example configurations (#15)

This commit is contained in:
Sebastian Muszynski
2023-02-09 08:28:17 +01:00
committed by GitHub
parent 224fffd0b6
commit f58434084a
12 changed files with 97 additions and 33 deletions

View File

@@ -164,11 +164,11 @@ jobs:
shell: bash
run: 'echo -e "wifi_ssid: ssid\nwifi_password: password\nmqtt_host: host\nmqtt_username: username\nmqtt_password: password" > tests/secrets.yaml'
- run: |
esphome -s external_components_source components config esp32-ble-example.yaml
esphome -s external_components_source components config esp32-ble-example-faker.yaml
- run: |
esphome -s external_components_source components config esp8266-solar-charger-example.yaml
esphome -s external_components_source components config esp8266-charger-example.yaml
esphome -s external_components_source components config esp8266-charging-converter-example.yaml
esphome -s external_components_source components config esp8266-solar-charger-example-faker.yaml
esphome -s external_components_source components config esp8266-charger-example-faker.yaml
esphome -s external_components_source components config esp8266-charging-converter-example-faker.yaml
- run: |
esphome -s external_components_source ../components config tests/esp8266-fake-charger.yaml
esphome -s external_components_source ../components config tests/esp8266-fake-charging-converter.yaml
@@ -210,8 +210,8 @@ jobs:
shell: bash
run: 'echo -e "wifi_ssid: ssid\nwifi_password: password\nmqtt_host: host\nmqtt_username: username\nmqtt_password: password" > secrets.yaml'
- run: |
esphome -s external_components_source components compile esp32-ble-example.yaml
esphome -s external_components_source components compile esp32-ble-example-faker.yaml
- run: |
esphome -s external_components_source components compile esp8266-solar-charger-example.yaml
esphome -s external_components_source components compile esp8266-charger-example.yaml
esphome -s external_components_source components compile esp8266-charging-converter-example.yaml
esphome -s external_components_source components compile esp8266-solar-charger-example-faker.yaml
esphome -s external_components_source components compile esp8266-charger-example-faker.yaml
esphome -s external_components_source components compile esp8266-charging-converter-example-faker.yaml

View File

@@ -27,7 +27,7 @@ CONFIG_SCHEMA = (
): cv.positive_time_period_milliseconds,
}
)
.extend(cv.polling_component_schema("2s"))
.extend(cv.polling_component_schema("never"))
.extend(uart.UART_DEVICE_SCHEMA)
)

View File

@@ -0,0 +1,10 @@
<<: !include esp8266-charger-example.yaml
logger:
level: VERY_VERBOSE
logs:
component: DEBUG
scheduler: INFO
binary_sensor: DEBUG
sensor: DEBUG
text_sensor: DEBUG

View File

@@ -0,0 +1,18 @@
<<: !include esp8266-charger-example-debug.yaml
uart:
- id: uart0
baud_rate: 1000
tx_pin: ${tx_pin}
rx_pin: ${rx_pin}
debug:
direction: BOTH
dummy_receiver: false
votronic:
- id: votronic0
uart_id: uart0
rx_timeout: ${rx_timeout}
throttle: 0ms
update_interval: 1s
enable_fake_traffic: true

View File

@@ -41,16 +41,12 @@ uart:
baud_rate: 1000
tx_pin: ${tx_pin}
rx_pin: ${rx_pin}
debug:
direction: BOTH
dummy_receiver: false
votronic:
- id: votronic0
uart_id: uart0
update_interval: 2s
rx_timeout: ${rx_timeout}
enable_fake_traffic: false
throttle: 2s
binary_sensor:
- platform: votronic

View File

@@ -0,0 +1,10 @@
<<: !include esp8266-charging-converter-example.yaml
logger:
level: VERY_VERBOSE
logs:
component: DEBUG
scheduler: INFO
binary_sensor: DEBUG
sensor: DEBUG
text_sensor: DEBUG

View File

@@ -0,0 +1,18 @@
<<: !include esp8266-charging-converter-example-debug.yaml
uart:
- id: uart0
baud_rate: 1000
tx_pin: ${tx_pin}
rx_pin: ${rx_pin}
debug:
direction: BOTH
dummy_receiver: false
votronic:
- id: votronic0
uart_id: uart0
rx_timeout: ${rx_timeout}
throttle: 0ms
update_interval: 1s
enable_fake_traffic: true

View File

@@ -41,16 +41,12 @@ uart:
baud_rate: 1000
tx_pin: ${tx_pin}
rx_pin: ${rx_pin}
debug:
direction: BOTH
dummy_receiver: false
votronic:
- id: votronic0
uart_id: uart0
update_interval: 2s
rx_timeout: ${rx_timeout}
enable_fake_traffic: false
throttle: 2s
binary_sensor:
- platform: votronic

View File

@@ -0,0 +1,10 @@
<<: !include esp8266-solar-charger-example.yaml
logger:
level: VERY_VERBOSE
logs:
component: DEBUG
scheduler: INFO
binary_sensor: DEBUG
sensor: DEBUG
text_sensor: DEBUG

View File

@@ -0,0 +1,18 @@
<<: !include esp8266-solar-charger-example-debug.yaml
uart:
- id: uart0
baud_rate: 1000
tx_pin: ${tx_pin}
rx_pin: ${rx_pin}
debug:
direction: BOTH
dummy_receiver: false
votronic:
- id: votronic0
uart_id: uart0
rx_timeout: ${rx_timeout}
throttle: 0ms
update_interval: 1s
enable_fake_traffic: true

View File

@@ -25,15 +25,7 @@ wifi:
password: !secret wifi_password
ota:
logger:
level: VERY_VERBOSE
logs:
component: DEBUG
scheduler: INFO
binary_sensor: DEBUG
sensor: DEBUG
text_sensor: DEBUG
# If you use Home Assistant please remove this `mqtt` section and uncomment the native `api` component!
# api:
@@ -49,16 +41,12 @@ uart:
baud_rate: 1000
tx_pin: ${tx_pin}
rx_pin: ${rx_pin}
debug:
direction: BOTH
dummy_receiver: false
votronic:
- id: votronic0
uart_id: uart0
update_interval: 2s
rx_timeout: ${rx_timeout}
enable_fake_traffic: false
throttle: 2s
binary_sensor:
- platform: votronic

View File

@@ -1,3 +1,3 @@
#!/bin/bash
esphome -s external_components_source components ${1:-run} ${2:-esp8266-example-faker.yaml}
esphome -s external_components_source components ${1:-run} ${2:-esp8266-solar-charger-example-faker.yaml}