summaryrefslogtreecommitdiffstats
path: root/inc/phNfcTypes.h
diff options
context:
space:
mode:
Diffstat (limited to 'inc/phNfcTypes.h')
-rwxr-xr-x[-rw-r--r--]inc/phNfcTypes.h329
1 files changed, 173 insertions, 156 deletions
diff --git a/inc/phNfcTypes.h b/inc/phNfcTypes.h
index 914ae07..f698ddb 100644..100755
--- a/inc/phNfcTypes.h
+++ b/inc/phNfcTypes.h
@@ -101,23 +101,23 @@ typedef unsigned long uint32_t; /**< \ingroup grp_nfc_common
#endif /* _WIN32 */
#ifndef TRUE
-#define TRUE (0x01) /**< \ingroup grp_nfc_common
+#define TRUE (0x01) /**< \ingroup grp_nfc_common
Logical True Value */
#endif
#ifndef FALSE
-#define FALSE (0x00) /**< \ingroup grp_nfc_common
+#define FALSE (0x00) /**< \ingroup grp_nfc_common
Logical False Value */
#endif
-typedef uint8_t utf8_t; /**< \ingroup grp_nfc_common
+typedef uint8_t utf8_t; /**< \ingroup grp_nfc_common
UTF8 Character String */
-typedef uint8_t bool_t; /**< \ingroup grp_nfc_common
- boolean data type */
+typedef uint8_t bool_t; /**< \ingroup grp_nfc_common
+ boolean data type */
typedef uint16_t NFCSTATUS; /**< \ingroup grp_nfc_common
- NFC return values
+ NFC return values
\ref phNfcStatus.h for different status
values */
@@ -126,7 +126,7 @@ typedef uint16_t NFCSTATUS; /**< \ingroup grp_nfc_common
#endif
/* This Macro to be used to resolve Unused and unreference
- * compiler warnings.
+ * compiler warnings.
*/
#define PHNFC_UNUSED_VARIABLE(x) for((x)=(x);(x)!=(x);)
@@ -165,7 +165,7 @@ typedef uint16_t NFCSTATUS; /**< \ingroup grp_nfc_common
#define PHHAL_ATQA_LENGTH 0x02U /**< ATQA length */
#define PHHAL_MAX_UID_LENGTH 0x0AU /**< Maximum UID length expected */
-#define PHHAL_MAX_ATR_LENGTH 0x30U /**< Maximum ATR_RES (General Bytes)
+#define PHHAL_MAX_ATR_LENGTH 0x30U /**< Maximum ATR_RES (General Bytes)
* length expected */
#define PHHAL_ATQB_LENGTH 0x0BU /**< ATQB length */
@@ -180,7 +180,7 @@ typedef uint16_t NFCSTATUS; /**< \ingroup grp_nfc_common
ISO15693 Tag */
#define VENDOR_NAME_LEN 0x14U
-#define MAX_TRANSFER_UNIT 0x21U
+#define MAX_TRANSFER_UNIT 0x21U
#define SESSIONID_SIZE 0x08U
#define MAX_AID_LEN 0x10U
#define MAX_UICC_PARAM_LEN 0xFFU
@@ -212,9 +212,9 @@ typedef uint16_t NFCSTATUS; /**< \ingroup grp_nfc_common
/**
* Data Buffer Structure to hold the Data Buffer
*
- * This structure holds the Data in the Buffer of the specified
+ * This structure holds the Data in the Buffer of the specified
* size.
- *
+ *
*/
typedef struct phNfc_sData_t
{
@@ -226,7 +226,7 @@ typedef struct phNfc_sData_t
* \brief Possible Hardware Configuration exposed to upper layer.
* Typically this should be at least the communication link (Ex:"COM1","COM2")
* the controller is connected to.
- */
+ */
typedef struct phLibNfc_sConfig_t
{
/** Device node of the controller */
@@ -255,29 +255,29 @@ typedef struct phLibNfc_Message_t
* Deferred message. This message type will be posted to the client application thread
* to notify that a deferred call must be invoked.
*/
-#define PH_LIBNFC_DEFERREDCALL_MSG (0x311)
+#define PH_LIBNFC_DEFERREDCALL_MSG (0x311)
/**
*\brief Deferred call declaration.
- * This type of API is called from ClientApplication ( main thread) to notify
+ * This type of API is called from ClientApplication ( main thread) to notify
* specific callback.
*/
typedef void (*pphLibNfc_DeferredCallback_t) (void*);
/**
*\brief Deferred parameter declaration.
- * This type of data is passed as parameter from ClientApplication (main thread) to the
+ * This type of data is passed as parameter from ClientApplication (main thread) to the
* callback.
*/
typedef void *pphLibNfc_DeferredParameter_t;
/**
*\brief Deferred message specific info declaration.
- * This type of information is packed as message data when \ref PH_LIBNFC_DEFERREDCALL_MSG
+ * This type of information is packed as message data when \ref PH_LIBNFC_DEFERREDCALL_MSG
* type message is posted to message handler thread.
- */
+ */
typedef struct phLibNfc_DeferredCall_t
{
- pphLibNfc_DeferredCallback_t pCallback;/**< pointer to Deferred callback */
- pphLibNfc_DeferredParameter_t pParameter;/**< pointer to Deferred parameter */
+ pphLibNfc_DeferredCallback_t pCallback;/**< pointer to Deferred callback */
+ pphLibNfc_DeferredParameter_t pParameter;/**< pointer to Deferred parameter */
} phLibNfc_DeferredCall_t;
@@ -293,7 +293,7 @@ typedef struct phLibNfc_DeferredCall_t
*/
typedef struct phNfc_sSupProtocol_t
{
- unsigned int MifareUL : 1; /**< Protocol Mifare Ultra Light or
+ unsigned int MifareUL : 1; /**< Protocol Mifare Ultra Light or
any NFC Forum Type-2 tags */
unsigned int MifareStd : 1; /**< Protocol Mifare Standard. */
unsigned int ISO14443_4A : 1; /**< Protocol ISO14443-4 Type A. */
@@ -312,11 +312,11 @@ typedef struct phNfc_sSupProtocol_t
* \brief Information related to the NFC Device
*
* The <em> Device Information Structure </em> holds information
- * related to the NFC IC read during initialization time.
+ * related to the NFC IC read during initialization time.
* It allows the caller firware, hardware version, the model id,
- * HCI verison supported and vendor name. Refer to the NFC Device
+ * HCI verison supported and vendor name. Refer to the NFC Device
* User Manual on how to interpret each of the values. In addition
- * it also contains capabilities of the NFC Device such as the
+ * it also contains capabilities of the NFC Device such as the
* protocols supported in Reader and emulation mode
*
*/
@@ -337,10 +337,10 @@ typedef struct phNfc_sDeviceCapabilities_t
Vendor name (Null terminated string)*/
uint8_t full_version[NXP_FULL_VERSION_LEN];
- phNfc_sSupProtocol_t ReaderSupProtocol; /**< Supported protocols
+ phNfc_sSupProtocol_t ReaderSupProtocol; /**< Supported protocols
(Bitmapped) in Reader mode. */
phNfc_sSupProtocol_t EmulationSupProtocol; /**< Supported protocols
- (Bitmapped) in Emulation
+ (Bitmapped) in Emulation
mode. */
char firmware_update_info; /** */
} phNfc_sDeviceCapabilities_t;
@@ -361,79 +361,79 @@ typedef struct phNfc_sDeviceCapabilities_t
typedef enum phNfc_eMifareCmdList_t
{
phNfc_eMifareRaw = 0x00U, /**< This command performs raw transcations .
- Format of the phLibNfc_sTransceiveInfo_t
- content in this case shall be as below:
- • cmd: filed shall set to phHal_eMifareRaw .
+ Format of the phLibNfc_sTransceiveInfo_t
+ content in this case shall be as below:
+ • cmd: filed shall set to phHal_eMifareRaw .
• addr : doesn't carry any significance.
- • sSendData : Shall contain formatted raw buffer
- based on MIFARE commands type used.
- Formatted buffer shall follow below
+ • sSendData : Shall contain formatted raw buffer
+ based on MIFARE commands type used.
+ Formatted buffer shall follow below
formating scheme.
-
+
CmdType+ Block No + CommandSpecific data + 2 byte CRC
- Ex: With Write 4 byte command on block 8 looks as
- " 0xA2,0x08,0x01,0x02,0x03,0x04,CRC1,CRC2
- Note : For MIFARE Std card we recommend use MIFARE
+ Ex: With Write 4 byte command on block 8 looks as
+ " 0xA2,0x08,0x01,0x02,0x03,0x04,CRC1,CRC2
+ Note : For MIFARE Std card we recommend use MIFARE
commands directly.
*/
phNfc_eMifareAuthentA = 0x60U, /**< Mifare Standard:\n
This command performs an authentication with KEY A for a sector.\n
- Format of the phLibNfc_sTransceiveInfo_t content in this case is :
- • cmd: field shall set to phHal_eMifareAuthentA .
- • addr : indicates MIFARE block address.
+ Format of the phLibNfc_sTransceiveInfo_t content in this case is :
+ • cmd: field shall set to phHal_eMifareAuthentA .
+ • addr : indicates MIFARE block address.
Ex: 0x08 indicates block 8 needs to be authenticated.
- • sSendData : Shall contain authentication key values.
- sSendData ,buffer shall contain authentication
- key values 01 02 03 04 05 06 authenticates
- block 08 with the key 0x01[..]06. If this
- command fails, then user needs to reactivate
- the remote Mifare card.
+ • sSendData : Shall contain authentication key values.
+ sSendData ,buffer shall contain authentication
+ key values 01 02 03 04 05 06 authenticates
+ block 08 with the key 0x01[..]06. If this
+ command fails, then user needs to reactivate
+ the remote Mifare card.
*/
phNfc_eMifareAuthentB = 0x61U, /**< Mifare Standard:\n
This command performs an authentication with KEY B for a sector.\n
- Format of the phLibNfc_sTransceiveInfo_t content in this case is :
- • cmd: field shall set to phHal_eMifareAuthentB .
- • addr : indicates MIFARE block address.
+ Format of the phLibNfc_sTransceiveInfo_t content in this case is :
+ • cmd: field shall set to phHal_eMifareAuthentB .
+ • addr : indicates MIFARE block address.
Ex: 0x08 indicates block 8 needs to be authenticated.
- • sSendData : Shall contain authentication key values.
- sSendData ,buffer shall contain authentication
- key values 01 02 03 04 05 06 authenticates
- block 08 with the key 0x01[..]06. If this
- command fails, then user needs to reactivate
- the remote Mifare card.
+ • sSendData : Shall contain authentication key values.
+ sSendData ,buffer shall contain authentication
+ key values 01 02 03 04 05 06 authenticates
+ block 08 with the key 0x01[..]06. If this
+ command fails, then user needs to reactivate
+ the remote Mifare card.
*/
phNfc_eMifareRead16 = 0x30U, /**< Mifare Standard and Ultra Light:\n
Read 16 Bytes from a Mifare Standard block or 4 Mifare Ultra Light pages.\n
- Format of the phLibNfc_sTransceiveInfo_t content in this case is :
- • cmd: field shall set to phHal_eMifareRead16 .
- • addr : memory adress to read.
- • sRecvData : Shall contain buffer of size 16
- to read the data into.
+ Format of the phLibNfc_sTransceiveInfo_t content in this case is :
+ • cmd: field shall set to phHal_eMifareRead16 .
+ • addr : memory adress to read.
+ • sRecvData : Shall contain buffer of size 16
+ to read the data into.
- If this command fails, the user needs to reactivate the
+ If this command fails, the user needs to reactivate the
the remote Mifare card
*/
phNfc_eMifareRead = 0x30U,
phNfc_eMifareWrite16 = 0xA0U, /**< Mifare Standard and Ultra Light:\n
Write 16 Bytes to a Mifare Standard block or 4 Mifare Ultra Light pages.\n
- Format of the phLibNfc_sTransceiveInfo_t content in this case is :
- • cmd: field shall set to phHal_eMifareWrite16 .
- • addr : starting memory adress to write from.
+ Format of the phLibNfc_sTransceiveInfo_t content in this case is :
+ • cmd: field shall set to phHal_eMifareWrite16 .
+ • addr : starting memory adress to write from.
• sSendData : Shall contain buffer of size 16 containing
- the data bytes to be written.
-
- If this command fails, the user needs to reactivate the
+ the data bytes to be written.
+
+ If this command fails, the user needs to reactivate the
the remote Mifare card
*/
phNfc_eMifareWrite4 = 0xA2U, /**< Mifare Ultra Light:\n
Write 4 bytes.\n
- Format of the phLibNfc_sTransceiveInfo_t content in this case is :
- • cmd: field shall set to phHal_eMifareWrite4 .
- • addr : starting memory adress to write from.
+ Format of the phLibNfc_sTransceiveInfo_t content in this case is :
+ • cmd: field shall set to phHal_eMifareWrite4 .
+ • addr : starting memory adress to write from.
• sSendData : Shall contain buffer of size 4 containing
- the data bytes to be written.
+ the data bytes to be written.
- If this command fails, the user needs to reactivate the
+ If this command fails, the user needs to reactivate the
the remote Mifare card
*/
phNfc_eMifareInc = 0xC1U, /**< Increment. */
@@ -456,7 +456,7 @@ typedef enum phNfc_eMifareCmdList_t
typedef enum phNfc_eIso14443_4_CmdList_t
{
phNfc_eIso14443_4_Raw = 0x00U /**< ISO 14443-4 Exchange command:\n
- - This command sends the data buffer directly
+ - This command sends the data buffer directly
to the remote device */
} phNfc_eIso14443_4_CmdList_t;
@@ -472,7 +472,7 @@ typedef enum phNfc_eIso14443_4_CmdList_t
typedef enum phNfc_eNfcIP1CmdList_t
{
phNfc_eNfcIP1_Raw = 0x00U /**< NfcIP Exchange command:\n
- - This command sends the data buffer directly
+ - This command sends the data buffer directly
to the remote device */
}phNfc_eNfcIP1CmdList_t;
@@ -488,11 +488,11 @@ typedef enum phNfc_eIso15693_CmdList_t
{
#if 0
phNfc_eIso15693_Raw = 0x00U, /**< ISO 15693 Exchange Raw command:\n
- - This command sends the data buffer directly
+ - This command sends the data buffer directly
to the remote device */
#endif
phNfc_eIso15693_Cmd = 0x20U, /**< ISO 15693 Exchange command:\n
- - This command is used to access the card
+ - This command is used to access the card
to the remote device */
phNfc_eIso15693_Invalid = 0xFFU /**< Invalid Command */
} phNfc_eIso15693_CmdList_t;
@@ -508,7 +508,7 @@ typedef enum phNfc_eIso15693_CmdList_t
typedef enum phNfc_eFelicaCmdList_t
{
phNfc_eFelica_Raw = 0xF0U, /**< Felica Raw command:\n
- - This command sends the data buffer directly
+ - This command sends the data buffer directly
to the remote device */
phNfc_eFelica_Check = 0x00, /**< Felica Check command:\n
- This command checks the data from the Felica
@@ -530,7 +530,7 @@ typedef enum phNfc_eFelicaCmdList_t
typedef enum phNfc_eJewelCmdList_t
{
phNfc_eJewel_Raw = 0x00U, /**< Jewel command:\n
- - This command sends the data buffer directly
+ - This command sends the data buffer directly
to the remote device */
phNfc_eJewel_Invalid = 0xFFU /**< Invalid jewel command */
}phNfc_eJewelCmdList_t;
@@ -538,10 +538,10 @@ typedef enum phNfc_eJewelCmdList_t
/** \ingroup grp_hal_nfci
*
-* \brief Remote Device Reader A RF Gate Information Container
+* \brief Remote Device Reader A RF Gate Information Container
*
* The <em> Reader A structure </em> includes the available information
-* related to the discovered ISO14443A remote device. This information
+* related to the discovered ISO14443A remote device. This information
* is updated for every device discovery.
* \note None.
*
@@ -550,11 +550,11 @@ typedef struct phNfc_sIso14443AInfo_t
{
uint8_t Uid[PHHAL_MAX_UID_LENGTH]; /**< UID information of the TYPE A
Tag Discovered */
- uint8_t UidLength; /**< UID information length, shall not be greater
+ uint8_t UidLength; /**< UID information length, shall not be greater
than PHHAL_MAX_UID_LENGTH i.e., 10 */
- uint8_t AppData[PHHAL_MAX_ATR_LENGTH]; /**< Application data information of the
- tag discovered (= Historical bytes for
- type A) */
+ uint8_t AppData[PHHAL_MAX_ATR_LENGTH]; /**< Application data information of the
+ tag discovered (= Historical bytes for
+ type A) */
uint8_t AppDataLength; /**< Application data length */
uint8_t Sak; /**< SAK informationof the TYPE A
Tag Discovered */
@@ -562,23 +562,23 @@ typedef struct phNfc_sIso14443AInfo_t
Tag Discovered */
uint8_t MaxDataRate; /**< Maximum data rate supported by the TYPE A
Tag Discovered */
- uint8_t Fwi_Sfgt; /**< Frame waiting time and start up frame guard
- time as defined in ISO/IEC 14443-4[7] for
+ uint8_t Fwi_Sfgt; /**< Frame waiting time and start up frame guard
+ time as defined in ISO/IEC 14443-4[7] for
type A */
} phNfc_sIso14443AInfo_t;
/** \ingroup grp_hal_nfci
*
-* \brief Remote Device Reader B RF Gate Information Container
+* \brief Remote Device Reader B RF Gate Information Container
*
* The <em> Reader B structure </em> includes the available information
-* related to the discovered ISO14443B remote device. This information
+* related to the discovered ISO14443B remote device. This information
* is updated for every device discovery.
* \note None.
*
*/
-typedef struct phNfc_sIso14443BInfo_t
+typedef struct phNfc_sIso14443BInfo_t
{
union phNfc_uAtqBInfo
{
@@ -594,8 +594,8 @@ typedef struct phNfc_sIso14443BInfo_t
uint8_t AtqRes[PHHAL_ATQB_LENGTH]; /**< ATQB Response Information of TYPE B
Tag Discovered */
} AtqB;
- uint8_t HiLayerResp[PHHAL_MAX_ATR_LENGTH]; /**< Higher Layer Response information
- in answer to ATRRIB Command for Type B */
+ uint8_t HiLayerResp[PHHAL_MAX_ATR_LENGTH]; /**< Higher Layer Response information
+ in answer to ATRRIB Command for Type B */
uint8_t HiLayerRespLength; /**< Higher Layer Response length */
uint8_t Afi; /**< Application Family Identifier of TYPE B
Tag Discovered */
@@ -603,13 +603,29 @@ typedef struct phNfc_sIso14443BInfo_t
Tag Discovered */
} phNfc_sIso14443BInfo_t;
+/** \ingroup grp_hal_nfci
+*
+* \brief Remote Device 14443-4 Card RF Gate Information Container
+*
+* The <em> Card 14443-4 structure </em> includes the available information
+* related to the discovered ISO14443-4 PCD remote device. This information
+* is updated for every device discovery.
+* \note None.
+*
+*/
+typedef struct phNfc_sIso14443_4_PCD_Info_t
+{
+ uint8_t *buffer; /**< Data submitted to the emulated card*/
+ uint16_t length; /**< Data length*/
+} phNfc_sIso14443_4_PCD_Info_t;
+
/** \ingroup grp_hal_nfci
*
-* \brief Remote Device Reader B prime RF Gate Information Container
+* \brief Remote Device Reader B prime RF Gate Information Container
*
*/
-typedef struct phNfc_sIso14443BPrimeInfo_t
+typedef struct phNfc_sIso14443BPrimeInfo_t
{
/* TODO: This will be updated later */
void *BPrimeCtxt;
@@ -618,19 +634,19 @@ typedef struct phNfc_sIso14443BPrimeInfo_t
/** \ingroup grp_hal_nfci
*
-* \brief Remote Device Jewel Reader RF Gate Information Container
+* \brief Remote Device Jewel Reader RF Gate Information Container
*
* The <em> Jewel Reader structure </em> includes the available information
-* related to the discovered Jewel remote device. This information
+* related to the discovered Jewel remote device. This information
* is updated for every device discovery.
* \note None.
*
*/
-typedef struct phNfc_sJewelInfo_t
+typedef struct phNfc_sJewelInfo_t
{
uint8_t Uid[PHHAL_MAX_UID_LENGTH]; /**< UID information of the TYPE A
Tag Discovered */
- uint8_t UidLength; /**< UID information length, shall not be greater
+ uint8_t UidLength; /**< UID information length, shall not be greater
than PHHAL_MAX_UID_LENGTH i.e., 10 */
uint8_t HeaderRom0; /**< Header Rom byte zero */
uint8_t HeaderRom1; /**< Header Rom byte one */
@@ -640,10 +656,10 @@ typedef struct phNfc_sJewelInfo_t
/** \ingroup grp_hal_nfci
*
-* \brief Remote Device Felica Reader RF Gate Information Container
+* \brief Remote Device Felica Reader RF Gate Information Container
*
* The <em> Felica Reader structure </em> includes the available information
-* related to the discovered Felica remote device. This information
+* related to the discovered Felica remote device. This information
* is updated for every device discovery.
* \note None.
*
@@ -651,7 +667,7 @@ typedef struct phNfc_sJewelInfo_t
typedef struct phNfc_sFelicaInfo_t
{
uint8_t IDm[(PHHAL_FEL_ID_LEN + 2)]; /**< Current ID of Felica tag */
- uint8_t IDmLength; /**< IDm length, shall not be greater
+ uint8_t IDmLength; /**< IDm length, shall not be greater
than PHHAL_FEL_ID_LEN i.e., 8 */
uint8_t PMm[PHHAL_FEL_PM_LEN]; /**< Current PM of Felica tag */
uint8_t SystemCode[PHHAL_FEL_SYS_CODE_LEN]; /**< System code of Felica tag */
@@ -660,10 +676,10 @@ typedef struct phNfc_sFelicaInfo_t
/** \ingroup grp_hal_nfci
*
-* \brief Remote Device Reader 15693 RF Gate Information Container
+* \brief Remote Device Reader 15693 RF Gate Information Container
*
* The <em> Reader A structure </em> includes the available information
-* related to the discovered ISO15693 remote device. This information
+* related to the discovered ISO15693 remote device. This information
* is updated for every device discovery.
* \note None.
*
@@ -673,7 +689,7 @@ typedef struct phNfc_sIso15693Info_t
{
uint8_t Uid[PHHAL_15693_UID_LENGTH]; /**< UID information of the 15693
Tag Discovered */
- uint8_t UidLength; /**< UID information length, shall not be greater
+ uint8_t UidLength; /**< UID information length, shall not be greater
than PHHAL_15693_UID_LENGTH i.e., 8 */
uint8_t Dsfid; /**< DSF information of the 15693
Tag Discovered */
@@ -688,7 +704,7 @@ typedef struct phNfc_sIso15693Info_t
*
* \brief NFC Data Rate Supported between the Reader and the Target
*
-* The <em> \ref phHalNfc_eDataRate enum </em> lists all the Data Rate
+* The <em> \ref phHalNfc_eDataRate enum </em> lists all the Data Rate
* values to be used to determine the rate at which the data is transmitted
* to the target.
*
@@ -698,41 +714,41 @@ typedef struct phNfc_sIso15693Info_t
/** \ingroup grp_hal_nfci
*
-* \brief NFCIP1 Data rates
+* \brief NFCIP1 Data rates
*
*/
typedef enum phNfc_eDataRate_t{
- phNfc_eDataRate_106 = 0x00U,
- phNfc_eDataRate_212,
- phNfc_eDataRate_424,
- /* phNfc_eDataRate_848,
- phNfc_eDataRate_1696,
- phNfc_eDataRate_3392,
+ phNfc_eDataRate_106 = 0x00U,
+ phNfc_eDataRate_212,
+ phNfc_eDataRate_424,
+ /* phNfc_eDataRate_848,
+ phNfc_eDataRate_1696,
+ phNfc_eDataRate_3392,
phNfc_eDataRate_6784,*/
- phNfc_eDataRate_RFU
+ phNfc_eDataRate_RFU
} phNfc_eDataRate_t;
/** \ingroup grp_hal_nfci
*
-* \brief NFCIP1 Gate Information Container
+* \brief NFCIP1 Gate Information Container
*
* The <em> NFCIP1 structure </em> includes the available information
-* related to the discovered NFCIP1 remote device. This information
+* related to the discovered NFCIP1 remote device. This information
* is updated for every device discovery.
* \note None.
*
*/
-typedef struct phNfc_sNfcIPInfo_t
+typedef struct phNfc_sNfcIPInfo_t
{
- /* Contains the random NFCID3I conveyed with the ATR_REQ.
- always 10 bytes length
+ /* Contains the random NFCID3I conveyed with the ATR_REQ.
+ always 10 bytes length
or contains the random NFCID3T conveyed with the ATR_RES.
always 10 bytes length */
- uint8_t NFCID[PHHAL_MAX_UID_LENGTH];
+ uint8_t NFCID[PHHAL_MAX_UID_LENGTH];
uint8_t NFCID_Length;
/* ATR_RES = General bytes length, Max length = 48 bytes */
- uint8_t ATRInfo[PHHAL_MAX_ATR_LENGTH];
+ uint8_t ATRInfo[PHHAL_MAX_ATR_LENGTH];
uint8_t ATRInfo_Length;
/**< SAK information of the tag discovered */
uint8_t SelRes;
@@ -740,7 +756,7 @@ typedef struct phNfc_sNfcIPInfo_t
uint8_t SenseRes[PHHAL_ATQA_LENGTH];
/**< Is Detection Mode of the NFCIP Target Active */
uint8_t Nfcip_Active;
- /**< Maximum frame length supported by the NFCIP device */
+ /**< Maximum frame length supported by the NFCIP device */
uint16_t MaxFrameLength;
/**< Data rate supported by the NFCIP device */
phNfc_eDataRate_t Nfcip_Datarate;
@@ -767,6 +783,7 @@ typedef union phNfc_uRemoteDevInfo_t
phNfc_sFelicaInfo_t Felica_Info;
phNfc_sJewelInfo_t Jewel_Info;
phNfc_sIso15693Info_t Iso15693_Info;
+ phNfc_sIso14443_4_PCD_Info_t Iso14443_4_PCD_Info;
} phNfc_uRemoteDevInfo_t;
@@ -776,7 +793,7 @@ typedef union phNfc_uRemoteDevInfo_t
*
* The <em> RF Device Type List </em> is used to identify the type of
* remote device that is discovered/connected. There seperate
-* types to identify a Remote Reader (denoted by _PCD) and
+* types to identify a Remote Reader (denoted by _PCD) and
* Remote Tag (denoted by _PICC)
* \note None.
*
@@ -810,8 +827,8 @@ typedef enum phNfc_eRFDevType_t
phNfc_eISO15693_PICC,
/* NFC-IP1 Device Types */
- phNfc_eNfcIP1_Target,
- phNfc_eNfcIP1_Initiator,
+ phNfc_eNfcIP1_Target,
+ phNfc_eNfcIP1_Initiator,
/* Other Sources */
phNfc_eInvalid_DevType
@@ -860,18 +877,18 @@ typedef union phNfc_uCommand_t
* Device detected by the polling function .\n
* It lists parameters common to all supported remote devices.
*
- * \note
+ * \note
*
* \sa \ref phHal4Nfc_ConfigureDiscovery and \ref phHal4Nfc_Connect
*
*/
typedef struct phNfc_sRemoteDevInformation_t
{
- uint8_t SessionOpened; /**< [out] Boolean
+ uint8_t SessionOpened; /**< [out] Boolean
* Flag indicating the validity of
* the handle of the remote device. */
- phNfc_eRemDevType_t RemDevType; /**< [out] Remote device type which says that remote
- is Reader A or Reader B or NFCIP or Felica or
+ phNfc_eRemDevType_t RemDevType; /**< [out] Remote device type which says that remote
+ is Reader A or Reader B or NFCIP or Felica or
Reader B Prime or Jewel*/
phNfc_uRemoteDevInfo_t RemoteDevInfo; /**< Union of available Remote Device.
* \ref phNfc_uRemoteDevInfo_t Information. */
@@ -884,10 +901,10 @@ typedef struct phNfc_sRemoteDevInformation_t
/** \ingroup grp_hal_common
*
- * \brief Transceive Information Data Structure for sending commands/response
+ * \brief Transceive Information Data Structure for sending commands/response
* to the remote device
*
- * The <em> Transceive Information Data Structure </em> is used to pass the
+ * The <em> Transceive Information Data Structure </em> is used to pass the
* Command, Address (only required for MIFARE) and the send and receive data
* data structure (buffer and length) for communication with remote device
*
@@ -913,8 +930,8 @@ typedef struct phNfc_sTransceiveInfo_t
* \brief Poll Device Information for conifiguring the discovery wheel
Reader and Card Emulation Phases
*
-* The <em> \ref phNfc_sPollDevInfo_t enum </em> is used to enable/disable
-* phases of the discovery wheel related to specific reader types and
+* The <em> \ref phNfc_sPollDevInfo_t enum </em> is used to enable/disable
+* phases of the discovery wheel related to specific reader types and
* card emulation phase
* \note Enabling specific Reader technology when NFCIP1 speed is set in the
* phNfc_sADD_Cfg_t is implicitly done in HAL. Use this structure to only
@@ -922,23 +939,23 @@ typedef struct phNfc_sTransceiveInfo_t
*/
typedef struct phNfc_sPollDevInfo_t
{
- unsigned EnableIso14443A : 1; /**< Flag to enable
+ unsigned EnableIso14443A : 1; /**< Flag to enable
Reader A discovery */
- unsigned EnableIso14443B : 1; /**< Flag to enable
+ unsigned EnableIso14443B : 1; /**< Flag to enable
Reader B discovery */
unsigned EnableFelica212 : 1; /**< Flag to enable
Felica 212 discovery */
unsigned EnableFelica424 : 1; /**< Flag to enable
Felica 424 discovery */
- unsigned EnableIso15693 : 1; /**< Flag to enable
+ unsigned EnableIso15693 : 1; /**< Flag to enable
ISO 15693 discovery */
- unsigned EnableNfcActive : 1; /**< Flag to enable
- Active Mode of NFC-IP discovery.
- This is updated internally
+ unsigned EnableNfcActive : 1; /**< Flag to enable
+ Active Mode of NFC-IP discovery.
+ This is updated internally
based on the NFC-IP speed.
*/
unsigned RFU : 1; /**< Reserved for future use */
- unsigned DisableCardEmulation : 1; /**< Flag to
+ unsigned DisableCardEmulation : 1; /**< Flag to
disable the card emulation */
} phNfc_sPollDevInfo_t;
@@ -947,7 +964,7 @@ typedef struct phNfc_sPollDevInfo_t
*
* \brief P2P speed for the Initiator
*
-* The <em> \ref phNfc_eP2PMode_t enum </em> lists all the NFCIP1 speeds
+* The <em> \ref phNfc_eP2PMode_t enum </em> lists all the NFCIP1 speeds
* to be used for configuring the NFCIP1 discovery
*
* \note None.
@@ -986,7 +1003,7 @@ typedef enum phNfc_eNotificationType_t
/** \ingroup grp_hal_common
*
-* \brief
+* \brief
*
* \note None.
*/
@@ -1010,11 +1027,11 @@ typedef struct phNfc_sUiccInfo_t
*
* \note None.
*/
-typedef struct phNfc_sNfcIPCfg_t
+typedef struct phNfc_sNfcIPCfg_t
{
/* ATR_RES = General bytes length, Max length = 48 bytes */
uint8_t generalBytesLength;
- uint8_t generalBytes[PHHAL_MAX_ATR_LENGTH];
+ uint8_t generalBytes[PHHAL_MAX_ATR_LENGTH];
/* TODO: This will be updated later for any additional params*/
} phNfc_sNfcIPCfg_t;
@@ -1025,19 +1042,19 @@ typedef struct phNfc_sNfcIPCfg_t
* \brief Discovery Configuration Mode
*
* This enumeration is used to choose the Discovery Configuration
-* Mode :- Configure and Start, Stop or Start with last set
+* Mode :- Configure and Start, Stop or Start with last set
* configuration
* \note None.
*/
typedef enum phNfc_eDiscoveryConfigMode_t
{
- NFC_DISCOVERY_CONFIG = 0x00U,/**< Configure discovery with values
- in phNfc_sADD_Cfg_t and start
+ NFC_DISCOVERY_CONFIG = 0x00U,/**< Configure discovery with values
+ in phNfc_sADD_Cfg_t and start
discovery */
NFC_DISCOVERY_START, /**< Start Discovery with previously set
configuration */
NFC_DISCOVERY_STOP, /**< Stop the Discovery */
- NFC_DISCOVERY_RESUME /**< Resume the Discovery with previously
+ NFC_DISCOVERY_RESUME /**< Resume the Discovery with previously
* set configuration.
* This is valid only when the Target
* is not connected.
@@ -1048,14 +1065,14 @@ typedef enum phNfc_eDiscoveryConfigMode_t
*
* \brief Target or Tag Release Mode
*
-* This enumeration defines various modes of releasing an acquired target
+* This enumeration defines various modes of releasing an acquired target
* or tag.
* \note None.
*/
typedef enum phNfc_eReleaseType_t
{
NFC_INVALID_RELEASE_TYPE =0x00U,/**<Invalid release type */
- NFC_DISCOVERY_RESTART, /**< Release current target and
+ NFC_DISCOVERY_RESTART, /**< Release current target and
restart discovery within same technology*/
NFC_DISCOVERY_CONTINUE, /**< Release current target and continue
discovery with next technology in the wheel */
@@ -1067,8 +1084,8 @@ typedef enum phNfc_eReleaseType_t
*
* \brief Poll configuration structure
*
-* The <em> Poll configuration structure </em> holds information about the
-* enabling the the type of discovery required by the application. This
+* The <em> Poll configuration structure </em> holds information about the
+* enabling the the type of discovery required by the application. This
* structure is the input parameter for the discovery call
*
* \note All members of this structure are input parameters [out].
@@ -1078,28 +1095,28 @@ typedef enum phNfc_eReleaseType_t
*/
typedef struct phNfc_sADD_Cfg_t
{
- union
+ union
{
- phNfc_sPollDevInfo_t PollCfgInfo; /**< Enable/Disable Specific
- Reader Functionality and
- Card Emulation */
+ phNfc_sPollDevInfo_t PollCfgInfo; /**< Enable/Disable Specific
+ Reader Functionality and
+ Card Emulation */
unsigned PollEnabled; /** Can be used to set polling 'Off'
by setting PollEnabled to zero */
} PollDevInfo;
- uint32_t Duration; /**< Duration of virtual or idle
+ uint32_t Duration; /**< Duration of virtual or idle
period in microseconds in the step size
of 48 microseconds.If duration is set less
than 48 microseconds then default value is
- used.For more details please refer PN 544
+ used.For more details please refer PN 544
user manual*/
uint8_t NfcIP_Mode ; /**< Select the P2P
speeds using phNfc_eP2PMode_t type.
- This is used to enable NFC-IP Discovery
+ This is used to enable NFC-IP Discovery
The related Reader Type will be implicitly
selected */
uint8_t NfcIP_Target_Mode ;
- uint8_t NfcIP_Tgt_Disable; /**< Flag to
+ uint8_t NfcIP_Tgt_Disable; /**< Flag to
disable the NFCIP1 TARGET */
} phNfc_sADD_Cfg_t;