BALTECH Docs |
C API for BALTECH SDK
|
brp_errcode brp_I4CE_ExchangeInverseAPDU | ( | brp_protocol | protocol, |
brp_buf | Rsp, | ||
size_t | Rsp_len, | ||
unsigned | Timeout, | ||
brp_buf * | Cmd, | ||
size_t * | Cmd_len, | ||
brp_mempool * | mempool | ||
) |
**This command is marked as deprecated as it is not supported by Baltech's SDK.
There is currently no alternative for this command.**
Send an APDU response to the APDU request received during the last call of I4CE.ExchangeInverseAPDU or brp_I4CE_StartEmu(), and receive the next PCD APDU request.
The Timeout parameter specifies the maximum time in ms to wait for the next APDU. If no request could be received from the PCD, I4CE.ExchangeInverseAPDU returns the BRP_I4CE_ErrTimeout status code.
In case the received APDU does not fit into the internal buffer of the emulated PICC, the part of the frame which could be processed is returned together with an BRP_I4CE_ErrOverflow status code. The buffer size is firmware dependent and can be retrieved via the brp_Sys_GetBufferSize() command.
The command returns the BRP_I4CE_ErrIso144State status code if the PICC is not in the proper state to exchange ISO14443-4 APDUs. This is the case if brp_I4CE_StartEmu() has not previously been successfully executed, or if the PCD has terminated the communication by e.g. executing the brp_Iso14L4_Deselect() command.
[in] | protocol | used to execute the command |
[in] | Rsp | APDU which shall be sent to the PCD as a response to the last command. |
[in] | Rsp_len | |
[in] | Timeout | Maximum time (in ms) to wait for the next ISO14443-4 APDU request. A value of 0xFFFF corresponds to an infinite timeout. |
[out] | Cmd | Next ISO14443-4 APDU request received from the PCD. |
[out] | Cmd_len | |
[in] | mempool | is used to store response data. Maybe NULL to use an internal mempool, in this case the data is only available until another command uses the internal mempool |