ACR1281U-C8 – Application Programming Interface
Version 1.00
www.acs.com.hk
Page 13 of 52
3.7. ACR120_DirectSend
Directly sends data to the Mifare® Chip.
High Level API
:
DLLAPI INT16 AC_DECL
ACR120_DirectSend( UINT16 hReader,
UINT8 DataLength,
UINT8* pData,
UINT8* pResponseDataLength,
UINT8* pResponseData,
UINT16 TimedOut,);
Parameters
Description
hReader
Handle to the Reader returned by AC_Open()
DataLength (N)
Data length (maximum of 66 bytes)
Data
Data to be sent
pResponseDataLength (K) Response data length
pResponseData
Response Data
TimedOut
Time Out for waiting the response data (ms)
Return Value
INT16
0 = success; Error Code < 0
Table 8
: ACR120_DirectSend Command Description
Low Level Frame Structure:
Command: From PC to Reader (N + 3) bytes; 2<=N<=66
Command Code
(1 byte)
Command Data Length
(1 bytes)
Data
(N bytes)
E0h
DataLength
(2<=N<=66)
N bytes of Data
Maximum of 66 bytes
Response: From Reader to PC (K + 5) bytes <<Success or Fail>>
Response Code
(1 byte)
Response Status
(2 bytes)
Response Data Length
(2 bytes)
Response Data
(K bytes)
E1h
INT16
pResponseDataLength (K)
pResponseData
Note:
ACR120_DirectSend()
&
ACR120_DirectReceive()
must be used in a pair.