Skip to content

Commit

Permalink
Update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
AzonInc committed Mar 26, 2024
1 parent 5eb0ae2 commit f589ba4
Showing 1 changed file with 34 additions and 34 deletions.
68 changes: 34 additions & 34 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,46 +17,46 @@ Example of a Configuration, which generates a binary_sensor entity that goes to
```
external_components:
- source: github://AzonInc/ESPHome-TCS-Intercom
tcs_intercom:
binary_sensor:
- platform: tcs_intercom
name: "Apartment Doorbell"
command: 0x1c30ba41
name: "Apartment Doorbell"
command: 0x1c30ba41
button:
- platform: template
name: Open Door
on_press:
- tcs_intercom.send:
command: 0x1100
name: Open Door
on_press:
- tcs_intercom.send:
command: 0x1100
```

Full Configuration:
```
external_components:
- source: github://AzonInc/ESPHome-TCS-Intercom
tcs_intercom:
rx_pin: GPIO22
tx_pin: GPIO23
event: "tcs"
bus_command:
name: "Last Bus Command"
name: "Last Bus Command"
binary_sensor:
- platform: tcs_intercom
name: "Apartment Doorbell"
command: 0x1c30ba41
auto_off: 5s
name: "Apartment Doorbell"
command: 0x1c30ba41
auto_off: 5s
button:
- platform: template
name: Open Door
on_press:
- tcs_intercom.send:
command: 0x1100
name: Open Door
on_press:
- tcs_intercom.send:
command: 0x1100
```

Configuration variables:
Expand All @@ -81,13 +81,13 @@ Configuration examples:
```
binary_sensor:
- platform: tcs_intercom
name: Apartment Doorbell
command: 0x1c30ba41
name: Apartment Doorbell
command: 0x1c30ba41
- platform: tcs_intercom
command: 0x0c30ba80
name: Entrance Doorbell
auto_off: 5s
command: 0x0c30ba80
name: Entrance Doorbell
auto_off: 5s
```

- **command** (**Required**, int): The command that when received sets the sensor to on.
Expand Down Expand Up @@ -142,31 +142,31 @@ on_...:
- tcs_intercom.send:
command: 0x1100
```

- **command** (**Required**, int)

### Button:
The action can be easily inserted into a button type entity:
```
button:
- platform: template
name: Open Door
on_press:
- tcs_intercom.send:
command: 0x1100
name: Open Door
on_press:
- tcs_intercom.send:
command: 0x1100
```

### Service:
You can create a home assistant service, which can easily be invoked by an automation or script:
```
api:
encryption:
key: "xxxxxxxxxxxxxxxxxxx"
services:
- service: open_door
then:
- tcs_intercom.send:
command: 0x1100
key: "xxxxxxxxxxxxxxxxxxx"
services:
- service: open_door
then:
- tcs_intercom.send:
command: 0x1100
```

### Sending multiple commands:
Expand All @@ -176,10 +176,10 @@ In this case, a delay of at least 200ms must be inserted between the commands (o
```
on_...:
- tcs_intercom.send:
command: 0x1100
command: 0x1100
- delay: 90ms
- tcs_intercom.send:
command: 0x2100
command: 0x2100
```


Expand Down

0 comments on commit f589ba4

Please sign in to comment.