šŸš˜ Garage Fingerprint Sensor

It says there is no response from the reader, but the transmit is working because the ledā€™s are blinking.

See if the RX pin from the ESP and the TX pin from the sensor are connected correctly.

Sorry for my unclear information. The LED that was blinking was on the ESP32, not on the R503. Iā€™m not sure which LED you are referring to.

The led on the r503.

Hi and thank you for sharing your idea. I think the approach is nice and I would like to adapt it. However, Iā€™m also new to HA and Iā€™m still studying how everything works together. My question is: where exactly do I place the learning and deleting script? Do I need an additional entity to connect it, like a switch? Or can I attache it to the esphome device (corresponding entity)? Neither the description here nor the saver documentation is clear about it - Iā€™m missing that little piece of information ;). Thanks in advance!

Hey, the learning and delete scripts go within the scripts area of HomeAssistant. No need to an additional entity, just link directly to your esphome entities, in my case thatā€™s esphome.fingerprint_reader_enroll. If you used the same esphome code given in the first post of the thread my posts should be mostly a copy and paste (I think).

1 Like

Thanks a lot that helped. Its working now as expected. I use a different ESPhome code, because I use a display and a different fingerprinter, but autocompete of HA was helpful.

I tried with many ESP32 boards, but I think the module is not working. The seller refused to refund my money, so I had to buy a new one. I am currently waiting for the shipment.

Unfortunately I canā€™t get any furtherā€¦ I used the cables as written for the ESP32 (red+white on 3V, black to GND, yellow to GPIO16, green to GPIO17 and black to GPIO05).
In ESPhome the ESP32 is online and I copied your config with the below modifications.
If I start the ESPHome: fingerprint_enroll in the developer tools under the services tab
nothing happensā€¦ In the log I found this error:
Socket operation failed: BAD_INDICATOR errno=11
Do you have any idea whats the problem?
Thanks!!

esphome:
  name: fingerprint
  friendly_name: Fingerprint

esp32:
  board: esp32dev
  framework:
    type: arduino

# Enable logging
logger:

# Enable Home Assistant API


ota:
  password: "xxx"

wifi:
  ssid: !secret wifi_ssid
  password: !secret wifi_password

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Fingerprint Fallback Hotspot"
    password: "xxx"

uart:
  tx_pin: GPIO17 # Or GPIO17 for ESP32
  rx_pin: GPIO16 # Or GPIO16 for ESP32
  baud_rate: 57600

fingerprint_grow:
  sensing_pin: GPIO05 # Or GPIO05 for ESP32
  on_finger_scan_matched:
    - fingerprint_grow.aura_led_control:
        state: BREATHING
        speed: 200
        color: BLUE
        count: 1
    - text_sensor.template.publish:
        id: fingerprint_state
        state: "Authorized finger"
  on_finger_scan_unmatched:
    - fingerprint_grow.aura_led_control:
        state: FLASHING
        speed: 25
        color: RED
        count: 2
    - text_sensor.template.publish:
        id: fingerprint_state
        state: "Unauthorized finger"
  on_enrollment_scan:
    - fingerprint_grow.aura_led_control:
        state: FLASHING
        speed: 25
        color: BLUE
        count: 2
    - fingerprint_grow.aura_led_control:
        state: ALWAYS_ON
        speed: 0
        color: PURPLE
        count: 0
    - text_sensor.template.publish:
        id: fingerprint_state
        state: "Finger scanned"
  on_enrollment_done:
    - fingerprint_grow.aura_led_control:
        state: BREATHING
        speed: 100
        color: BLUE
        count: 2
    - text_sensor.template.publish:
        id: fingerprint_state
        state: "Enrolled fingerprint"
  on_enrollment_failed:
    - fingerprint_grow.aura_led_control:
        state: FLASHING
        speed: 25
        color: RED
        count: 4
    - text_sensor.template.publish:
        id: fingerprint_state
        state: "Failed to enroll fingerprint"

text_sensor:
  - platform: template
    id: fingerprint_state
    name: "Garage Fingerprint State"

sensor:
  - platform: fingerprint_grow
    fingerprint_count:
      name: "Garage Fingerprint Count"
    last_finger_id:
      name: "Garage Fingerprint Last Finger ID"
    last_confidence:
      name: "Garage Fingerprint Last Confidence"
    status:
      name: "Garage Fingerprint Status"
    capacity:
      name: "Garage Fingerprint Capacity"
    security_level:
      name: "Garage Fingerprint Security Level"

api:
  encryption:
    key: "+7zlD9VOafKR0WjEWj7uOY6ybdNwfDmKWqngf2/ZAMs="
  services:
  - service: enroll
    variables:
      finger_id: int
      num_scans: int
    then:
      - fingerprint_grow.enroll:
          finger_id: !lambda 'return finger_id;'
          num_scans: !lambda 'return num_scans;'
  - service: cancel_enroll
    then:
      - fingerprint_grow.cancel_enroll:
  - service: delete
    variables:
      finger_id: int
    then:
      - fingerprint_grow.delete:
          finger_id: !lambda 'return finger_id;'
  - service: delete_all
    then:
      - fingerprint_grow.delete_all:

You have to put your finger on the sensor after calling the enroll function. Does nothing happen? By the way, in your post you say ā€œblack to gpio5ā€ I assume you meant blue?

Yes, I put my finger on the sensor - but I couldnā€™t see any reaction.
Of course: blue to gpio05 (black to GND).

Actually I see this log in ESPhome, when calling enroll function:
30s after ā€œstarting enrollmentā€ I stopped it because nothing happened
Perhaps this could help you.

[23:23:38][D][api:102]: Accepted ::FFFF:192.168.178.76
[23:23:38][D][api.connection:918]: Home Assistant 2023.2.5 (::FFFF:192.168.178.xx): Connected successfully
[23:24:32][I][fingerprint_grow:066]: Starting enrollment in slot 0
[23:25:08][D][fingerprint_grow:305]: Setting Aura LED
[23:25:09][E][fingerprint_grow:419]: No response received from reader
[23:25:09][D][text_sensor:067]: 'Garage Fingerprint State': Sending state 'Failed to enroll fingerprint'
[23:25:09][I][fingerprint_grow:087]: Finished enrollment

Does the LED on the device blink when you call the cancel enroll service?

Also try to start from slot 1, I donā€™t think slot 0 works.

@Leo4417 , I can confirm that GPIO16 (or D0) on ESP8266, at least on the Wemos D1 mini, does not work. I tried it before and finally changed to D1 and D2 for Tx and Rx.

Super odd. Followed this guide (Home Assistant: A Fingerprint Scanner for Your Garage - HomeTechHacker) back in November and went great, been up and running since November. Last Thursday was the last day it worked though - w/out major updates to HA. Anyone else seen this? The ESPHome Logs show it connects ok, but the sensor wonā€™t ā€˜scanā€™ and doesnā€™t change LED colors - like it wonā€™t register a fingerprint any more? Same happens w/ enroll, logs say itā€™s ready - but finger presses donā€™t ā€˜doā€™ anythingā€¦

UPDATE: Forced a recompile / upload to the ESP8266 - and also added a manual_ip: section and back working. Super odd.

Hmm, is the wakeup wire still connected correctly? (blue wire)

Like @FredTheFrog, weā€™ve just received a R503 in a baggie branded Shenzen Xuan Yao (not Grow) from ThePiHut (UK). We have Red, Black, Yellow, Brown, Blue, White wires.

When I wire it up to my ESP32 using Esphome, all the sensors show as 'unknown.

There is no ā€˜lifeā€™ at all from the R503 - the LED never lights up at any time.

I thought it was totally dead until I connected a meter to ground and blue, when we found that there is 3.3v on the blue finger detection wire UNTIL I press a thumb or finger on the sensor. Then the blue gets pulled to ground! So despite outward appearances there IS life in the fingerprint sensor.

I found a datasheet which said the blue wire was active high, but actually is it active low?!

Anyway - help much appreciatedā€¦

Screenshot 2023-03-18 at 12.16.28

By the way, where the log shows ā€˜finished enrollmentā€™, this is where Iā€™ve called the service ā€˜cancel enrollmentā€™. It isnā€™t proof the sensor is ā€˜talkingā€™.

At no point have I had any sign that the sensor has sent ANY data to Home Assistant and at no point has the circular LED bezel thing lit up AT ALL.

The only sign of life is the blue wire being pulled to 0v when a fingerprint is placed on the sensor. Thatā€™s it.

Just realised (from reading) itā€™s also similar to the issue @MosSHR posted. I wonder if these are knock off R503sā€¦

1 Like

I think itā€™s best to create an issue in the ESPHome GitHub.

I have a working one and my green wire is also brown. I just migrated it from a 8266 to a 32 and ended up with a non working condition as well, but realised after too much staring at the wires that I swapped TX and RX.

Did you use the pins described in the start post?

Mine is the adafruit sensor, not the grow, I now realise. I am using an ESP32-POE, so probably canā€™t use the exact pins described. And it seems to be super fussy about which pins can be used. A bit odd as really it seems like it just needs power, ground and tx/rx

Iā€™ve got it working on an old arduino, but thatā€™s using the adafruit library I found on the adafruit websiteā€¦.