C API for BALTECH SDK
hitag.h
Go to the documentation of this file.
1 
10 #ifndef __BRP_BALTECH_API_CMDS_HITAG_H__
11 #define __BRP_BALTECH_API_CMDS_HITAG_H__
12 #include "../typedefs.h"
16 #define BRP_Hitag_ErrHtgNoTag BRP_ERR_STATUS(0x3000, 0x01)
17 
20 #define BRP_Hitag_ErrHtgCollision BRP_ERR_STATUS(0x3000, 0x02)
21 
24 #define BRP_Hitag_ErrHtgRxdata BRP_ERR_STATUS(0x3000, 0x03)
25 
28 #define BRP_Hitag_HtgChecksum BRP_ERR_STATUS(0x3000, 0x04)
29 
32 #define BRP_Hitag_HtgWrongParam BRP_ERR_STATUS(0x3000, 0x07)
33 
36 #define BRP_Hitag_ErrHtgAuth BRP_ERR_STATUS(0x3000, 0x09)
37 
40 #define BRP_Hitag_ErrHtgOvTo BRP_ERR_STATUS(0x3000, 0x08)
41 
44 #define BRP_Hitag_ErrHtgHw BRP_ERR_STATUS(0x3000, 0x0A)
45 
48 #define BRP_Hitag_ErrHtgCr BRP_ERR_STATUS(0x3000, 0x0B)
49 
52 #define BRP_Hitag_ErrHtgCfg BRP_ERR_STATUS(0x3000, 0x0C)
53 
56 #define BRP_Hitag_ErrHtgHfreqctrl BRP_ERR_STATUS(0x3000, 0x0D)
57 
60 #define BRP_Hitag_ErrHtgHwNotSupported BRP_ERR_STATUS(0x3000, 0x0F)
61 
79 brp_errcode brp_Hitag_Select(brp_protocol protocol, brp_Hitag_Select_SelMode SelMode, unsigned Pwd, unsigned* Page1);
99 brp_errcode brp_Hitag_Read(brp_protocol protocol, unsigned Address, bool InvRead, bool KeyB, bool Encrypt, bool BlockRead, unsigned** PageNr, size_t* PageNr_len, brp_mempool *mempool);
111 brp_errcode brp_Hitag_Write(brp_protocol protocol, unsigned Address, bool KeyB, bool Encrypt, bool BlockWrite, unsigned* PageNr, size_t PageNr_len);
121 brp_errcode brp_Hitag_PersonaliseHtg(brp_protocol protocol, bool Reset, bool HtgS, unsigned* Len, size_t Len_len);
122 #endif
123 
brp_errcode brp_Hitag_Read(brp_protocol protocol, unsigned Address, bool InvRead, bool KeyB, bool Encrypt, bool BlockRead, unsigned **PageNr, size_t *PageNr_len, brp_mempool *mempool)
Reads a Hitag1/S label.
unsigned int brp_errcode
This type is used library-wide for passing error codes in the return value of functions.
Definition: errorcodes.h:23
struct brp_protocol_t * brp_protocol
This is a generic handle of a protocol.
Definition: protocol.h:34
brp_errcode brp_Hitag_Request(brp_protocol protocol, brp_Hitag_Request_TagType TagType, brp_Hitag_Request_Mode Mode, unsigned *Snr)
Request and AC / according to Mode byte you can request Hitag-1 and Hitag-S tags. ...
struct brp_mempool_object_t * brp_mempool
mempool handle.
Definition: mempool.h:27
brp_errcode brp_Hitag_Write(brp_protocol protocol, unsigned Address, bool KeyB, bool Encrypt, bool BlockWrite, unsigned *PageNr, size_t PageNr_len)
Writes data to a Hitag1/S label.
brp_Hitag_Request_TagType
Definition: typedefs.h:1070
brp_errcode brp_Hitag_Select(brp_protocol protocol, brp_Hitag_Select_SelMode SelMode, unsigned Pwd, unsigned *Page1)
Selects a Hitag-1 or Hitag-S tag and returns page 1.
brp_errcode brp_Hitag_Halt(brp_protocol protocol)
Sets a Hitag1/S label in halt mode.
brp_errcode brp_Hitag_PersonaliseHtg(brp_protocol protocol, bool Reset, bool HtgS, unsigned *Len, size_t Len_len)
Writes personalization data for Hitag1/2 to coprocessor.
brp_Hitag_Select_SelMode
Definition: typedefs.h:1110
brp_Hitag_Request_Mode
Definition: typedefs.h:1092