Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
296 views24 pages

SB100BPC - OCX Specification 2.1 (2006/12/01)

This document specifies the structure and functions of the SB100BPC.OCX component. It describes 42 methods for communicating with terminals to get and set enrollment data, logs, device settings and statuses. It also describes 1 property for setting a reading mark. The methods allow retrieving user, attendance and event logs, as well as configuring terminal settings like user privileges, device time and door status.

Uploaded by

Anil Bajaj
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
296 views24 pages

SB100BPC - OCX Specification 2.1 (2006/12/01)

This document specifies the structure and functions of the SB100BPC.OCX component. It describes 42 methods for communicating with terminals to get and set enrollment data, logs, device settings and statuses. It also describes 1 property for setting a reading mark. The methods allow retrieving user, attendance and event logs, as well as configuring terminal settings like user privileges, device time and door status.

Uploaded by

Anil Bajaj
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 24

SB100BPC.OCX Specification 2.

1 (2006/12/01)

Contents
Contents..................................................................................1
1.Structure of SB100BPC.OCX...............................................................2
2.Method..................................................................................4
2.1 Function “GetEnrollData”.............................................................4
2.2 Function “SetEnrollData”.............................................................5
2.3 Function “DeleteEnrollData”..........................................................5
2.4 Function “ReadSuperLogData”..........................................................6
2.5 Function “GetSuperLogData”...........................................................6
2.6 Function “ReadGeneralLogData”........................................................8
2.7 Function “GetGeneralLogData”.........................................................8
2.8 Function “ReadAllSLogData”..........................................................10
2.9 Function “GetAllSLogData”...........................................................10
2.10 Function “ReadAllGLogData”.........................................................11
2.11 Function “GetAllGLogData”..........................................................11
2.12 Function “GetDeviceStatus”.........................................................11
2.13 Function “GetDeviceInfo”...........................................................12
2.14 Function “SetDeviceInfo”...........................................................13
2.15 Function “EnableDevice”............................................................13
2.16 Function “EnableUser”..............................................................14
2.17 Function “SetDeviceTime”...........................................................14
2.18 Function “GetDeviceTime”...........................................................15
2.19 Function “PowerOnAllDevice”........................................................15
2.20 Function “PowerOffDevice”..........................................................15
2.21 Function “ModifyPrivilege”.........................................................16
2.22 Function “ReadAllUserID”...........................................................16
2.23 Function “GetAllUserID”............................................................16
2.24 Function “GetSerialNumber”.........................................................17
2.25 Function “ClearKeeperData”.........................................................17
2.26 Function “GetLastError”............................................................18
2.27 Function “GetBackupNumber”.........................................................18
2.28 Function “GetProductCode”..........................................................18
2.29 Function “EmptyEnrollData”.........................................................19
2.30 Function “EmptyGeneralLogData”.....................................................19
2.31 Function “EmptySuperLogData”.......................................................19
2.32 Function “GetUserName”.............................................................19
2.33 Function “SetUserName”.............................................................20
2.34 Function “GetCompanyName”..........................................................20
2.35 Function “SetCompanyName”..........................................................20
2.36 Function “GetDoorStatus”...........................................................21
2.37 Function “SetDoorStatus”...........................................................21
2.38 Function “GetBellTime”.............................................................22
2.39 Function “SetBellTime”.............................................................22
2.40 Function “ConnectSerial”...........................................................22
2.41 Function “ConnectTcpip”............................................................23
2.42 Function “Disconnect”..............................................................23
3.Property...............................................................................24
3.1 Property “ReadMark”.................................................................24

1.Structure of SB100BPC.OCX
Classific No Function Name Explanation

- 1 -
ation
Method
1 GetEnrollData It gets one of registered data from the terminal.
M
2 SetEnrollData It registers a user on the terminal.
It deletes one of the registered data from the
3 DeleteEnrollData
terminal.
It reads the newly-recorded management data from
4 ReadSuperLogData
the terminal.
It gets one of the management data from the
5 GetSuperLogData
internal memory.
It reads the newly-recorded attendance data from
6 ReadGeneralLogData
the terminal.
It gets one of the attendance data from the
7 GetGeneralLogData
internal memory.
It reads all of the management data from the
8 ReadAllSLogData
terminal.
It gets all of the management data from the
9 GetAllSLogData
internal memory.
It reads all of the management data from the
10 ReadAllGLogData
terminal.
It gets all of the attendance data from the
11 GetAllGLogData
internal memory.
It gets the current status of operation of the
12 GetDeviceStatus
terminal.
13 GetDeviceInfo It gets the setup information of the terminal.

14 SetDeviceInfo It modifies the setup information of the terminal.


It enables/forbids the terminal to record
15 EnableDevice
attendances on it.
It enables/forbids the terminal to record
16 EnableUser
attendance of the specified user.
17 GetDeviceTime It gets the time and date of the terminal.

18 SetDeviceTime It modifies the time and date of the terminal.

19 PowerOnAllDevice It powers on all of the terminals.

20 PowerOffDevice It powers off an individual terminal.


It modifies the authority of the user for the
21 ModifyPrivilege
terminal.
It reads the info data of all the users registered
22 ReadAllUserID
currently on the terminal.
It gets the info data of all the users from the
23 GetAllUserID
internal memory.
24 GetSerialNumber It gets the serial number of the product.

25 ClearKeeperData It deletes all the recorded and registered data.

26 GetLastError It gets the last error info.

27 GetBackupNumber It gets the management number of the terminal.

28 GetProductCode It gets the product info of the terminal.

29 EmptyEnrollData It deletes all the registered data.

30 EmptyGeneralLogData It deletes all the attendance (access) data.

31 EmptySuperLogData It deletes all the management data.


It get one of the specified registration user's
32 GetUserName
name data from the terminal.
33 SetUserName It download the specified user's name data to the
appointed terminal.

- 2 -
It get the display name of a company from the
34 GetCompanyName
terminal.
It download the display name of a company to the
35 SetCompanyName
appointed terminal.
36 GetDoorStatus It get the current door status from the terminal.
It download a door status to the appointed
37 SetDoorStatus
terminal.
38 GetBellTime It get the bell time from the terminal.
It download the bell time to the appointed
39 SetBellTime
terminal.
It connects to the terminal via the serial port
40 ConnectSerial
(RS232, RS485).
It connects to the terminal via the network
41 ConnectTcpip
(TCP/IP).
It closes the connected session for communication
42 Disconnect
with the terminal.
Property 1 ReadMark Recorded data-reading mark.

- 3 -
2.Method

2.1 Function “GetEnrollData”


[Function]
Function “GetEnrollData” is used to get one of the specified registration data
from the terminal.
[Format]
BOOL GetEnrollData(
long dwMachineNumber,
long dwEnrollNumber,
long dwEMachineNumber,
long dwBackupNumber,
long* dwMachinePrivilege,
VARIANT* dwEnrollData,
long* dwPassWord);

[Parameter]
dwMachineNumber : It stands for the ID number of the terminal which the
data will be read from.
dwEnrollNumber : Registration number of the data to get
dwEMachineNumber : ID number of the terminal which the data has been
registered on
dwBackupNumber : Backup number of the registration data to get.
Below are values of the backup numbers.
Value Meaning
Fingerprint data ranging from No.0
0~9
to No.9
10 Password data
11 Card data

dwMachinePrivilege : A pointer to the Long-type variable receiving the


device authority of the registration data to get.
Below are values of the device authority.
Value Meaning Authority
0 General user None
Primary Setting registration
1
manager and devices
Enroll
2 Enrollment
manager
3 Setup manager Setting the devices

dwEnrollData : A VARIANT-Type pointer to the cache receiving the value


of the registration data to get. The data is 1404+12 Bytes
is size.
dwPassWord : A pointer to the Long-type variable receiving the
password (card) value of the registration data to get.
[Return Value]
It is TRUE when a valid data has been read from the terminal.
It would be FALSE if the terminal does not have the specified data on it or an
error has occurred to the communication. When the return value is FALSE, the
values of parameters have no meanings.
[Attention]
This function is used to get the specified fingerprint and password-registered
data from the terminal.
The function gets the specified fingerprint data from the terminal if the
value of “dwBackupNumber” is between 0 and 9 assigned when the function is
accessed. At the moment, the value of the variable designated by “dwPassWord”
has no meaning.

- 4 -
The function gets the specified password data from the terminal if the value of
“dwBackupNumber” is 10 assigned when the function is accessed. At the moment,
the value of the variable designated by “dwEnrollData” has no meaning.

2.2 Function “SetEnrollData”


[Function]
Function “SetEnrollData” is used to download the specified data to the appointed
terminal and enroll them on it
[Format]
BOOL SetEnrollData(
long dwMachineNumber,
long dwEnrollNumber,
long dwEMachineNumber,
long dwBackupNumber,
long dwMachinePrivilege,
VARIANT* dwEnrollData,
long dwPassWord);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal to download
the data to.
dwEnrollNumber : the registration number of the data to download.
dwEMachineNumber : ID number of the terminal which the data has been
registered on
dwBackupNumber : Backup number of the registration data to download.
The value of the backup number is the same as
dwBackupNumber of function “GetEnrollData”.
If Backup number is 0,1, or 2 then set data enable double
check.
If Backup number is 20,21, or 22 then set data send and
write to device unconditionaly.
dwMachinePrivilege : Device authority of the data to download.
dwEnrollData : A VARIANT-Type pointer to the cache receiving the value
of the registration data to get. The data is 1404+12 Bytes
is size. It is one of the data the attendance management
system has already stored, making use of function
“GetEnrollData”.
dwPassWord : Password (card) of the data to download.
[Return Value]
It is TRUE when the data has accurately been downloaded to the specified
terminal and successfully been operated on it.
It would be FALSE if the terminal does not have the specified data on it, an
error has occurred to the communication or the terminal has failed in its
working.
[Attention] This function is used to register the specified enrollment data on
the appointed terminal.
The function registers the specified fingerprint data on the terminal if the
value of “dwBackupNumber” is between 0 and 9 assigned when the function is
accessed. At the moment, the value of the variable designated by “dwPassWord”
has no meaning.
The function registers the specified password data on the terminal if the value
of “dwBackupNumber” is 10 assigned when the function is accessed. At the moment,
the value of the variable designated by “dwEnrollData” has no meaning.

2.3 Function “DeleteEnrollData”


[Function]
Function “DeleteEnrollData” is used to delete the specified data from the
appointed terminal.
[Format]
BOOL DeleteEnrollData(
long dwMachineNumber,
long dwEnrollNumber,
long dwEMachineNumber,
long dwBackupNumber);
[Parameter]

- 5 -
dwMachineNumber : It stands for the ID number of the terminal which the
data will be deleted from.
dwEnrollNumber : Registration number of the data to delete.
dwEMachineNumber : ID number of the terminal which the data has been
registered on.
dwBackupNumber : Backup number of the data to delete The values of the
backup numbers are as the following.

Value Meaning
Fingerprint data ranging from No.0
0~9
to No.9
10 Password data
11 Card data
12 All fingerprint and password data
13 All fingerprint data

[Return Value]
It is TRUE when the deletion command has accurately been transferred to the
specified terminal and successfully been executed on it.
It would be FALSE if the appointed terminal does not exist or the operation has
resulted in failure.
[Attention]
The function deletes, at a time, all the backup-registered fingerprint data of
the user designated by “dwEnrollNumber” and “dwEMachineNumber” when the value of
“dwBackupNumber” is 13; it, at a time, deletes the backup-registered fingerprint
and password data and card data of the user designated by “dwEnrollNumber” and
“dwEMachineNumber” when the value of “dwBackupNumber” is 12.

2.4 Function “ReadSuperLogData”


[Function]
Function “ReadSuperLogData” is used to read the newly-recorded management data
from the specified terminal one by one in order and store them in the internal
memory.
[Format]
BOOL ReadSuperLogData(
long dwMachineNumber);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal to read the
data from.
[Return Value]
It is TRUE when the data has been read from the specified terminal.
It would be FALSE if the specified terminal does not exist, it does not have any
newly-recorded management data on it or an error has occurred to the data
communication.
[Attention]
Function “ReadSuperLogData” reads the newly-recorded management data from the
specified terminal and stores them in the internal memory.
The function does not read the data which have ever been read out once before.
Using function “GetSuperLogData”, the user can, one by one, get the data
stored in the internal memory.

2.5 Function “GetSuperLogData”


[Function]
Function “GetSuperLogData” is used to get the newly-recorded management data
one by one in order from the internal memory.
[Format]
BOOL GetSuperLogData(
long dwMachineNumber,
long* dwTMachineNumber,
long* dwSEnrollNumber,

- 6 -
long* dwSMachineNumber,
long* dwGEnrollNumber,
long* dwGMachineNumber,
long* dwManipulation,
long* dwBackupNumber,
long* dwYear,
long* dwMonth,
long* dwDay,
long* dwHour,
long* dwMinute);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal to read the
data from.
dwTMachineNumber : A pointer to the Long-type variable receiving the value
of the ID number of the terminal the data belongs to
dwSEnrollNumber : A pointer to the Long-type variable receiving the value
of the registration number of the manager who conducted
operations.
The value of this parameter is 0 when there is no manager
registered.
dwSMachineNumber : A pointer to the Long-type variable receiving the value
of the ID number of the terminal the manager has been
registered on.
dwGEnrollNumber : A pointer to the Long-type variable receiving the value
of the registration number of the operated object for
management operations.
The value of this parameter is 0 when the operated object
is a terminal itself (in case of changing the system info
of the terminal).
dwGMachineNumber : A pointer to the Long-type variable receiving the value
of the ID number of the terminal the operated object has
been registered on.
The value of this parameter is 0 when the operated object
is a terminal itself (in case of changing the system info
of the terminal).
dwManipulation : A pointer to the Long-type variable receiving the value
of the mode of the management operation conducted on the
terminal.
Below are the values of the management operation.
Value Meaning
A new general user has been enrolled on
3
the terminal.
A new manager has been enrolled on the
4
terminal.
A fingerprint data has been deleted from
5
the terminal.
A password data has been deleted from the
6
terminal.
A card data has been deleted from the
7
terminal.
All of the record data have been deleted
8
from the terminal.
The system setup info has been changed on
9
the terminal.
The date/time has been changed on the
10
terminal.
The record setup info has been changed on
11
the terminal.
The communication setup info has been
12
changed on the terminal.

dwBackupNumber : A pointer to the Long-type variable receiving the value


of the backup number of a registration data when
management operations (enrollment and deletion) are
conducted on it.
Below are values of the backup number.
Value Meaning
0~9 Fingerprint data ranging from No.0

- 7 -
to No.9
10 Password data
11 Card data

dwYear : A pointer to the Long-type variable receiving the value


of the year of the date when the management operation was
conducted.
dwMonth : A pointer to the Long-type variable receiving the value
of the month of the date when the management operation was
conducted.
dwDay : A pointer to the Long-type variable receiving the value
of the day of the date when the management operation was
conducted.
dwHour : A pointer to the Long-type variable receiving the value
of the hour of the time when the management operation was
conducted.
dwMinute : A pointer to the Long-type variable receiving the value
of the minute of the time when the management operation
was conducted.
[Return Value]
It is TRUE when an efficient data has been read from the internal memory.
It would be FALSE if there is no efficient data in the memory or the data were
all read out already from it. The values of the parameters have no meaning when
the return value is FALSE.
[Attention]
This function, one by one in order, gets the data that function
“ReadSuperLogData” read from the specified terminal and stored in the memory.
The function returns TRUE whenever it gets efficient data out. It returns FALSE
when it has gotten all of the data.

When the value of “ReadMark Property” is TRUE, the data cannot, any longer, be
read out from the terminal using function “ReadSuperLogData” after getting them
from the memory by using “GetSuperLogData”. The newly-recorded management data
alone except those data will be able to be read when accessing function
“ReadSuperLogData” the next time.
If the user is reading the management data stored in the memory one by one, but
fails to read all for some reason, which leads the return value to FALSE, he/she
will be able to read those unread data again when accessing function
“ReadSuperLogData” the next time.
If the value of “ReadMark Property” is FALSE, the user is able to read the data
stored in the internal memory, using function “ReadSuperLogData” again even
after getting them by making use of “GetSuperLogData”.

2.6 Function “ReadGeneralLogData”


[Function]
Function “ReadGeneralLogData” is used to read the newly-recorded attendance
data one by one from the specified terminal and store them in the internal
memory.
[Format]
BOOL ReadGeneralLogData(
long dwMachineNumber);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal to read the
data from.
[Return Value]
It is TRUE when the efficient data has been read from the specified terminal.
It would be FALSE if the specified terminal does not exist, it does not have any
newly-recorded attendance data on it or an error has occurred to the data
communication.

2.7 Function “GetGeneralLogData”


[Function]

- 8 -
Function “GetGeneralLogData” is used to get the newly-recorded attendance data
one by one in order from the internal memory.
[Format]
BOOL GetGeneralLogData(
long dwMachineNumber,
long* dwTMachineNumber,
long* dwEnrollNumber,
long* dwEMachineNumber,
long* dwVerifyMode,
long* dwYear,
long* dwMonth,
long* dwDay,
long* dwHour,
long* dwMinute);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal to read the
data from.
dwMachineNumber : ID number of the terminal to read the data from
dwTMachineNumber : A pointer to the Long-type variable receiving the value
of the ID number of the terminal the user passed through.
dwEnrollNumber : A pointer to the Long-type variable receiving the value
of the registration number of the user who came or left
dwEMachineNumber : A pointer to the Long-type variable receiving the value
of the ID number of the terminal the user has been
registered on.
dwVerifyMode : A pointer to the Long-type variable receiving the value
of the mode of verifying the user who came or left

The values have the following meanings.

Value Meaning
1 Fingerprint-based verification mode
2 Password-based verification mode
3 Card-based verification mode
51 In : Fingerprint-based verification mode
52 In : Password-based verification mode
53 In : Card-based verification mode
101 Out : Fingerprint-based verification mode
102 Out : Password-based verification mode
103 Out : Card-based verification mode
151 Extra: Fingerprint-based verification mode
152 Extra: Password-based verification mode
153 Extra: Card-based verification mode
10 Hand lock
11 Program lock
12 Program open
13 Program close
14 Auto recover
20 Lock over
21 Illegal open

dwYear : A pointer to the Long-type variable receiving the value


of the year of the date when the user came or left
dwMonth : A pointer to the Long-type variable receiving the value
of the month of the date when the user came or left

- 9 -
dwDay : A pointer to the Long-type variable receiving the value
of the day of the date when the user came or left
dwHour : A pointer to the Long-type variable receiving the value
of the hour of the time when the user came or left
dwMinute : A pointer to the Long-type variable receiving the value
of the minute of the time when the user came or left
[Return Value]
It is TRUE when an efficient data has been read from the internal memory.
It would be FALSE if there is no efficient data in the memory or the data were
all read out already from it. The values of the parameters have no meaning when
the return value is FALSE.
[Attention]
This function, one by one in order, gets the data that function
“ReadGeneralLogData” read from the specified terminal and stored in the memory.
The function returns TRUE whenever it gets efficient data out. It returns FALSE
when it has gotten all of the data.

When the value of “ReadMark Property” is TRUE, the data cannot, any longer, be
read out from the terminal using function “ReadGeneralLogData” after getting
them from the memory by using “GetGeneralLogData”. The newly-recorded management
data alone except those data will be able to be read when accessing function
“ReadGeneralLogData” the next time.
If the user is reading the management data stored in the memory one by one, but
fails to read all for some reason, which leads the return value to FALSE, he/she
will be able to read those unread data again when accessing function
“ReadGeneralLogData” the next time.
If the value of “ReadMark Property” is FALSE, the user is able to read the data
stored in the internal memory, using function “ReadGeneralLogData” again even
after getting them by making use of “GetGeneralLogData”.

2.8 Function “ReadAllSLogData”


[Function]
Function “ReadAllSLogData” is used to read all of the recorded management data
from the specified terminal and store them in the internal memory.
[Format]
BOOL ReadAllSLogData(
long dwMachineNumber);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal to read the
data from.
[Return Value]
It is TRUE when the data has been read from the specified terminal.
It would be FALSE if the specified terminal does not exist, it does not have any
management data recorded on it or an error has occurred to the data
communication.
[Attention]
Function “ReadAllSLogData” reads all of the management data out from the
specified terminal and stores them in the internal memory.
Unlike “ReadSuperLogData”, this function also reads the management data which
have ever been read before as well as the newly-recorded ones as long as they
have not been deleted.
Using function “GetAllSLogData”, the user can get the data stored in the
internal memory.

2.9 Function “GetAllSLogData”


[Function]
Function “GetAllSLogData” is used to get all of the management data from the
internal memory.
[Format]
BOOL GetAllSLogData(
long dwMachineNumber,
long* dwTMachineNumber,

- 10 -
long* dwSEnrollNumber,
long* dwSMachineNumber,
long* dwGEnrollNumber,
long* dwGMachineNumber,
long* dwManipulation,
long* dwBackupNumber,
long* dwYear,
long* dwMonth,
long* dwDay,
long* dwHour,
long* dwMinute);
[Attention]
The function gets the data which function “ReadAllSLogData” read from the
specified terminal and stored in the internal memory.
The method of using this function is the same as that of “GetSuperLogData”.
Execution of this function has nothing to do with the value of “ReadMark
property”.

2.10 Function “ReadAllGLogData”


[Function]
Function “ReadAllGLogData” is used to read all of the recorded attendance data
from the specified terminal and store them in the internal memory.
[Format]
BOOL ReadAllGLogData(
long dwMachineNumber);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal to read the
data from.
[Return Value]
It is TRUE when the efficient data has been read from the specified terminal.
It would be FALSE if the specified terminal does not exist, it does not have any
attendance data recorded on it or an error has occurred to the data
communication.
[Attention]
Function “ReadAllGLogData” reads all of the attendance data out from the
specified terminal and stores them in the internal memory.
Unlike “ReadGeneralLogData”, this function also reads the attendance data
which have ever been read before as well as the newly-recorded ones as long as
they have not been deleted.
Using function “GetAllGLogData”, the user can get the data stored in the
internal memory.

2.11 Function “GetAllGLogData”


[Function]
Function “GetAllGLogData” is used to get all of the attendance data from the
internal memory.
[Format]
BOOL GetAllGLogData(
long dwMachineNumber,
long* dwTMachineNumber,
long* dwEnrollNumber,
long* dwEMachineNumber,
long* dwVerifyMode,
long* dwYear,
long* dwMonth,
long* dwDay,
long* dwHour,
long* dwMinute);
[Attention]
The function gets the data which function “ReadAllGLogData” read from the
specified terminal and stored in the internal memory.
The method of using this function is the same as that of “GetGeneralLogData”.

- 11 -
Execution of this function has nothing to do with the value of “ReadMark
property”.

2.12 Function “GetDeviceStatus”


[Function]
Function “GetDeviceStatus” is used to get the designated status information of
the specified terminal.
[Format]
BOOL GetDeviceStatus(
long dwMachineNumber,
long dwStatus,
long* dwValue);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal the status
info of which to get.
dwStatus : Type of the status info to get
Below are values of this parameter.
Value Meaning
The number of managers currently
1
registered on the terminal
The number of users currently registered
2
on the terminal
Amount of fingerprints currently
3
registered on the terminal
Amount of passwords currently registered
4
on the terminal
The number of management data currently
5
recorded on the terminal
The number of attendance data currently
6
recorded on the terminal
Amount of cards currently registered on
7
the terminal

dwValue : A pointer to the Long-type variable receiving the value


of the status information
[Return Value]
It is TRUE when the specified status info has been gotten; it would be FALSE
if the operation resulted in failure.
[Attention]
The data acquired by this function are alike ones shown on the “system Info
View” menu on the terminal.

2.13 Function “GetDeviceInfo”


[Function]
Function “GetDeviceInfo” is used to get the specified setup info of the
designated terminal.
[Format]
BOOL GetDeviceInfo(
long dwMachineNumber,
long dwInfo,
long* dwValue);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal the setup
info of which to get.
dwInfo : Type of the setup info to get
dwValue : A pointer to the Long-type variable receiving the value
of the setup info

[Return Value]
It is TRUE when the specified setup info has been gotten; it would be FALSE if
the operation resulted in failure.
[Attention]

- 12 -
The data acquired by this function are the same as those shown on the “Device
Setup” menu on the terminal excepting the date separators.

Below are values of the setup information.


Value Meaning Range
Maximum number of managers register able
1 0~10
on a terminal
2 ID numbers of terminals 1~255
0 English
3 Languages 1 Chinese (simplified)
2 Chinese (traditional)
4 Auto power-off interval (minute) 0~255
The interval of unlocking. (second)
5 0-16
(AllpaBIO)
The number of attendance data generating
6 0~1500
an overflow alarm
The number of management data generating
7 0~255
an overflow alarm
8 Verification interval (minute) 0~255
3 9,600 bps
4 19,200 bps
5 38,400 bps
9 Baud rate
6 57,600 bps

7 115,200 bps

0 No making parity check


Parity check
10 1 Even check
(no effect)
2 Odd check
Stop bit 0 Stop bit 1
11
(no effect) 1 Stop bit 2
0 ‘/’
12 Date separators
1 ‘-’

2.14 Function “SetDeviceInfo”


[Function]
Function “SetDeviceInfo” is used to set the specified setup info of the
designated terminal to a new value.
[Format]
BOOL SetDeviceInfo(
long dwMachineNumber,
long dwInfo,
long dwValue);
[Parameter]
dwMachineNumber : It stands for the ID number of the terminal the setup
info of which to set
dwInfo : Type of the setup info to set The value of this
parameter is the same as that of “dwInfo” of function
“GetDeviceInfo”.
dwValue : New value to set
[Return Value]
It is TRUE when the specified setup info has been set on the designated
terminal; it would be FALSE if the operation resulted in failure.

- 13 -
2.15 Function “EnableDevice”
[Function]
Function “EnableDevice” is used to enable or forbid the specified terminal to
record the attendance data.
[Format]
BOOL EnableDevice(
long dwMachineNumber,
long bFlag);
[Parameter]
dwMachineNumber : ID number of the terminal
bflag : Flag indicating enabling or forbiddance
TRUE stands for enabling. FALSE forbiddance.
[Return Value]
Success returns TRUE; failure FALSE.
[Attention]
This function makes it possible to or impossible to input figures by the
keypad and to capture fingerprints on the individual terminals.
It is better to set the value of “bFlag” to FALSE before accessing this function
when the supervising computer exchanges the data with the terminal, and to set
the value of “bFlag” to TRUE before access when their exchange has been
finished. In other words, the user should suspend the terminal’s working, using
this function during an exchange of the data.
The function returns FALSE when the specified terminal lies in the status of
management operations or it has been powered off.

2.16 Function “EnableUser”


[Function]
Function “EnableUser” is used to permit or forbid the specified user to have
his/her attendances recorded on the designated terminal.
[Format]
BOOL EnableUser(
long dwMachineNumber,
long dwEnrollNumber,
long dwEMachineNumber,
long dwBackupNumber,
long bFlag);
[Parameter]
dwMachineNumber : ID number of the terminal
dwEnrollNumber : Registration number of the user
dwEMachineNumber : ID number of the terminal the user has been registered
on
dwBackupNumber : Backup number
The meaning of this data is the same as the value of
parameter “dwBackupNumber” of function “DeleteEnrollData”.
bflag : Flag indicating permission or forbiddance
TRUE stands for enabling. FALSE forbiddance.
[Return Value]
Success returns TRUE; failure FALSE.
[Attention]
This function makes it possible or impossible for an individual user to have
his/her attendances recorded on the individual terminals.
According to the value of “dwBackupNumber”, the function permits/forbids
operations on one or all of the registered fingerprints and password data of the
specified user.

2.17 Function “SetDeviceTime”


[Function]
Function “SetDeviceTime” is used to change the current date/time on the
specified terminal.
[Format]

- 14 -
BOOL SetDeviceTime(
long dwMachineNumber);
[Parameter]
dwMachineNumber : ID number of the terminal
[Return Value]
Success returns TRUE; failure FALSE.
[Attention]
This function sets the date/time of the terminal to those of the supervising
computer.

2.18 Function “GetDeviceTime”


[Function]
Function “GetDeviceTime” is used to get the current date/time of the specified
terminal.
[Format]
BOOL GetDeviceTime(
long dwMachineNumber,
long* dwYear,
long* dwMonth,
long* dwDay,
long* dwHour,
long* dwMinute,
long* dwDayOfWeek);
[Parameter]
dwMachineNumber : ID number of the terminal
dwYear : a pointer to the Long-typed variable receiving the
value of year of the current date of the terminal
dwMonth : a pointer to the Long-typed variable receiving the
value of month of the current date of the terminal
dwDay : a pointer to the Long-typed variable receiving the
value of day of the current date of the terminal
dwHour : a pointer to the Long-typed variable receiving the
value of hour of the current time of the terminal
dwMinute : a pointer to the Long-typed variable receiving the
value of minute of the current time of the terminal
dwDayOfWeek : a pointer to the Long-typed variable receiving the
value of weekday of the current date of the terminal
Value Meaning
1 Sunday
2 Monday
3 Tuesday
4 Wednesday
5 Thursday
6 Friday
7 Saturday

[Return Value]
Success returns TRUE; failure FALSE.

2.19 Function “PowerOnAllDevice”


[Function]
Function “PowerOnAllDevice” is used to power on all of the terminals.
[Format]
void PowerOnAllDevice( void );
[Parameter]
void
[Return Value]
void

- 15 -
2.20 Function “PowerOffDevice”
[Function]
Function “PowerOffDevice” is used to power off the specified terminal.
[Format]
BOOL PowerOffDevice(
long dwMachineNumber);
[Parameter]
dwMachineNumber : ID number of the terminal to power off
[Return Value]
Success returns TRUE; failure FALSE.

2.21 Function “ModifyPrivilege”


[Function]
Function “ModifyPrivilege” is used to modify the device authority of the
appointed user for the designated identification information on the specified
terminal.
[Format]
BOOL ModifyPrivilege(
long dwMachineNumber,
long dwEnrollNumber,
long dwEMachineNumber,
long dwBackupNumber,
long dwMachinePrivilege);
[Parameter]
dwMachineNumber : ID number of the terminal
dwEnrollNumber : Registration number of the user
dwEMachineNumber : ID number of the terminal the user has been registered
on
dwBackupNumber : Backup number
The meaning of this data is the same as the value of
parameter “dwBackupNumber” of function “DeleteEnrollData”.
dwMachinePrivilege : New authority to set.
[Return Value]
Success returns TRUE; failure FALSE.
[Attention]
This function changes the device authority of the appointed user for the
designated identification information on the specified terminal.
According to the value of “dwBackupNumber”, the function changes the device
authority of the specified user for one or all of the registered fingerprints
and password data into the value of “dwMachinePrivilege”.

2.22 Function “ReadAllUserID”


[Function]
Function “ReadAllUserID” is used to read the registration info of all the
enrolled users from the specified terminal and store them in the internal
memory.
[Format]
BOOL ReadAllUserID(
long dwMachineNumber);
[Parameter]
dwMachineNumber : ID number of the terminal to read the data from
[Return Value]
It is TRUE when the data have been read from the specified terminal.
It would be FALSE if the specified terminal does not exist, it does not have any
registration data on it or an error has occurred to the data communication.

- 16 -
2.23 Function “GetAllUserID”
[Function]
Function “GetAllUserID” is used to get one by one the registration data of the
users from the internal memory.
[Format]
BOOL GetAllUserID(
long dwMachineNumber,
long* dwEnrollNumber,
long* dwEMachineNumber,
long* dwBackupNumber,
long* dwMachinePrivilege,
long* dwEnable);
[Parameter]
dwMachineNumber : ID number of the terminal to read the data from
dwEnrollNumber : A pointer to the Long-type variable receiving the value
of the registration number of the user
dwEMachineNumber : A pointer to the Long-type variable receiving the value
of the ID number of the terminal the user has been
registered on
dwBackupNumber : A pointer to the Long-type variable receiving the value
of the backup number of the user
dwMachinePrivilege : A pointer to the Long-type variable receiving the value
of the device authority of the user
dwEnable : A pointer to the Long-type variable receiving the value
of attendance record permission of the user
Value Meaning
Record of an attendance of this user has been
1
permitted.
Record of an attendance of this user has been
2 forbidden, that is, his/her attendance is not
recorded in spite of his/her registration.

[Return Value]
It is TRUE when an efficient data has been read from the internal memory.
It would be FALSE if there is no efficient data in the memory or the data were
all read out already from it. The values of the parameters have no meaning when
the return value is FALSE.
[Attention]
This function, one by one in order, gets the data that function
“ReadAllUserID” read from the specified terminal and stored in the memory.
The function returns TRUE whenever it gets efficient data out. It returns FALSE
when it has gotten all of the data.

2.24 Function “GetSerialNumber”


[Function]
Function “GetSerialNumber” is used to get the serial number or license of the
product.
[Format]
BOOL GetSerialNumber(
long dwMachineNumber,
BSTR* dwSerialNumber);
[Parameter]
dwMachineNumber : ID number of the terminal to read the data from
dwSerialNumber : 32Byte character string pointer for getting the serial
number or license of the product
[Return Value]
Success returns TRUE; failure FALSE.

- 17 -
2.25 Function “ClearKeeperData”
[Function]
Function “ClearKeeperData” is used to delete all of the data registered or
recorded on the terminal.
[Format]
BOOL ClearKeeperData(
long dwMachineNumber);
[Parameter]
dwMachineNumber : ID number of the terminal to read the data from
[Return Value]
Success returns TRUE; failure FALSE.

2.26 Function “GetLastError”


[Function]
Function “GetLastError” is used to get the last error info.
[Format]
void GetLastError(
long* dwErrorCode);
[Parameter]
dwErrorCode : A pointer to the Long-type variable receiving the value
of the error code

Value Meaning
0 The operation has been finished with success.
1 The COM port is not able to be opened.
An error has happened to transmission of the
2
data.
3 An error has happened to receipt of the data.
An invalid parameter was used when accessing
4
the function.
5 The operation has resulted in failure.
The recorded data have all been read out from
6
the internal memory.

[Return Value]
Success returns TRUE; failure FALSE.
[Attention]
When the functions (GetSuperLogData, GetAllSLogData, GetGeneralLogData and
GetAllGLogData), used to get recorded data, return “FLASE”, “6” is acquired as
the value of an error code after accessing function “GetLastError”, which means
having read all the recorded data stored in the internal memory.

2.27 Function “GetBackupNumber”


[Function]
Function “GetBackupNumber” is used to get the management number of the product.
[Format]
long GetBackupNumber(
long dwMachineNumber);
[Parameter]
dwMachineNumber : ID number of the terminal to read the data from
[Return Value]
The function gets the management number of the terminal.

- 18 -
2.28 Function “GetProductCode”
[Function]
Function “GetProductCode” is used to get the product information of the user.
[Format]
BOOL GetProductCode(
long dwMachineNumber,
BSTR* lpszProductCode);
[Parameter]
dwMachineNumber : ID number of the terminal to read the data from
lpszProductCode : 32Byte character string pointer for getting the code of
the product
[Return Value]
Success returns TRUE, and failure FALSE.

2.29 Function “EmptyEnrollData”


[Function]
Function “EmptyEnrollData” is used to delete all the registered data from the
specified terminal.
[Format]BOOL EmptyEnrollData(
long dwMachineNumber);
[Parameter]
dwMachineNumber : ID number of the terminal to delete the registration
data from
[Return Value]
Success returns TRUE, and failure FALSE.

2.30 Function “EmptyGeneralLogData”


[Function]
Function “EmptyGeneralLogData” is used to delete all the attendance (access)
data from the specified terminal.
[Format]
BOOL EmptyGeneralLogData(
long dwMachineNumber);
[Parameter]
dwMachineNumber : ID number of the terminal to delete the attendance
(access) data from
[Return Value]
Success returns TRUE, and failure FALSE.

2.31 Function “EmptySuperLogData”


[Function]
Function “EmptySuperLogData” is used to delete all the management data from the
specified terminal.
[Format]
BOOL EmptySuperLogData(
[Parameter]
dwMachineNumber : ID number of the terminal to delete the management data from
[Return Value]
Success returns TRUE, and failure FALSE.

2.32 Function “GetUserName”


[Function]
Function "GetUserName" is used to get one of the specified registration user's
name data from the terminal.
[Format]

- 19 -
BOOL GetUserName(
long DeviceKind,
long dwMachineNumber,
long dwEnrollNumber,
long dwEMachineNumber,
VARIANT* dwUserName);
[Parameter]
DeviceKind : DeviceKind
1 : FK3xx(SH3) 2 : FK5xx(S3C44B0)

dwMachineNumber : ID number of the terminal to get from.


dwEnrollNumber : Registration number of the data to get.
dwEmachineNumber : ID number of the terminal which the data has been
registered on.
dwUserName : A VARIANT-type pointer (UNICODE BSTR) to the cache
receiving the value of the registration user's name data
to get.
[Return Value]
It is TRUE when a valid data has been read from the terminal.
It would FALSE if the terminal does not have the specified data on it or an
error has occurred to the communication. When the return value FALSE, the value
of parameters have no meanings.

2.33 Function “SetUserName”


[Function]
Function "SetUserName" is used to download the specified user's name data to the
appointed terminal.
[Format]
BOOL SetUserName(
long DeviceKind,
long dwMachineNumber,
long dwEnrollNumber,
long dwEMachineNumber,
VARIANT* dwUserName);
[Parameter]
DeviceKind : DeviceKind
1 : FK3xx(SH3) 2 : FK5xx(S3C44B0)

dwMachineNumber : ID number of the terminal to download.


dwEnrollNumber : The registration number of the data to download.
dwEmachineNumber : ID number of the terminal which the data has been
registered on.
dwUserName : A VARIANT-type pointer (UNICODE BSTR) to the cache
transmission the value of the registration user's name
data to set
[Return Value]
It is TRUE when the data has accurately been downloaded to the specified
terminal and successfully been operated on it.
It would FALSE if the terminal does not have the specified data on it, or an
error has occurred to the communication or the terminal has failed in its
working.

2.34 Function “GetCompanyName”


[Function]
Function "GetCompanyName" is used to get the display name of a company from the
terminal.
[Format]
BOOL GetCompanyName(
long dwMachineNumber,
VARIANT* dwCompanyName);
[Parameter]
dwMachineNumber : ID number of the terminal to get.
dwCompanyName : A VARIANT-type pointer (UNICODE BSTR) to the cache
receiving the value of the company name data to get

- 20 -
[Return Value]
It is TRUE when a valid data has been read from the terminal.
It would FALSE if the terminal does not have the specified data on it or an
error has occurred to the communication. When the return value is FALSE, the
values of parameters have no meanings.

2.35 Function “SetCompanyName”


[Function]
Function "SetCompanyName" is used to download the display name of a company to
the appointed terminal.
[Format]
BOOL SetCompanyName(
long dwMachineNumber,
long vKind,
VARIANT* dwCompanyName);
[Parameter]
dwMachineNumber : ID number of the terminal to download.
vKind : Valid or invalid parameter to display name of company.
1 : Valid, 0 : invalid.
dwCompanyName : A VARIANT-type pointer (UNICODE BSTR) to the cache
transmission the value of the company name data to
download.
[Return Value]
It is TRUE when the data has accurately been downloaded to the specified
terminal and successfully been operated on it.
It would FALSE if the terminal does not have the specified data on it, or an
error has occurred to the communication or the terminal has failed in its
working.

2.36 Function “GetDoorStatus”


[Function]
Function "GetDoorStatus" is used to get the current door status from the
terminal.
[Format]
BOOL GetDoorStatus(
long dwMachineNumber,
long* dwValue);
[Parameter]
dwMachineNumber : ID number of the terminal to get.
dwValue : A long-type pointer to the value of the door status.
1 : Force open
2 : Force close
3 : Program open
4 : Auto recover.
[Return Value]
It is TRUE when a valid data has been read from the terminal.
It would FALSE if the terminal does not have the specified data on it or an
error has occurred to the communication. When the return value is FALSE, the
values of parameters have no meanings.

2.37 Function “SetDoorStatus”


[Function]
Function "SetDoorStatus" is used to download a door status to the appointed
terminal.
[Format]
BOOL SetDoorStatus(
long dwMachineNumber,
long dwValue);
[Parameter]
dwMachineNumber : ID number of the terminal to download.
dwValue : A long-type to the value of the door status.
1 : Force open

- 21 -
2 : Force close
3 : Program open
4 : Auto recover.
[Return Value]
It is TRUE when the data has accurately been downloaded to the specified
terminal and successfully been operated on it.
It would FALSE if the terminal does not have the specified data on it, or an
error has occurred to the communication or the terminal has failed in its
working.

2.38 Function “GetBellTime”


[Function]
Function "GetBellTime" is used to get the bell time from the terminal.
[Format]
BOOL GetBellTime(
long dwMachineNumber,
long* dwValue,
long* dwBellInfo);
[Parameter]
dwMachineNumber : ID number of the terminal to get.
dwValue : A long-type pointer to the value of the bell count.
dwBellInfo : A long-type pointer to the value of the bell time
information. The data is 36 (AllpaBIO) bytes in size.
[Return Value]
It is TRUE when a valid data has been read from the terminal.
It would FALSE if the terminal does not have the specified data on it or an
error has occurred to the communication. When the return value is FALSE, the
values of parameters have no meanings.

2.39 Function “SetBellTime”


[Function]
Function "SetBellTime" is used to download the bell time to the appointed
terminal.
[Format]
BOOL SetBellTime(
long dwMachineNumber,
long dwValue,
long* dwBellInfo);
[Parameter]
dwMachineNumber : ID number of the terminal to download.
dwValue : A long-type to the value of the bell count..
dwBellInfo : A long-type pointer to the value of the bell time
information. The data is 36 (AllpaBIO) bytes in size.
[Return Value]
It is TRUE when the data has accurately been downloaded to the specified
terminal and successfully been operated on it.
It would FALSE if the terminal does not have the specified data on it, or an
error has occurred to the communication or the terminal has failed in its
working.

2.40 Function “ConnectSerial”


[Function]
Function “ConnectSerial” is used to connect to the terminal via the serial port
(RS232, RS485).
[Format]
BOOL ConnectSerial(
long dwMachineNumber,
long dwCommPort,
long dwBaudRate);
[Parameter]
dwMachineNumber : ID number of the terminal to connect.
dwCommPort : A data communication port of the supervising computer.

- 22 -
Value Meaning
1 COM1
2 COM2
3 COM3
4 COM4

dwBaudRate : A baudrate of the supervising computer.


Value
9600
19200
38400
57600
115200

[Return Value]
Success returns TRUE, and failure FALSE.

2.41 Function “ConnectTcpip”


[Function]
Function “ConnectTcpip” is used to connect to the terminal via the network
(TCP/IP).
[Format]
BOOL ConnectTcpip(
long dwMachineNumber,
BSTR* lpszIPAddress,
long dwPortNumber,
long dwPassWord);
[Parameter]
dwMachineNumber : ID number of the terminal to connect.
lpszIPAddress : IP address of the terminal for network communication.
dwPortNumber : Port number for network communication.
dwPassword : Password for network communication.
[Return Value]
Success returns TRUE, and failure FALSE.

2.42 Function “Disconnect”


[Function]
Function “Disconnect” is used to close the connected session for communication
with the terminal.
[Format]
Void Disconnect( void )
[Parameter]
None.
[Return Value]
None.

- 23 -
3.Property

3.1 Property “ReadMark”


[Function]
The flag shows whether the recorded data can be read again after they have been
read from the terminal by functions “GetGeneralLogData” and “GetSuperLogData” or
not.
If the value of this property is TRUE, the data, which have ever been read
before, will be unable to be read again by functions “GetGeneralLogData” and
“GetSuperLogData”.
However, “GetAllGLogData” and “GetAllSLogData” are able to read all the data.
If the value of this property is FALSE, the data, which have ever been read
before, will be able to be read again by “GetGeneralLogData” and
“GetSuperLogData”.
[Format]
BOOL ReadMark
[Initial Value]
TRUE

- 24 -

You might also like