|
参考:
Public Declare Function init_com Lib "sure32wc.dll" (ByVal port As Long) As Long
'初始化串行口: port=0 串行口1 , port=1 串行口2 返回值:0 成功,4 串行口错
Public Declare Function sele_card Lib "sure32wc.dll" (ByVal cardtype As Long) As Long
'选择卡的类型 cardtype =42 为 IC卡 返回值:0 成功
Public Declare Function power_on Lib "sure32wc.dll" () As Long
'给卡上电 返回值: 0成功 ,2无卡 ,4串行口错
'passwordpasswordpasswordpassword
Public Declare Function power_off Lib "sure32wc.dll" () As Long
'卡下电 自弹式读写机同时退卡 返回值:0成功,2无卡,4串行口错
Public Declare Function close_com Lib "sure32wc.dll" () As Long
'关闭串行口 返回值: 0 成功,4 串行口错
Public Declare Function rd_str Lib "sure32wc.dll" (ByVal apz As Long, ByVal address As Long, ByVal length As Long, ByVal buffers As String) As Long
Public Declare Function wr_str Lib "sure32wc.dll" (ByVal apz As Long, ByVal address As Long, ByVal length As Long, ByVal buffers As String) As Long
Public Declare Function rd_asc Lib "sure32wc.dll" (ByVal apz As Long, ByVal address As Long, ByVal length As Long, ByVal buffers As String) As Long
Public Declare Function wr_asc Lib "sure32wc.dll" (ByVal apz As Long, ByVal address As Long, ByVal length As Long, ByVal buffers As String) As Long
'读卡或写卡 :参数apz 为写卡的区域 0为公用区 1为应用数据区 address 为读取或写入的起始地址
'length 为读取或写入的字节数 buffers 为读写数据的缓冲区
Public Declare Function chk_sc Lib "sure32wc.dll" (ByVal i1 As Long, ByVal i2 As Long, ByVal STR As String) As Long
'核对密码 返回值:0 正确,11密码错
Public Declare Function wr_sc Lib "sure32wc.dll" (ByVal STR As String) As Long
'写入新的密码
Public Declare Function inquire Lib "sure32wc.dll" (ByVal STR As String) As Long
'读取读写器状态
|
|