bastianraschke / pyfingerprint

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

searchTemplate ERROR #113

Open kotobukidevelopers opened 3 years ago

kotobukidevelopers commented 3 years ago

I have stumble the error communication error mentioned in #89 the problem is that the thread doesn't explain the whole problem and the exact solution

ok here is the instance

I have registered my fingerprint in R307 module then save the FINGERPRINT_BUFFER1 characteristic in the database then I will sync the other R307 with the given fingerprint buffer using the uploadCharacteristics()

here is the snippet Second R307 f.uploadCharacteristics(FINGERPRINT_CHARBUFFER1,json.loads(row[2])) //check if the fp data is in the module result = f.searchTemplate() pos_no = result[0] if pos_no == -1: print("register to module") else: print("already in the module")

so means on second r307 I wanna check if the fingerprint is already registered in the module however when I perform a searchTemplate() this throws an exception of communication error

the GOAL is to check the fingerprint if it exist before adding it in the second module