mirror of
https://github.com/boneIO-eu/esphome.git
synced 2026-04-10 20:50:02 +02:00
cover pcf test
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
cover:
|
||||
- platform: time_based
|
||||
name: "${node_name} Cover 01"
|
||||
device_class: shutter
|
||||
device_class: cover
|
||||
id: cover_01
|
||||
open_action:
|
||||
- switch.turn_off: cover_close_01
|
||||
@@ -24,7 +24,7 @@ cover:
|
||||
|
||||
- platform: time_based
|
||||
name: "${node_name} Cover 02"
|
||||
device_class: shutter
|
||||
device_class: cover
|
||||
id: cover_02
|
||||
open_action:
|
||||
- switch.turn_off: cover_close_02
|
||||
|
||||
60
boards/cover16_outputs_pcf_test.yaml
Normal file
60
boards/cover16_outputs_pcf_test.yaml
Normal file
@@ -0,0 +1,60 @@
|
||||
|
||||
pcf8574:
|
||||
- id: 'pcf_1'
|
||||
address: 0x21
|
||||
pcf8575: true
|
||||
i2c_id: bus_b
|
||||
- id: 'pcf_2'
|
||||
address: 0x20
|
||||
pcf8575: true
|
||||
i2c_id: bus_b
|
||||
|
||||
switch:
|
||||
- platform: gpio
|
||||
id: cover_open_01
|
||||
pin:
|
||||
pcf8574: pcf_1
|
||||
# Use pin number 0
|
||||
number: 15
|
||||
mode:
|
||||
output: true
|
||||
inverted: true
|
||||
interlock: &cover_interlock_01 [cover_open_01, cover_close_01]
|
||||
interlock_wait_time: 5ms
|
||||
restore_mode: always off
|
||||
|
||||
- platform: gpio
|
||||
id: cover_close_01
|
||||
pin:
|
||||
pcf8574: pcf_1
|
||||
# Use pin number 1
|
||||
number: 14
|
||||
mode:
|
||||
output: true
|
||||
inverted: true
|
||||
interlock: *cover_interlock_01
|
||||
restore_mode: always off
|
||||
|
||||
- platform: gpio
|
||||
id: cover_open_02
|
||||
pin:
|
||||
pcf8574: pcf_1
|
||||
# Use pin number 3
|
||||
number: 13
|
||||
mode:
|
||||
output: true
|
||||
inverted: true
|
||||
interlock: &cover_interlock_02 [cover_open_02, cover_close_02]
|
||||
restore_mode: always off
|
||||
|
||||
- platform: gpio
|
||||
id: cover_close_02
|
||||
pin:
|
||||
pcf8574: pcf_1
|
||||
# Use pin number 2
|
||||
number: 12
|
||||
mode:
|
||||
output: true
|
||||
inverted: true
|
||||
interlock: *cover_interlock_02
|
||||
restore_mode: always off
|
||||
32
boards/cover_pcf_test.yaml
Normal file
32
boards/cover_pcf_test.yaml
Normal file
@@ -0,0 +1,32 @@
|
||||
cover:
|
||||
- platform: time_based
|
||||
name: "${node_name} Cover 01"
|
||||
device_class: cover
|
||||
id: cover_01
|
||||
open_action:
|
||||
- switch.turn_off: cover_close_01
|
||||
- switch.turn_on: cover_open_01
|
||||
open_duration: 60s
|
||||
close_action:
|
||||
- switch.turn_off: cover_open_01
|
||||
- switch.turn_on: cover_close_01
|
||||
close_duration: 60s
|
||||
stop_action:
|
||||
- switch.turn_off: cover_open_01
|
||||
- switch.turn_off: cover_close_01
|
||||
|
||||
- platform: time_based
|
||||
name: "${node_name} Cover 02"
|
||||
device_class: cover
|
||||
id: cover_02
|
||||
open_action:
|
||||
- switch.turn_off: cover_close_02
|
||||
- switch.turn_on: cover_open_02
|
||||
open_duration: 60s
|
||||
close_action:
|
||||
- switch.turn_off: cover_open_02
|
||||
- switch.turn_on: cover_close_02
|
||||
close_duration: 60s
|
||||
stop_action:
|
||||
- switch.turn_off: cover_open_02
|
||||
- switch.turn_off: cover_close_02
|
||||
Reference in New Issue
Block a user