NXP Reader Library  v17.1.0.2535
Commands_EVCharging

Describes about the MIFARE DUOX EV Charging commands. More...

Collaboration diagram for Commands_EVCharging:

Modules

 Defines
 

Functions

phStatus_t phalMfDuoX_VdeReadData (void *pDataParams, uint16_t wOption, uint8_t bFileNo, uint16_t wBytesToRead, uint8_t bExtendedLenApdu, uint8_t **ppResponse, uint16_t *pRspLen)
 Reads data from Standard data File. More...
 
phStatus_t phalMfDuoX_VdeWriteData (void *pDataParams, uint8_t bOperation, uint8_t bExtendedLenApdu, uint8_t *pData, uint16_t wDataLen)
 Writes data to Standard data File and eventually lock the file. More...
 
phStatus_t phalMfDuoX_VdeECDSASign (void *pDataParams, uint16_t wBytesToRead, uint8_t bExtendedLenApdu, uint8_t *pData, uint16_t wDataLen, uint8_t **ppResponse, uint16_t *pRspLen)
 Generates and ECDSA signature over a 32-byte challenge. More...
 

Detailed Description

Describes about the MIFARE DUOX EV Charging commands.

Function Documentation

◆ phalMfDuoX_VdeReadData()

phStatus_t phalMfDuoX_VdeReadData ( void *  pDataParams,
uint16_t  wOption,
uint8_t  bFileNo,
uint16_t  wBytesToRead,
uint8_t  bExtendedLenApdu,
uint8_t **  ppResponse,
uint16_t pRspLen 
)

Reads data from Standard data File.

Note
Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
PH_ERR_SUCCESS_CHAININGIndicating more data to be read.
PH_ERR_INVALID_DATA_PARAMSIf DataParams is null.
PH_ERR_INVALID_PARAMETER
  • If the buffers are null.
  • For Invalid Exchange option value (wOption).
XXXX
  • Depending on status codes return by PICC.
  • Other Depending on implementation and underlying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]wOption[In] One of the below options.
[in]bFileNo[In] The file number from where the data to be read.
[in]wBytesToRead[In] The number of bytes to be read from the file.
  • If zero, any amount of data stating from zero upto 256 / 65536 bytes. LE will be exchanged as zero based on bExtendedLenApdu value.
  • If non zero, any amount of data stating from zero upto wBytesToRead will be returned. LE will be exchanged as wBytesToRead based on bExtendedLenApdu value.
[in]bExtendedLenApdu[In] Flag for Extended Length APDU.
[out]ppResponse[Out] The data returned by the PICC.
[out]pRspLen[Out] Length of bytes available in ppResponse buffer.

◆ phalMfDuoX_VdeWriteData()

phStatus_t phalMfDuoX_VdeWriteData ( void *  pDataParams,
uint8_t  bOperation,
uint8_t  bExtendedLenApdu,
uint8_t pData,
uint16_t  wDataLen 
)

Writes data to Standard data File and eventually lock the file.

Note
For all ISO7816 errors, library returns a command error code ISO7816 General Errors. To know the exact error returned by PICC call Get Config with Additional Information as Configuration Identifier.
Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
PH_ERR_INVALID_DATA_PARAMSIf DataParams is null.
PH_ERR_INVALID_PARAMETERIf the buffer is null.
PHAL_MFDUOX_ERR_DF_7816_GEN_ERRORAny ISO7816 Error.
XXXX
  • Depending on status codes return by PICC.
  • Other Depending on implementation and underlying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]bOperation[In] The operation to perform on the file.
[in]bExtendedLenApdu[In] Flag for Extended Length APDU.
[in]pData[In] The data to be written to the PICC.
[in]wDataLen[In] Length of bytes available in pData buffer.

◆ phalMfDuoX_VdeECDSASign()

phStatus_t phalMfDuoX_VdeECDSASign ( void *  pDataParams,
uint16_t  wBytesToRead,
uint8_t  bExtendedLenApdu,
uint8_t pData,
uint16_t  wDataLen,
uint8_t **  ppResponse,
uint16_t pRspLen 
)

Generates and ECDSA signature over a 32-byte challenge.

Note
For all ISO7816 errors, library returns a command error code ISO7816 General Errors. To know the exact error returned by PICC call Get Config with Additional Information as Configuration Identifier.
Returns
Status code
Return values
PH_ERR_SUCCESSOperation successful.
PH_ERR_INVALID_DATA_PARAMSIf DataParams is null.
PH_ERR_INVALID_PARAMETERIf the buffer is null.
PHAL_MFDUOX_ERR_DF_7816_GEN_ERRORAny ISO7816 Error.
XXXX
  • Depending on status codes return by PICC.
  • Other Depending on implementation and underlying component.
Parameters
[in]pDataParams[In] Pointer to this layer's parameter structure.
[in]wBytesToRead[In] The number of bytes to be read from the file.
  • If zero, any amount of data stating from zero upto 256 / 65536 bytes. LE will be exchanged as zero based on bExtendedLenApdu value.
  • If non zero, any amount of data stating from zero upto wBytesToRead will be returned. LE will be exchanged as wBytesToRead based on bExtendedLenApdu value.
[in]bExtendedLenApdu[In] Flag for Extended Length APDU.
[in]pData[In] Message to be signed.
[in]wDataLen[In] Length of bytes available in pData buffer.
[out]ppResponse[Out] The signature of the message.
  • The Signature will be in R and S integer format. ppResponse = R data followed by S data.
  • Here R and S length will be based on the curve length.
  • Ex: If curve length is 256 bit, then R and S length will be 32 bytes each.
[out]pRspLen[Out] Length of bytes available in ppResponse buffer.