Renesas PTX1xxR IoT-Reader API Version 7.3.1
Renesas Software Stack for IoT-Reader Applications
Data Structures | Typedefs | Functions
Target Integration Layer (Common)
Collaboration diagram for Target Integration Layer (Common):

Data Structures

struct  ptxTbInt
 

Typedefs

typedef void(* pptxInt_Completion_t) (void *sysCtx, uint8_t *complData, size_t complDataLen, int32_t complStatus)
 Completion function pointer for general calls and responses to calls.
 
typedef void(* pptxInt_CompletionNTF_t) (void *sysCtx, ptxNSC_Event_t *complData)
 Completion function pointer for notifications.
 

Functions

ptxStatus_t ptxTbInt_GetIORQNtf (void *cpLayer, ptxIoRq_t *io_rq)
 Integration get IO RQ Ntf (Not including NCI).
 
void ptxTbInt_ReturnIoRqItem (ptxTbInt_t *cInst, ptxIoRq_t *ioCpl, ptxStatus_t reqStatus)
 Internal function to return I/O request objects in case of non-pending status.
 
void ptxTbInt_GetIORQNtfCompletion (ptxIoRq_t *ioCpl, void *cplLayer, void *data, size_t dataLength, ptxStatus_t cplStatus)
 Completion function for ptxTbInt_GetIORQNtf.
 
void ptxTbInt_NSCCompletion (ptxIoRq_t *ioCpl, void *cplLayer, void *data, size_t dataLength, ptxStatus_t cplStatus)
 Internal default completion function general purpose NSC.
 
typedef struct ptxTbInt ptxTbInt_t
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_SetUp (void *compCtx, pptxInt_Completion_t complFn, pptxInt_CompletionNTF_t complFnNtf, void *sysCtx)
 Set up the stack.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_ShutDown (void *compCtx)
 Shut down the stack.
 
PTX_LIBFUNC const char * ptxTbInt_GetVersionDescription (void)
 Get Version Description.
 
PTX_LIBFUNC ptxTbInt_tptxTbInt_Allocate (void)
 Allocate memory for ptxTbInt_t - the main struct for the stack that has to be sent from caller in all the calls.
 
PTX_LIBFUNC void ptxTbInt_Free (ptxTbInt_t *cInst)
 Free the memory previously allocated by ptxTbInt_t.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_SetParameter (ptxTbInt_t *cInst, ptxNscFactory_P_t parType, uint8_t *parBuf, uint32_t parLenOrValue)
 Set Factory Operating Parameter.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_BuildStack (ptxTbInt_t *cInst, void *systemContext)
 Build the stack.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_DestroyStack (ptxTbInt_t *cInst)
 Destroy the stack, except for basic objects such as LOG.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_DestroyStack_Finalize (ptxTbInt_t *cInst)
 Destroy the basic stack objects.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSCFwDownloader (void *compCtx, uint8_t *pData, int length)
 NSC download firmware image to the chip.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_DragonFlyActivation (void *compCtx)
 NSC DFY Activation entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_Init (void *compCtx, ptxNSC_Init_Param_t *initParams)
 NSC Init entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfConfig (void *compCtx, ptxNSC_RfConfig_Param_t *rfConfigParams)
 NSC Rf Config.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfSetParams (void *compCtx, ptxNsc_RfPar_t *rfPar, size_t rfParLen)
 NSC RF SET PARAMETER entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfTestRun (void *compCtx, ptxNsc_RfTest_Id_t rfTestId, uint8_t *rfTestParams, size_t rfTestParamsLen)
 Function for NSC_RF_RUN_CMD.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfTestStop (void *compCtx)
 Function for NSC_RF_STOP_CMD.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSCGetMode (void *compCtx, uint8_t *mode)
 NSC Get State.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSCGetMiscRFConfig (void *compCtx, uint8_t *configBuffer, size_t *configBufferLen)
 NSC Get last loaded Misc. RF-Configuration.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_Read (void *compCtx, uint16_t *address, size_t addressLen, ptxNSC_ReadCmd_Type_t typeRd)
 NSC Read entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_Write (void *compCtx, uint16_t *address, size_t addressLen, uint8_t *value, size_t valueLen, ptxNSC_WriteCmd_Type_t typeWr)
 NSC Write entry function at integration level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfDiscover (void *compCtx, ptxNSC_Discover_Param_t *discoverParams)
 NSC Discover entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfDiscover_EmvCo_TRANSAC_A (void *compCtx)
 NSC Rf Discover entry function at Int level, enabling the TRANSAC_A feature.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfDiscover_EmvCo_TRANSAC_B (void *compCtx)
 NSC Rf Discover entry function at Int level, enabling the TRANSAC_B feature.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_SetField (void *compCtx, uint8_t enabled)
 Turns the RF-field of the Reader on or off.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfConfig_NVMLoad (void *compCtx, ptxNSC_RfConfig_Param_t *rfConfigParams)
 Loads the RF-Configuration from NVM.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfConfig_NVMUnLoad (void *compCtx, ptxNSC_RfConfig_Param_t *rfConfigParams)
 (Un-)Loads the RF-Configuration from internal memory.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_DataMsg (void *compCtx, uint8_t *payload, size_t length, uint8_t isChained)
 NSC Data Msg entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_CltMsg (void *compCtx, uint8_t *pld, uint8_t *pldPar, size_t length)
 NSC Clt Msg entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_PresCheck_IsoDep_Nack (void *compCtx)
 NSC Presence Check at ISO-DEP(Nack) at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_PresCheck_IsoDep_EmptyBlock (void *compCtx)
 NSC Presence Check at ISO-DEP(Empty I-Frame) at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_PresCheck_NfcDep_AttentionCmd (void *compCtx)
 NSC Presence Check at NFC-DEP(Attention Command) at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_T5T_IsolatedEoF (void *compCtx)
 It sends an isolated EoF when T5T protocol is selected.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfActivate (void *compCtx, ptxNSC_RfActiv_Param_t *rfActivParams)
 NSC Rf Activate.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfDeactivate (void *compCtx, ptxNSC_Rf_Deact_Param_t *rfDeactParam)
 NSC Deactivate entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_Standby (void *compCtx, uint8_t powerMode)
 NSC Standby/WakeUp entry function at Int level.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NscSoftReset (void *compCtx)
 Nsc Soft Reset at Integration layer.
 
PTX_LIBFUNC size_t ptxTbInt_GetMtU (void *cInst)
 Get Maximum Transfer Unit (bytes that can be received) by the Stack. This setting is platform dependent.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_SetMtU (ptxTbInt_t *cInst, size_t MaxTransferUnit)
 Set Maximum Unit Transfer(bytes that can be received) by the Stack. This setting is platform dependent.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_SetEMVParams (void *compCtx, ptxNSC_Discover_Param_t *discoverParams)
 Sets up RF-Discover parameter structure for EMVCo.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_SetNFCForumParams (void *compCtx, ptxNSC_Discover_Param_t *discoverParams)
 Sets up RF-Discover parameter structure for NFC Forum.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_GetRevisionInfo (void *compCtx, ptxNSC_RevisionType_t revisionType, uint32_t *revisionInfo)
 Get various revisions of system (C-Stack, DFY-Code/-Toochain, Chip-ID, Local changes etc.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_WriteSystemConfig (void *compCtx, ptxNSC_System_t *sysConfigParams)
 NSC System Config Set.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_ReadSystemConfig (void *compCtx, ptxNSC_System_t *sysConfigParams)
 NSC System Config Get.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_ReadTempSensor (void *compCtx)
 Reads current internal temperature sensor value.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_LoadSystemConfig (void *compCtx, ptxNSC_System_t *sysConfigParams, ptxNSC_System_LoadParams_t loadType)
 Load NSC System Config.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_GPIO_Config (void *compCtx, uint8_t gpioNr, uint8_t gpioMode, uint8_t gpioFlags)
 Configures a selected GPIO-pin to work as input or output.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_GPIO_Write (void *compCtx, uint8_t gpioNr, uint8_t gpioValue)
 Writes the selected GPIO-pin high or low.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_GPIO_Read (void *compCtx, uint8_t gpioNr)
 Reads the current value of a selected GPIO-pin.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_GetDeactivateTimeout (void *compCtx, uint32_t *currentTimeout)
 Function to retrieve the current timeout value in [ms] to wait for a NSC.RF_DEACTIVATE_RSP.
 
PTX_LIBFUNC ptxStatus_t ptxTbInt_SetDeactivateTimeout (void *compCtx, uint32_t *currentTimeout)
 Function to set the current timeout value in [ms] to wait for a NSC.RF_DEACTIVATE_RSP.
 
ptxStatus_t ptxTbInt_BuildStackCommon (ptxTbInt_t *cInst, void *systemContext, ptxLog_t *log)
 Common function for building the Stack.
 

Detailed Description

Typedef Documentation

◆ ptxTbInt_t

typedef struct ptxTbInt ptxTbInt_t

This structure must be allocated initially: statically or using system-specific memory allocation.

Function Documentation

◆ ptxTbInt_Allocate()

PTX_LIBFUNC ptxTbInt_t * ptxTbInt_Allocate ( void )

Allocate memory for ptxTbInt_t - the main struct for the stack that has to be sent from caller in all the calls.

Returns
Pointer to an allocated instance of ptxTbInt_t.

◆ ptxTbInt_BuildStack()

PTX_LIBFUNC ptxStatus_t ptxTbInt_BuildStack ( ptxTbInt_t * cInst,
void * systemContext )

Build the stack.

Parameters
[in]cInstInstance of the stack allocated by ptxTbInt_Allocate.
[in]systemContextPointer to arbitrary system context, used for internal resource management in OSAL.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_BuildStackCommon()

ptxStatus_t ptxTbInt_BuildStackCommon ( ptxTbInt_t * cInst,
void * systemContext,
ptxLog_t * log )

Common function for building the Stack.

It can be called providing Log from outside or taking the Log from the integration component.

Parameters
[in]cInstInstance of the stack allocated by ptxTbInt_Allocate.
[in]systemContextPointer to arbitrary system context, used for internal resource management in OSAL.
[in]logLogger component instance to be used by the stack. If NULL, use logger instance from integration component.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_DestroyStack()

PTX_LIBFUNC ptxStatus_t ptxTbInt_DestroyStack ( ptxTbInt_t * cInst)

Destroy the stack, except for basic objects such as LOG.

Parameters
[in]cInstInstance of the stack allocated by the system.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.
Note
Call ptxTbInt_DestroyStack_Finalize to dispose also the basic objects.

◆ ptxTbInt_DestroyStack_Finalize()

PTX_LIBFUNC ptxStatus_t ptxTbInt_DestroyStack_Finalize ( ptxTbInt_t * cInst)

Destroy the basic stack objects.

Parameters
[in]cInstInstance of the stack allocated by the system.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.
Note
The LOG can be retrieved until before this call. This allows for logging of the shutdown process itself.

◆ ptxTbInt_DragonFlyActivation()

PTX_LIBFUNC ptxStatus_t ptxTbInt_DragonFlyActivation ( void * compCtx)

NSC DFY Activation entry function at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_Free()

PTX_LIBFUNC void ptxTbInt_Free ( ptxTbInt_t * cInst)

Free the memory previously allocated by ptxTbInt_t.

Parameters
[in]cInstPointer to an allocated instance of ptxTbInt_t.

◆ ptxTbInt_GetDeactivateTimeout()

PTX_LIBFUNC ptxStatus_t ptxTbInt_GetDeactivateTimeout ( void * compCtx,
uint32_t * currentTimeout )

Function to retrieve the current timeout value in [ms] to wait for a NSC.RF_DEACTIVATE_RSP.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[out]currentTimeoutPointer to store the current timeout value.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_GetIORQNtf()

ptxStatus_t ptxTbInt_GetIORQNtf ( void * cpLayer,
ptxIoRq_t * io_rq )

Integration get IO RQ Ntf (Not including NCI).

Parameters
[in]cpLayerInstance of the stack allocated by ptxTbInt_Allocate.
[in]io_rqio_rq object already allocated allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_GetIORQNtfCompletion()

void ptxTbInt_GetIORQNtfCompletion ( ptxIoRq_t * ioCpl,
void * cplLayer,
void * data,
size_t dataLength,
ptxStatus_t cplStatus )

Completion function for ptxTbInt_GetIORQNtf.

Generic path, in case of NSC-triggered action (NTF).

Parameters
[in]ioCplPointer to the I/O request object.
[in]cplLayerPointer to a component further up the stack.
[in]dataPointer to data to be processed on the completion function.
[in]dataLengthLength of the data to be processed on the completion function.
[in]cplStatusStatus of the I/O completion.

◆ ptxTbInt_GetMtU()

PTX_LIBFUNC size_t ptxTbInt_GetMtU ( void * cInst)

Get Maximum Transfer Unit (bytes that can be received) by the Stack. This setting is platform dependent.

Parameters
[in]cInstPointer to a valid component object.
Returns
MaxUnitTransfer

◆ ptxTbInt_GetRevisionInfo()

PTX_LIBFUNC ptxStatus_t ptxTbInt_GetRevisionInfo ( void * compCtx,
ptxNSC_RevisionType_t revisionType,
uint32_t * revisionInfo )

Get various revisions of system (C-Stack, DFY-Code/-Toochain, Chip-ID, Local changes etc.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]revisionTypeType of Revision.
[out]revisionInfoRevision information..
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_GetVersionDescription()

PTX_LIBFUNC const char * ptxTbInt_GetVersionDescription ( void )

Get Version Description.

Returns
Zero-terminated string containing the description text.

◆ ptxTbInt_GPIO_Config()

PTX_LIBFUNC ptxStatus_t ptxTbInt_GPIO_Config ( void * compCtx,
uint8_t gpioNr,
uint8_t gpioMode,
uint8_t gpioFlags )

Configures a selected GPIO-pin to work as input or output.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]gpioNrGPIO number.
[in]gpioModeGPIO configuration (input, output, special function).
[in]gpioFlagsGPIO flags (e.g. enable internal pull-up resistor, enable high driver strength).
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_GPIO_Read()

PTX_LIBFUNC ptxStatus_t ptxTbInt_GPIO_Read ( void * compCtx,
uint8_t gpioNr )

Reads the current value of a selected GPIO-pin.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]gpioNrGPIO number.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_GPIO_Write()

PTX_LIBFUNC ptxStatus_t ptxTbInt_GPIO_Write ( void * compCtx,
uint8_t gpioNr,
uint8_t gpioValue )

Writes the selected GPIO-pin high or low.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]gpioNrGPIO number.
[in]gpioValueValue to set (!= 0 = High, 0 = Low).
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_CltMsg()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_CltMsg ( void * compCtx,
uint8_t * pld,
uint8_t * pldPar,
size_t length )

NSC Clt Msg entry function at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]pldArray of bytes of payload.
[in]pldParArray of parity bits (in byte form).
[in]lengthLength of pld and pldPar. pld and shall have same length.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_DataMsg()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_DataMsg ( void * compCtx,
uint8_t * payload,
size_t length,
uint8_t isChained )

NSC Data Msg entry function at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]payloadPayload data to send to device.
[in]lengthLength of payload.
[in]isChained1 if it is chained data.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_Init()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_Init ( void * compCtx,
ptxNSC_Init_Param_t * initParams )

NSC Init entry function at Int level.

In this function entry params are taken from a buffer. This buffer should contain all the parameters used in NSC_INIT_CMD in the order specified in specs.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]initParamsPointer to a struct containing NSC_INIT parameters. If NULL, builder fn is called.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_LoadSystemConfig()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_LoadSystemConfig ( void * compCtx,
ptxNSC_System_t * sysConfigParams,
ptxNSC_System_LoadParams_t loadType )

Load NSC System Config.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[out]sysConfigParamsPointer to a struct that will get System parameters
[in]loadTypeSource of config parameters: file or default hardcoded values.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_PresCheck_IsoDep_EmptyBlock()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_PresCheck_IsoDep_EmptyBlock ( void * compCtx)

NSC Presence Check at ISO-DEP(Empty I-Frame) at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_PresCheck_IsoDep_Nack()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_PresCheck_IsoDep_Nack ( void * compCtx)

NSC Presence Check at ISO-DEP(Nack) at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_PresCheck_NfcDep_AttentionCmd()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_PresCheck_NfcDep_AttentionCmd ( void * compCtx)

NSC Presence Check at NFC-DEP(Attention Command) at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_Read()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_Read ( void * compCtx,
uint16_t * address,
size_t addressLen,
ptxNSC_ReadCmd_Type_t typeRd )

NSC Read entry function at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]addressAddress where application wants to read from.
[in]addressLenNumber of Address where application wants to read from.
[in]typeRdType of read operation.
Returns
Status of the operation.

◆ ptxTbInt_NSC_ReadSystemConfig()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_ReadSystemConfig ( void * compCtx,
ptxNSC_System_t * sysConfigParams )

NSC System Config Get.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[out]sysConfigParamsPointer to a struct containing System parameters
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_ReadTempSensor()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_ReadTempSensor ( void * compCtx)

Reads current internal temperature sensor value.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfActivate()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfActivate ( void * compCtx,
ptxNSC_RfActiv_Param_t * rfActivParams )

NSC Rf Activate.

Note
Bridge at integration level.
Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]rfActivParamsPointer to a struct containing NSC_RF_ACTIVATE parameters.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfConfig()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfConfig ( void * compCtx,
ptxNSC_RfConfig_Param_t * rfConfigParams )

NSC Rf Config.

Note
Bridge at integration level.
Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]rfConfigParamsPointer to a struct containing NSC_RF_CONFIG parameters. If NULL builder fn is called.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfConfig_NVMLoad()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfConfig_NVMLoad ( void * compCtx,
ptxNSC_RfConfig_Param_t * rfConfigParams )

Loads the RF-Configuration from NVM.

Parameters
[in]compCtxPointer to an initialized instance of the main component in the stack.
[in]rfConfigParamsPointer to RF-Configuration parameters.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfConfig_NVMUnLoad()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfConfig_NVMUnLoad ( void * compCtx,
ptxNSC_RfConfig_Param_t * rfConfigParams )

(Un-)Loads the RF-Configuration from internal memory.

Parameters
[in]compCtxPointer to an initialized instance of the main component in the stack.
[in]rfConfigParamsPointer to RF-Configuration parameters.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfDeactivate()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfDeactivate ( void * compCtx,
ptxNSC_Rf_Deact_Param_t * rfDeactParam )

NSC Deactivate entry function at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]rfDeactParamPointer to an rf Deact Parameters.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfDiscover()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfDiscover ( void * compCtx,
ptxNSC_Discover_Param_t * discoverParams )

NSC Discover entry function at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]discoverParamsPointer to discover parameters.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfDiscover_EmvCo_TRANSAC_A()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfDiscover_EmvCo_TRANSAC_A ( void * compCtx)

NSC Rf Discover entry function at Int level, enabling the TRANSAC_A feature.

Note
This function is expected to be used just for EMVCo scenarios, so Rf Discover Parameters are taken internally.
Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfDiscover_EmvCo_TRANSAC_B()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfDiscover_EmvCo_TRANSAC_B ( void * compCtx)

NSC Rf Discover entry function at Int level, enabling the TRANSAC_B feature.

Note
This function is expected to be used just for EMVCo scenarios, so Rf Discover Parameters are taken internally.
Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfSetParams()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfSetParams ( void * compCtx,
ptxNsc_RfPar_t * rfPar,
size_t rfParLen )

NSC RF SET PARAMETER entry function at Int level.

This function allows the application to write one, some or all available parameters for NSC_RF_SET_PARAMETERS

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]rfParPointer to an array of Rf parameters available.
[in]rfParLenLength of /ref rfPar.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfTestRun()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfTestRun ( void * compCtx,
ptxNsc_RfTest_Id_t rfTestId,
uint8_t * rfTestParams,
size_t rfTestParamsLen )

Function for NSC_RF_RUN_CMD.

This function builds the NSC_RF_RUN_CMD accordingly to inputParams and send it to the chip.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]rfTestIdTest Identifier.
[in]rfTestParamsTest Parameters.
[in]rfTestParamsLenNumber of Test Parameters.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_RfTestStop()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_RfTestStop ( void * compCtx)

Function for NSC_RF_STOP_CMD.

This function builds the NSC_RF_STOP_CMD accordingly to inputParams and send it to the chip.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_SetEMVParams()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_SetEMVParams ( void * compCtx,
ptxNSC_Discover_Param_t * discoverParams )

Sets up RF-Discover parameter structure for EMVCo.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]discoverParamsPointer to discover parameters.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_SetField()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_SetField ( void * compCtx,
uint8_t enabled )

Turns the RF-field of the Reader on or off.

Attention: This function shall be used for test purposes only (!). It shall not be mixed with other RF-functions from this library (e.g. activate Polling etc.). Once the RF-field has been turned on, it shall be disabled afterwards again by using this function call.

Parameters
[in]compCtxPointer to an initialized instance of the main component in the stack.
[in]enabledIf set to != 0, the RF-field gets enabled, disabled otherwise.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_SetNFCForumParams()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_SetNFCForumParams ( void * compCtx,
ptxNSC_Discover_Param_t * discoverParams )

Sets up RF-Discover parameter structure for NFC Forum.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]discoverParamsPointer to discover parameters.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_Standby()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_Standby ( void * compCtx,
uint8_t powerMode )

NSC Standby/WakeUp entry function at Int level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]powerMode1 = Standby, 0 = WakeUp.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_T5T_IsolatedEoF()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_T5T_IsolatedEoF ( void * compCtx)

It sends an isolated EoF when T5T protocol is selected.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_Write()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_Write ( void * compCtx,
uint16_t * address,
size_t addressLen,
uint8_t * value,
size_t valueLen,
ptxNSC_WriteCmd_Type_t typeWr )

NSC Write entry function at integration level.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]addressBuffer with the addresses to write to.
[in]addressLenNumber of addresses to write to.
[in]valueBuffer with the values to write.
[in]valueLenNumber of values to write.
[in]typeWrType of Write operations.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSC_WriteSystemConfig()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSC_WriteSystemConfig ( void * compCtx,
ptxNSC_System_t * sysConfigParams )

NSC System Config Set.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]sysConfigParamsPointer to a struct containing System parameters
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSCCompletion()

void ptxTbInt_NSCCompletion ( ptxIoRq_t * ioCpl,
void * cplLayer,
void * data,
size_t dataLength,
ptxStatus_t cplStatus )

Internal default completion function general purpose NSC.

Parameters
[in]ioCplPointer to the I/O request object.
[in]cplLayerPointer to a component further up the stack.
[in]dataPointer to data to be processed on the completion function.
[in]dataLengthLength of the data to be processed on the completion function.
[in]cplStatusStatus of the I/O completion.

◆ ptxTbInt_NSCFwDownloader()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSCFwDownloader ( void * compCtx,
uint8_t * pData,
int length )

NSC download firmware image to the chip.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]pDataPointer to data containing fw image. Already allocated.
[in]lengthLength of the data of the fw image.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSCGetMiscRFConfig()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSCGetMiscRFConfig ( void * compCtx,
uint8_t * configBuffer,
size_t * configBufferLen )

NSC Get last loaded Misc. RF-Configuration.

This function is used to retrieve a copy of the last loaded miscellaneous RF-Configuration settings.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]configBufferPointer to buffer where Misc. settings should be stored.
[in,out]configBufferLenSize of configBuffer (in), Length of stored Misc. settings (out).
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_NSCGetMode()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NSCGetMode ( void * compCtx,
uint8_t * mode )

NSC Get State.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]modePointer to NSC state / mode (Hardware Mode = 0, System Mode = 1).
Returns
Status of the operation.

◆ ptxTbInt_NscSoftReset()

PTX_LIBFUNC ptxStatus_t ptxTbInt_NscSoftReset ( void * compCtx)

Nsc Soft Reset at Integration layer.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_ReturnIoRqItem()

void ptxTbInt_ReturnIoRqItem ( ptxTbInt_t * cInst,
ptxIoRq_t * ioCpl,
ptxStatus_t reqStatus )

Internal function to return I/O request objects in case of non-pending status.

This releases internal buffer item (removes from the list) and frees the memory allocated for the object.

Parameters
[in]cInstPointer to the allocated integration component structure.
[in,out]ioCplPointer to the I/O request object to be freed.
[in]reqStatusIf reqStatus equals ptxStatus ptxStatus_Pending, ioCpl is not returned (freed). Otherwise, ioCpl is returned - memory allocated by that object is freed.

◆ ptxTbInt_SetDeactivateTimeout()

PTX_LIBFUNC ptxStatus_t ptxTbInt_SetDeactivateTimeout ( void * compCtx,
uint32_t * currentTimeout )

Function to set the current timeout value in [ms] to wait for a NSC.RF_DEACTIVATE_RSP.

Parameters
[in]compCtxInstance of the stack allocated by ptxTbInt_Allocate.
[in]currentTimeoutPointer to variable holding new timeout value. If set to NULL, default value will be used.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_SetMtU()

PTX_LIBFUNC ptxStatus_t ptxTbInt_SetMtU ( ptxTbInt_t * cInst,
size_t MaxTransferUnit )

Set Maximum Unit Transfer(bytes that can be received) by the Stack. This setting is platform dependent.

Parameters
[in]cInstPointer to a valid component object.
[in]MaxTransferUnitNumber of bytes that can be received in a single transfer by the stack.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_SetParameter()

PTX_LIBFUNC ptxStatus_t ptxTbInt_SetParameter ( ptxTbInt_t * cInst,
ptxNscFactory_P_t parType,
uint8_t * parBuf,
uint32_t parLenOrValue )

Set Factory Operating Parameter.

Set an operating parameter for the factory. This interface is intended to apply parameters that will be propagated to the individual components once they get instantiated. Call the function before ptxNscFactory_BuildStack for parameters needed by the components to properly initialize.

Parameters
[in]cInstPointer to the allocated integration component structure.
[in]parTypeType of the parameter to set.
[in]parBufUse this to pass longer data types or strings (e.g. "/dev/ttyUSB0"). Set to NULL when not applicable. Caution: String zero-termination is not handled, always use the next parameter for string length.
[in]parLenOrValueBuffer length or integer parameter.
  • If the previous buffer parameter is used (not NULL) this parameter is the length of the buffer. Please note that this will be needed as soon as the buffer parameter is used.
  • With the previous buffer parameter set to NULL this parameter is a simple unsigned integer.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_SetUp()

PTX_LIBFUNC ptxStatus_t ptxTbInt_SetUp ( void * compCtx,
pptxInt_Completion_t complFn,
pptxInt_CompletionNTF_t complFnNtf,
void * sysCtx )

Set up the stack.

Parameters
[in]compCtxInstance of the stack allocated by the software that integrates the stack.
[in]complFnCallback function pointer to handle Responses.
[in]complFnNtfCallback function pointer to handle Notifications.
[in]sysCtxPointer to arbitrary system context. May be NULL on some systems.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.

◆ ptxTbInt_ShutDown()

PTX_LIBFUNC ptxStatus_t ptxTbInt_ShutDown ( void * compCtx)

Shut down the stack.

Parameters
[in]compCtxInstance of the stack allocated by the software that integrates the stack.
Returns
Status, indicating whether the operation was successful. See ptxStatus_t.