Zkteco iface702 Time Attendance Machine Java Development Step One---connection attendance machine

Source: Internet
Author: User

Java uses Jacob to call the master Attendance Machine SDK Method 1, jacob-1.19 version

2, jdk1.8 64 bits (tested JACOB.1.19 support 64 for JDK);

3, put Jacob.jar into the project Web-info/lib under import:

4, put Jacob-1.19-x64.dll into 64-bit Jre/bin directory, my is: D:\java\jdk1.8.0_101\jre\bin;

5, the central control attendance Machine SDK dll files are all put into the C:\Windows\System32 directory

6. Run cmd to register zkemkeeper.dll--->regsvr32 c:\windows\system32\zkemkeeper.dll (you can also use autoenrollment. bat)

7, after the success of the following tips: There will be a bullet box

8, has been configured to test the code:

Zkemkeeper. Zkem.1 for Zkemkeeper.dll after successful registration in the registry can be viewed: HKEY_CLASSES_ROOT the bottom

Package Com.zsplat.zke;import com.jacob.activex.activexcomponent;/** * @ClassName: ${type_name} * @Description: ${todo } (Time Machine connection test) * @author: Zhoupan * @date ${date} ${time} * @Copyright: 2018 Www.zsplat.com Inc. All rights reserved. * ${tags} */public class Zkemsdk {    private static activexcomponent Zkem = new Activexcomponent ("Zkemkeeper. Zkem.1 ");    /** *     Link Attendance Machine     *     * @param address of the attendance machine *     @param port Port    number     *     @return    */Public Boolean Connect (String address, int port) {        Boolean result = Zkem.invoke ("connect_net", address, Port). Getboolean ();        return result;    }    /**     * Disconnect the attendance machine link */public    void DisConnect () {        Zkem.invoke ("DisConnect");    }    public static void Main (string[] args) {        zkemsdk SDK = new Zkemsdk ();        Boolean  Connflag = Sdk.connect ("192.168.1.201", 4370);        SYSTEM.OUT.PRINTLN ("conn:" +connflag);}    }

9, the output is true, the attendance machine link success

  

Zkteco iface702 Time Attendance Machine Java Development Step One---connection attendance machine

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.