Hi guys,
I’m new in YAML. I want to use two Grow Fingerprint sensors on my ESP32.
Please, how can I declare two? If I try to do it like a list, it shows Error by the “on_finger_scan…”.
Thank you for every help/comment.
Hi guys,
I’m new in YAML. I want to use two Grow Fingerprint sensors on my ESP32.
Please, how can I declare two? If I try to do it like a list, it shows Error by the “on_finger_scan…”.
Thank you for every help/comment.
The id
has to be unique for each instance. You can’t reuse id names.
You mean the row 21 - id: fingerprint_in and row 25 - id: fingerprint_out?
These are not same.
I see, you have the 2 id’s on the same sensing pin. Did you try different sensing pins for each reader?
Yes, I tried with GPIO32 now. But the error not about the sensing pin.
I’m new by YAML and I don’t know how to make two instance of the component.
Can I just make it as list with character ’ - ’ before the id?
It depends on how the integration was written. It may very well only support a single reader. You could file a feature request/bug report on github.
Ok, I made a request to update. fingerprint_grow multiple instances · Issue #1522 · esphome/feature-requests · GitHub
If somebody knows how to make two instances of the “fingerprint_grow” conponent, please let me know
Hi,
I tried to create two instances of the object without the events and it looks is working.
Just if I add the events, it says: fault. Looks like a bug in the component, or my fault by using YAML?
esphome:
name: test_loader
platform: ESP32
board: esp32dev
uart:
- id: uart_in
tx_pin: GPIO17
rx_pin: GPIO16
baud_rate: 57600
- id: uart_out
tx_pin: GPIO23
rx_pin: GPIO22
baud_rate: 57600
fingerprint_grow:
- id: fingerprint_in
uart_id: uart_in
sensing_pin: GPIO32
- id: fingerprint_out
uart_id: uart_out
sensing_pin: GPIO12
Thank for help and some Idea
Oh I see what I think is the problem, all your automations were under the same entry. All actions for uart_in
are under uart_out
. Separate them to their respective entries.
Hi Mike,
I’m not understanding, what you mean with “Separate them to their respective entries.”
Can you write some example?
Thank you very much.
fingerprint_grow:
### this is the entry
id: finger_in
sensing_pin: GPIO12 ##use different pins for each sensor
uart_id: uart_finger_in
###end of entry
###start of automations
on_finger_scan_matched:
- text_sensor.template.publish:
id: fingerprint_state
state: "Authorized finger"
- switch.turn_on: gate
- delay: 500ms
- switch.turn_off: gate
on_finger_scan_unmatched:
- text_sensor.template.publish:
id: fingerprint_state
state: "Unauthorized finger"
### end of automations
### start second entry
id: finger_out
sensing_pin: ##use different pins for each sensor
uart_id: uart_finger_out
###end of entry
###start of automations for second entry
on_finger_scan_matched:
- text_sensor.template.publish:
id: fingerprint_state
state: "Authorized finger"
- switch.turn_on: gate
- delay: 500ms
- switch.turn_off: gate
on_finger_scan_unmatched:
- text_sensor.template.publish:
id: fingerprint_state
state: "Unauthorized finger"
Ok, it’s not working on first, but after small correction looks good. (valid by ESPHome)
fingerprint_grow:
- id: fingerprint_in
uart_id: uart_in
sensing_pin: GPIO32
on_finger_scan_matched:
- switch.turn_on: relay_unlock
- fingerprint_grow.aura_led_control:
id: fingerprint_in
state: BREATHING
speed: 200
color: BLUE
count: 1
- text_sensor.template.publish:
id: fingerprint_out_state
state: "Authorized finger"
- switch.turn_on: relay_unlock
- delay: 500ms
- switch.turn_off: relay_unlock
- id: fingerprint_out
uart_id: uart_out
sensing_pin: GPIO12
on_finger_scan_matched:
- switch.turn_on: relay_unlock
- fingerprint_grow.aura_led_control:
id: fingerprint_out
state: BREATHING
speed: 200
color: BLUE
count: 1
- text_sensor.template.publish:
id: fingerprint_out_state
state: "Authorized finger"
- delay: 500ms
- switch.turn_off: relay_unlock
I thank you. You are great man.