Skip to content

Commit

Permalink
Merge pull request #24 from jesserockz/ha/tag-scanned-action
Browse files Browse the repository at this point in the history
Change to use the new tag_scanned action in ESPHome 1.15.2
  • Loading branch information
magnusoverli committed Sep 21, 2020
2 parents 7c62b46 + 48d39fd commit bb76086
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
4 changes: 3 additions & 1 deletion README.md
Expand Up @@ -35,8 +35,10 @@ Also make sure that you have set the switches on the PN532 to the following:

This enables the PN532 module to communicate with the D1 over SPI, and is required for the modules to work together!

To flash the reader firmware to your D1 Mini you point ESPHome at [tagreader.yaml](https://github.com/adonno/tagreader/blob/master/tagreader.yaml).
**The tag reader requires ESPHome 1.15.2 or later.**

To flash the reader firmware to your D1 Mini you point ESPHome at [tagreader.yaml](https://github.com/adonno/tagreader/blob/master/tagreader.yaml). If you're new to ESPHome, we recommend that you use the [ESPHome Home Assistant add-on](https://esphome.io/guides/getting_started_hassio.html).
If you're new to ESPHome, we recommend that you use the [ESPHome Home Assistant add-on](https://esphome.io/guides/getting_started_hassio.html).

![Open Case](https://raw.githubusercontent.com/adonno/tagreader/master/docs/open-case.jpg)

Expand Down
5 changes: 1 addition & 4 deletions tagreader.yaml
Expand Up @@ -80,10 +80,7 @@ pn532:
# What happens when a tag is read
on_tag:
then:
- homeassistant.event:
event: esphome.tag_scanned
data:
tag_id: !lambda 'return x;'
- homeassistant.tag_scanned: !lambda 'return x;'
- if:
condition:
switch.is_on: buzzer_enabled
Expand Down

0 comments on commit bb76086

Please sign in to comment.