NXP Reader Library  v17.1.0.2535
ICODE EPC, ICODE UID

These Components implement the ICode EPC and ICode UID products. More...

Collaboration diagram for ICODE EPC, ICODE UID:

Modules

 Component : Software
 

Macros

#define PHPAL_EPCUID_LABEL_EPC   0x00U
 EPC label identifier.
 
#define PHPAL_EPCUID_LABEL_UID   0x01U
 UID label identifier.
 
#define PHPAL_EPCUID_EPC_MAXBLOCKNUMBER   16U
 Last EPC block number.
 
#define PHPAL_EPCUID_UID_MAXBLOCKNUMBER   23U
 Last UID block number.
 
#define PHPAL_EPCUID_EPC_LENGTH   12U
 EPC length in bytes without CRC.
 
#define PHPAL_EPCUID_IDD_LENGTH   19U
 IDD length in bytes without UID-CRC.
 
#define PHPAL_EPCUID_DESTROYCODE_LENGTH   3U
 Length of the destroy code.
 
#define PHPAL_EPCUID_CLOSESLOT_NONLAST   0x00
 Send a non last close slot and wait for tag replies afterwards.
 
#define PHPAL_EPCUID_CLOSESLOT_LAST   0x01
 Send the last close slot of a reply round, no data is received afterwards.
 
#define PHPAL_EPCUID_NUMSLOTS_1   0x00
 Value for bNumSlots = 1.
 
#define PHPAL_EPCUID_NUMSLOTS_4   0x01
 Value for bNumSlots = 4.
 
#define PHPAL_EPCUID_NUMSLOTS_8   0x03
 Value for bNumSlots = 8.
 
#define PHPAL_EPCUID_NUMSLOTS_16   0x07
 Value for bNumSlots = 16.
 
#define PHPAL_EPCUID_NUMSLOTS_32   0x0F
 Value for bNumSlots = 32.
 
#define PHPAL_EPCUID_NUMSLOTS_64   0x1F
 Value for bNumSlots = 64.
 
#define PHPAL_EPCUID_NUMSLOTS_128   0x3F
 Value for bNumSlots = 128.
 
#define PHPAL_EPCUID_NUMSLOTS_256   0x7F
 Value for bNumSlots = 256.
 
#define PHPAL_EPCUID_NUMSLOTS_512   0xFF
 Value for bNumSlots = 512.
 

Functions

phStatus_t phpalEpcUid_ActivateCard (void *pDataParams, uint8_t bTagType, uint8_t bNumSlots, uint8_t *pMask, uint8_t bMaskBitLength, uint8_t bHash, uint8_t *pRxBuffer, uint8_t *pRxLength, uint8_t *pMoreCardsAvailable)
 Perform BeginRound command and bring first label to FIXED SLOT state. More...
 
phStatus_t phpalEpcUid_BeginRound (void *pDataParams, uint8_t bTagType, uint8_t bNumSlots, uint8_t *pMask, uint8_t bMaskBitLength, uint8_t bHash, uint8_t *pRxBuffer, uint8_t *pRxLength)
 Perform BeginRound command. More...
 
phStatus_t phpalEpcUid_CloseSlot (void *pDataParams, uint8_t bOption, uint8_t *pRxBuffer, uint8_t *pRxLength)
 Perform CloseSlot command. More...
 
phStatus_t phpalEpcUid_FixSlot (void *pDataParams, uint8_t bTagType, uint8_t *pMask, uint8_t bMaskBitLength)
 Perform FixSlot command. More...
 
phStatus_t phpalEpcUid_Write (void *pDataParams, uint8_t bTagType, uint8_t bBlockNo, uint8_t bData)
 Write a block. More...
 
phStatus_t phpalEpcUid_Destroy (void *pDataParams, uint8_t bTagType, uint8_t *pData, uint8_t bDataLength, uint8_t *pDestroyCode)
 Destroy Label. More...
 
phStatus_t phpalEpcUid_GetSerialNo (void *pDataParams, uint8_t *pUidOut, uint8_t *pLenUidOut)
 Get the tag data. More...
 

Detailed Description

These Components implement the ICode EPC and ICode UID products.

Function Documentation

◆ phpalEpcUid_ActivateCard()

phStatus_t phpalEpcUid_ActivateCard ( void *  pDataParams,
uint8_t  bTagType,
uint8_t  bNumSlots,
uint8_t pMask,
uint8_t  bMaskBitLength,
uint8_t  bHash,
uint8_t pRxBuffer,
uint8_t pRxLength,
uint8_t pMoreCardsAvailable 
)

Perform BeginRound command and bring first label to FIXED SLOT state.

This command performs a phpalEpcUid_BeginRound command and iterates through the given number of slots using the phpalEpcUid_CloseSlot command until it receives the first correct response.

Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]bTagType[In] Tag type; Either PHPAL_EPCUID_LABEL_EPC or PHPAL_EPCUID_LABEL_UID.
[in]bNumSlots[In] Number of slots.
[in]pMask[In] Fractional or complete EPC/IDD for selecting certain labels.
[in]bMaskBitLength[In] Length of the mask in bits.
[in]bHash[In] Used by EPC labels to generate random slot position.
[out]pRxBuffer[Out] Data returned by the tag which was detected first.
[out]pRxLength[Out] Received data length.
[out]pMoreCardsAvailable[Out] Indicates if more than one tag was detected

◆ phpalEpcUid_BeginRound()

phStatus_t phpalEpcUid_BeginRound ( void *  pDataParams,
uint8_t  bTagType,
uint8_t  bNumSlots,
uint8_t pMask,
uint8_t  bMaskBitLength,
uint8_t  bHash,
uint8_t pRxBuffer,
uint8_t pRxLength 
)

Perform BeginRound command.

This command sends a BeginRound command to all labels and stores the response of each label into a seperate pLabelInfo Array. Since the round starts with SlotF and not Slot0, the caller has to ensure that the number of entries within pLabelInfo is 1+bNumSlots. For each slot, a "Close Slot" Sequence is performed.

Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]bTagType[In] Tag type; Either PHPAL_EPCUID_LABEL_EPC or PHPAL_EPCUID_LABEL_UID.
[in]bNumSlots[In] Number of slots.
[in]pMask[In] Fractional or complete EPC/IDD for selecting certain labels.
[in]bMaskBitLength[In] Length of the mask in bits.
[in]bHash[In] Used by EPC labels to generate random slot position.
[out]pRxBuffer[Out] Data returned by the tag which was detected first.
[out]pRxLength[Out] Received data length.

◆ phpalEpcUid_CloseSlot()

phStatus_t phpalEpcUid_CloseSlot ( void *  pDataParams,
uint8_t  bOption,
uint8_t pRxBuffer,
uint8_t pRxLength 
)

Perform CloseSlot command.

This command closes the actual slot and returnes the answer of all labels replying in the next slot. If bOption is set to PHPAL_EPCUID_CLOSESLOT_LAST the reply round is closed and no more data is received.

Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]bOption[In] Option; Either PHPAL_EPCUID_CLOSESLOT_NONLAST or PHPAL_EPCUID_CLOSESLOT_LAST.
[out]pRxBuffer[Out] Data returned by the tag which answers during the next slot.
[out]pRxLength[Out] Received data length.

◆ phpalEpcUid_FixSlot()

phStatus_t phpalEpcUid_FixSlot ( void *  pDataParams,
uint8_t  bTagType,
uint8_t pMask,
uint8_t  bMaskBitLength 
)

Perform FixSlot command.

This command sets a lables matching to the given mask into the FIXED state. A begin round with a single slot is started and the responding label is fixed by a following FixSlot command. Remark: This command is coupled with phpalEpcUid_BeginRound to ensure the exact timing 302,04us (using TxWait) between the two commands.

Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]bTagType[In] Tag type; Either PHPAL_EPCUID_LABEL_EPC or PHPAL_EPCUID_LABEL_UID.
[in]pMask[In] Complete EPC/IDD for target label.
[in]bMaskBitLength[In] Length of the mask in bits.

◆ phpalEpcUid_Write()

phStatus_t phpalEpcUid_Write ( void *  pDataParams,
uint8_t  bTagType,
uint8_t  bBlockNo,
uint8_t  bData 
)

Write a block.

There is no response from the label after sending this command. In order to verify the written data, a phpalEpcUid_BeginRound command should be performed.

Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]bTagType[In] Tag type; Either PHPAL_EPCUID_LABEL_EPC or PHPAL_EPCUID_LABEL_UID.
[in]bBlockNo[In] Destination block number.
[in]bData[In] Data to write

◆ phpalEpcUid_Destroy()

phStatus_t phpalEpcUid_Destroy ( void *  pDataParams,
uint8_t  bTagType,
uint8_t pData,
uint8_t  bDataLength,
uint8_t pDestroyCode 
)

Destroy Label.

There is no response from the label after sending this command. In order to verify that the label is destroyed, a phpalEpcUid_BeginRound command should be performed.

Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]bTagType[In] Tag type; Either PHPAL_EPCUID_LABEL_EPC or PHPAL_EPCUID_LABEL_UID.
[in]pData[In] Complete EPC/IDD data of the tag to be destroyed.
[in]bDataLength[In] Length of EPC/IDD data.
[in]pDestroyCode[In] 3 bytes destroy code.

◆ phpalEpcUid_GetSerialNo()

phStatus_t phpalEpcUid_GetSerialNo ( void *  pDataParams,
uint8_t pUidOut,
uint8_t pLenUidOut 
)

Get the tag data.

The command returnes the tag response to the last phpalEpcUid_ActivateCard.

Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[out]pUidOut[Out] Tag response to the last Activate Card.
[out]pLenUidOut[Out] Tag response length.