NXP Reader Library  v17.1.0.2535

Implementation of SAM commands used for MIFARE Ultralight communication in S-Mode. More...

Collaboration diagram for S_Mode:

Modules

 Defines
 Definitions for SAM commands used for MIFARE Plus communication in S-Mode.
 

Functions

phStatus_t phhalHw_Sam_Cmd_SAM_PwdAuthUL_Part1 (phhalHw_Sam_DataParams_t *pDataParams, uint8_t bKeyNo, uint8_t bKeyVer, uint8_t *pDivInput, uint8_t bDivInputLen, uint8_t **ppPwd, uint16_t *pPwdLen)
 Performs PwdAuthUL command execution part 1 in S mode. More...
 
phStatus_t phhalHw_Sam_Cmd_SAM_PwdAuthUL_Part2 (phhalHw_Sam_DataParams_t *pDataParams, uint16_t wPack)
 Performs PwdAuthUL command execution part 2 in S mode. More...
 

Detailed Description

Implementation of SAM commands used for MIFARE Ultralight communication in S-Mode.

Function Documentation

◆ phhalHw_Sam_Cmd_SAM_PwdAuthUL_Part1()

phStatus_t phhalHw_Sam_Cmd_SAM_PwdAuthUL_Part1 ( phhalHw_Sam_DataParams_t pDataParams,
uint8_t  bKeyNo,
uint8_t  bKeyVer,
uint8_t pDivInput,
uint8_t  bDivInputLen,
uint8_t **  ppPwd,
uint16_t pPwdLen 
)

Performs PwdAuthUL command execution part 1 in S mode.

The first part includes the header, Key number, Key Version, Diversification input and returns Message

Note
  • Post calling this interface it's must to call PwdAuthUL Part2 to place SAM into proper completion state if Chaining Status is returned from Library. Otherwise error will be returned by SAM for any subsequent commands.
  • If Chaining Status is not returned from Library, no need to call PwdAuthUL Part2 interface.
Return values
PH_ERR_SUCCESS_CHAININGOperation successful.
PH_ERR_INVALID_DATA_PARAMSpDataParams is NULL.
PH_ERR_INVALID_PARAMETERpDivInput and pPwdLen are NULL.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]bKeyNo[In] Key number to be used from SAM. One of the following,
  • NVM Key: 0x00 - 0x7F
  • RAM Key: 0xE0 - 0xE3
[in]bKeyVer[In] Key version to be used from SAM.
[in]pDivInput[In] Diversification input for key diversification. (1 to 31 byte(s) input).
[in]bDivInputLen[In] Length of bytes available in pDivInput buffer.
[out]ppPwd[Out] Password received from SAM (4 byte).
[out]pPwdLen[Out] Length of bytes available in ppPwd buffer.

◆ phhalHw_Sam_Cmd_SAM_PwdAuthUL_Part2()

phStatus_t phhalHw_Sam_Cmd_SAM_PwdAuthUL_Part2 ( phhalHw_Sam_DataParams_t pDataParams,
uint16_t  wPack 
)

Performs PwdAuthUL command execution part 2 in S mode.

The Last part includes the header and Password authentication acknowledge

Note
This interface should be called only if PwdAuthUL Part1 returns Chaining Status.
Return values
PH_ERR_SUCCESSOperation successful.
PH_ERR_INVALID_DATA_PARAMSpDataParams is NULL.
OtherDepending on implementation and underlaying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]wPack[In] Password Authentication Acknowledge.