forked from ratgdo/esphome-ratgdo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adds dry contact opener control (ratgdo#258)
* Setting up dry contact protocol * limit switch implementation * setup door controls * Initial commit to make the component aware of the dry_contact sensors… (ratgdo#249) Initial commit to make the component aware of the dry_contact sensors and eliminate the need for lamda calls Co-authored-by: bradmck <[email protected]> * send both sensor values * removing irrelevant dry contact config * Add triple button (discrete) control for commercial openers & gates * point to git * Add dry contact to installer * rm whitespace * updated wiring diagram * organize dry contact methods & fix initial limit switch state --------- Co-authored-by: bradmck <[email protected]>
- Loading branch information
1 parent
9338348
commit da0776f
Showing
13 changed files
with
352 additions
and
19 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
--- | ||
|
||
external_components: | ||
- source: | ||
# type: local | ||
# path: components | ||
type: git | ||
url: https://github.com/ratgdo/esphome-ratgdo | ||
refresh: 1s | ||
|
||
preferences: | ||
flash_write_interval: 1min | ||
|
||
ratgdo: | ||
id: ${id_prefix} | ||
output_gdo_pin: ${uart_tx_pin} | ||
input_obst_pin: ${input_obst_pin} | ||
dry_contact_open_sensor: ${id_prefix}_dry_contact_open | ||
dry_contact_close_sensor: ${id_prefix}_dry_contact_close | ||
discrete_open_pin: ${discrete_open_pin} | ||
discrete_close_pin: ${discrete_close_pin} | ||
protocol: drycontact | ||
|
||
binary_sensor: | ||
- platform: ratgdo | ||
type: obstruction | ||
id: ${id_prefix}_obstruction | ||
ratgdo_id: ${id_prefix} | ||
name: "Obstruction" | ||
device_class: problem | ||
- platform: gpio | ||
id: "${id_prefix}_dry_contact_open" | ||
pin: | ||
number: ${dry_contact_open_pin} | ||
inverted: true | ||
mode: | ||
input: true | ||
pullup: true | ||
name: "Open limit switch" | ||
entity_category: diagnostic | ||
filters: | ||
- delayed_on_off: 500ms | ||
- platform: gpio | ||
id: "${id_prefix}_dry_contact_close" | ||
pin: | ||
number: ${dry_contact_close_pin} | ||
inverted: true | ||
mode: | ||
input: true | ||
pullup: true | ||
name: "Close limit switch" | ||
entity_category: diagnostic | ||
filters: | ||
- delayed_on_off: 500ms | ||
|
||
number: | ||
- platform: ratgdo | ||
id: ${id_prefix}_opening_duration | ||
type: opening_duration | ||
entity_category: config | ||
ratgdo_id: ${id_prefix} | ||
name: "Opening duration" | ||
unit_of_measurement: "s" | ||
|
||
- platform: ratgdo | ||
id: ${id_prefix}_closing_duration | ||
type: closing_duration | ||
entity_category: config | ||
ratgdo_id: ${id_prefix} | ||
name: "Closing duration" | ||
unit_of_measurement: "s" | ||
|
||
cover: | ||
- platform: ratgdo | ||
id: ${id_prefix}_garage_door | ||
device_class: garage | ||
name: "Door" | ||
ratgdo_id: ${id_prefix} | ||
|
||
button: | ||
- platform: restart | ||
id: ${id_prefix}_restart | ||
name: "Restart" | ||
- platform: safe_mode | ||
id: ${id_prefix}_safe_mode | ||
name: "Safe mode boot" | ||
entity_category: diagnostic | ||
|
||
- platform: template | ||
id: ${id_prefix}_toggle_door | ||
name: "Toggle door" | ||
on_press: | ||
then: | ||
lambda: !lambda |- | ||
id($id_prefix).door_toggle(); |
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.