Added a3pool information for quick and easy things

This commit is contained in:
Nicolas Bachschwell 2022-05-23 19:52:46 +02:00
parent a415ca582f
commit 38abeff25d
Signed by: NBSgamesAT
GPG Key ID: B2F1E0D04F024688
2 changed files with 93 additions and 0 deletions

83
a3pool.yaml Normal file
View File

@ -0,0 +1,83 @@
esphome:
name: a3pool
board: nodemcuv2
platform: ESP8266
ota:
password: !secret a3poolpasswd
api:
password: !secret a3poolpasswd
encryption:
key: !secret a3poolkey
logger:
wifi:
ssid: !secret wifi_ssid
password: !secret wifi_password
fast_connect: true
mqtt:
broker: !secret mqtt_broker_2
client_id: "A3 Pool"
binary_sensor:
- platform: gpio
pin:
number: 12
inverted: true
mode:
input: true
pullup: true
id: pump_state
switch:
- platform: gpio
pin: 5
id: relay
on_turn_on:
- delay: 500ms
- switch.turn_off: relay
- platform: template
name: "Automate Control"
optimistic: true
restore_state: true
- platform: template
optimistic: false
name: pump
lambda: |-
if (id(pump_state).state) {
return true;
} else {
return false;
}
turn_on_action:
- if:
condition:
lambda: 'return id(pump_state).state == false;'
then:
- switch.turn_on: relay
- delay: 500ms
- switch.turn_off: relay
turn_off_action:
- if:
condition:
lambda: 'return id(pump_state).state;'
then:
- switch.turn_on: relay
- delay: 500ms
- switch.turn_off: relay
dallas:
- pin: D4
update_interval: 10s
sensor:
- platform: dallas
address: 0xd1000007494b3628
name: "Pool Temperature"
- platform: dallas
address: 0x440000073de2e728
name: "Solar Temperature"

10
secrets.yaml.template Normal file
View File

@ -0,0 +1,10 @@
# Global
wifi_ssid: "WIFI SSID"
wifi_password: "WIFI PASSWORD"
# Papa Broker
mqtt_broker_2: # Just put your broker in here...
# A3Pool
a3poolpasswd: # A3Pool OTA and native API password
a3poolkey: # Native API encryption KEY