bastianraschke / pyfingerprint

Python library for ZhianTec fingerprint sensors (e.g. ZFM-20, ZFM-60)
Other
190 stars 115 forks source link

Stop R307 from waiting to scan finger. #80

Closed ShinNics closed 4 years ago

ShinNics commented 5 years ago

Hi,

what function can I use to make the fingerprint sensor stop from waiting an input.?

raphaelreme commented 5 years ago

Hi, I used this lib recently, with that device. There is no blocking function i believe.

If you want the fingerprint sensor to expect an input you can use the readImage method but this won't block (this will return quickly False if no finger has been detected).

In order to detect a finger you usually do:

while not f.readImage():
   pass

But if you want to have more control, you can put a test inside your while loop

bastianraschke commented 4 years ago

You are right @raphaelreme, so i close the issue.