Library and CLI tool for working with ZKTeco ZKAccess C3-100/200/400 controllers
Project description
PyZKAccess
PyZKAccess is a library and command-line interface for working with ZKTeco ZKAccess C3-100/200/400 access controllers.
This package is Windows-only, but it can be used on *nix systems with Wine. It built on top of the ZKTeco PULL SDK and fully supports all its features.
This package, once installed, may be used as library for your project or command-line interface. It's also distributed as a portable Windows executable, created by PyInstaller with built-in 32-bit Python interpreter.
Features
We support all the features the ZKTeco PULL SDK provides:
- Can be used as a code library or a command-line tool
- Reading and writing the device data tables
- Making queries to device data tables
- CSV format support
- On-board relays control
- Read the realtime events of a particular reader, aux input, door or the whole device
- Manipulation the device parameters such as datetime, network settings, entry modes, backup time, etc.
- Manipulation the door parameters such as smart card modes, intervals, entry modes, etc.
- Restart a device
- Scan the local network for active C3 devices
- Download/upload files from PC to/from a device
- Cancel alarm function
- Reset the device IP address by its MAC address
Quick start
The quickest way is to use portable pyzkaccess.exe.
It contains the full pyzkaccess package with built-in Python and necessary libraries.
You can also install the package from PyPI (the 32-bit Python>=3.8 version is required) pip install pyzkaccess
Run this to setup the environment:
pyzkaccess setup
This command will make a quick compatibility check of your system and suggest you to install PULL SDK from the official ZKTeco site (you can also specify your own SDK archive or you can install SDK manually, see docs for more info).
All set! Now let's find out what ZKAccess devices are available on the local network:
$ pyzkaccess search_devices
+---------------+-------------------+--------+---------------------+--------------------------+
| ip | mac | model | serial_number | version |
+---------------+-------------------+--------+---------------------+--------------------------+
| 192.168.1.201 | 00:17:61:C3:BA:55 | C3-400 | DGD9190010050345332 | AC Ver 4.3.4 Apr 28 2017 |
+---------------+-------------------+--------+---------------------+--------------------------+
Let's enumerate all users registered on a device:
$ pyzkaccess connect 192.168.1.201 table User
+----------+------------+-------+----------+-----+------------+-----------------+
| card | end_time | group | password | pin | start_time | super_authorize |
+----------+------------+-------+----------+-----+------------+-----------------+
| 16268812 | 2020-12-01 | 2 | 123456 | 1 | 2020-06-01 | 1 |
| 16268813 | | 3 | 123451 | 3 | | 0 |
+----------+------------+-------+----------+-----+------------+-----------------+
Or print a particular one:
$ pyzkaccess connect 192.168.1.201 table User where --card=16268812
+----------+------------+-------+----------+-----+------------+-----------------+
| card | end_time | group | password | pin | start_time | super_authorize |
+----------+------------+-------+----------+-----+------------+-----------------+
| 16268812 | 2020-12-01 | 2 | 123456 | 1 | 2020-06-01 | 1 |
+----------+------------+-------+----------+-----+------------+-----------------+
Adding, updating, or deleting records from a device table:
$ cat users1.csv | pyzkaccess --format=csv connect 192.168.1.201 table User upsert
$ cat users2.csv | pyzkaccess --format=csv connect 192.168.1.201 table User delete
$ pyzkaccess connect 192.168.1.201 table User --card=16268812 delete_all
Switching relays and awaiting device events:
$ pyzkaccess connect 192.168.1.201 relays switch_on
$ pyzkaccess connect 192.168.1.201 events --event_type=23 poll
card door entry_exit event_type pin time verify_mode
16268813 1 0 23 3 2020-05-09 22:35:55 0
Getting and setting parameters:
$ pyzkaccess connect 192.168.1.201 parameters --names=ip_address,serial_number,datetime
+---------------------+---------------+---------------------+
| datetime | ip_address | serial_number |
+---------------------+---------------+---------------------+
| 2020-05-09 22:42:31 | 192.168.1.201 | DGD9190010050345332 |
+---------------------+---------------+---------------------+
$ pyzkaccess connect 192.168.1.201 parameters set --datetime='2020-05-09 22:42:31' --rs232_baud_rate=57600
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pyzkaccess-1.1.tar.gz.
File metadata
- Download URL: pyzkaccess-1.1.tar.gz
- Upload date:
- Size: 64.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.4 CPython/3.8.18 Linux/6.5.0-1025-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
84b465f5ca3bee4cf7409b5f94c693305f2c4946d730827610237bb5a057a876
|
|
| MD5 |
e1818d01be4793f3bcda372ded1ebe79
|
|
| BLAKE2b-256 |
7b4e349639213f93c4d0cbd33e0e009c00ef341c543db8361948f0393a4274a4
|
File details
Details for the file pyzkaccess-1.1-py3-none-any.whl.
File metadata
- Download URL: pyzkaccess-1.1-py3-none-any.whl
- Upload date:
- Size: 69.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.4 CPython/3.8.18 Linux/6.5.0-1025-azure
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f77cd17cc469248ba21cbe7159a4a8d7345c6e494bea1ccabdeb29e07f9d959b
|
|
| MD5 |
303702eebf908ef0199651bd9efd1a86
|
|
| BLAKE2b-256 |
1efafaa2bf7b920a57f99b51a804eaf203a5d5135bf25abfc29fdf15702ee55d
|