Initial test
This commit is contained in:
42
infoMesin.py
Normal file
42
infoMesin.py
Normal file
@@ -0,0 +1,42 @@
|
||||
# reference the ZK Soap PHP namespace
|
||||
#from zksoap import Fingerprint, UserInfoEncoder
|
||||
from ZKFingerprint import Fingerprint, UserInfoEncoder
|
||||
import json
|
||||
|
||||
# initial office=10.35.14.10
|
||||
machine = Fingerprint('10.35.7.1', '80', '0')
|
||||
|
||||
# get machine status
|
||||
print("Machine Status : "+machine.getStatus()) # connected | disconnected
|
||||
|
||||
# get all user data
|
||||
#print(machine.getUserInfo()) # return List of User Info Data
|
||||
|
||||
# get specific pin user data
|
||||
#print(machine.getUserInfo('29305')) # return List of User Info Data
|
||||
# OR List
|
||||
#print(machine.getUserInfo(['Masna Suhana', '4705'])) # return List of User Info Data
|
||||
|
||||
# get exported json format
|
||||
#decoded_data = machine.getUserInfo()
|
||||
#data_dict = {"data": decoded_data}
|
||||
#json_data = json.dumps(data_dict, indent=4, cls=UserInfoEncoder)
|
||||
#file_path = 'user_info2.json'
|
||||
#with open(file_path, 'w') as file:
|
||||
# file.write(json_data)
|
||||
|
||||
#print(f"JSON data saved to {file_path}")
|
||||
|
||||
conn.get_firmware_version()
|
||||
conn.get_serialnumber()
|
||||
conn.get_platform()
|
||||
conn.get_device_name()
|
||||
conn.get_face_version()
|
||||
conn.get_fp_version()
|
||||
conn.get_extend_fmt()
|
||||
conn.get_user_extend_fmt()
|
||||
conn.get_face_fun_on()
|
||||
conn.get_compat_old_firmware()
|
||||
conn.get_network_params()
|
||||
conn.get_mac()
|
||||
conn.get_pin_width()
|
||||
Reference in New Issue
Block a user