Skip to main content

python driver for fingerprint machine (biometrics)

Project description

fpmachine

python driver for fingerprint machine (ZKTeco biometrics)

support

until now 2 model supported and tested ZMM100_TFT and ZMM220_TFT

install

pip3 install --upgrade fpmachine

usage

from fpmachine.devices import ZMM220_TFT

# create a device with ip, port and encoding
dev = ZMM220_TFT("192.168.1.3", 4370, "latin-1")

# connect and pass commkey default=0
dev.connect(2020)

# get users
users = dev.get_users()

# get attendance logs
att_logs = dev.get_att_logs()

# get fingerprints
fps = dev.get_fps()

# get face data passing person_id
face = dev.get_user_face("34002")

# get user picture passing person_id
pic = dev.get_user_pic("34002")

# get machine state
state = dev.get_state()

# set user pic passing person_id and bytes (pic data)
dev.set_user_pic("34002", pic_data)

# set user face passing person_id and bytes (face data)
dev.set_user_face("34002", face_data)

# set user at specific serial (id) passing UserInfo that 
dev.set_user(user_info)

# set fingerprint passing FPInfo struct that contain user serial and finger id
dev.set_fp(fp_info)

# set all fingerprints
dev.set_fps(fp_info_list)

# use delete function with caution

# delete user passing user serial (id) not person id
dev.del_user(id)

# delete user pic passing person_id
dev.del_user_pic("34002")

# delete user face passing person_id
dev.del_user_face("34002")

# delete fingerprint passing person_id and finger_id
dev.del_fp("34002", 5)
# delete all users
dev.del_users()

# delete all admins
dev.del_admins()

# delete all fingerprints
dev.del_fps()

# delete all attendance logs
dev.del_att_logs()

# disconnect
dev.disconnect()

# note the device object has properties some of them are readonly:
#.    id, name, product_time, serial_number, language, finger_fun_on, face_fun_on, zk_face_version, biometric_type, 
#.    build_version, bin_width, vendor, platform, os, software_version, ...
# others are read/write:
#.    work_code, mac_address, ip_address, password (commkey), port, device_time

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fpmachine-0.0.2.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fpmachine-0.0.2-py3-none-any.whl (17.6 kB view details)

Uploaded Python 3

File details

Details for the file fpmachine-0.0.2.tar.gz.

File metadata

  • Download URL: fpmachine-0.0.2.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.2

File hashes

Hashes for fpmachine-0.0.2.tar.gz
Algorithm Hash digest
SHA256 a540efa0d77436ac440d17450d46231ebc42e1e524354a992c6bde4a0f460082
MD5 6bed2dde49d8e1ac56b5a03a165ee026
BLAKE2b-256 7ee5feb2d809981424e94853cee90cf6fe697d0b863de711f4d6c57a16ab9389

See more details on using hashes here.

File details

Details for the file fpmachine-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: fpmachine-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 17.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.2

File hashes

Hashes for fpmachine-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 92055c13044526bfc5eb3947c568134cd0752b0370f34a2907d234ea9fb8049d
MD5 5175d28650934602998e810cd37d89cd
BLAKE2b-256 aa6e73845e3fb060688ceffa812fdff0334e084d1848e5d75aa6b09142078ab0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page