Hello all. I'm currently working on a Contact Card Interface. The idea is to send APDU's from a i.MX8M microprocessor throught it's USB bus to PN7412, that has a TDA8026 connected to it. I was able to successfully communicate and activate contact cards located at PN main slot, but when I try to replicate the same procedure in a card located at one of the TDA8026 slots (Slot 5), I get a empty ATR vector response, meaning that no activation was done. Here's the steps I followed in order to make it respond.
phStatus_t eStatus = PH_ERR_FAILED;
#ifdef PHFL_ENABLE_SAM_KEY_STORE
/* Global instance for CT pal parameter's structure */
phhalCt_InitParam_t sInitParams;
uint8_t gbAtrBuffer[32]={0};
phpalCt_DataParams_t tDataParams;
tDataParams.pbAtrBuffer = (uint8_t *)&gbAtrBuffer;
tDataParams.bSizeOfATRbuffer = 32;
sInitParams.bAutoCTDeactivationEnable= 0;
sInitParams.bCardPresConnectorStatus= gpkphCfg_EE_Boot_CT->bConnectorType;
sInitParams.bPullupSetStatus = gpkphCfg_EE_Boot_CT->bPullUp;
sInitParams.bSlewRateConfig = gpkphCfg_EE_Boot_CT->bSlewRate;
phpalCt_Init(&sInitParams);
do
{
tDataParams.pbAtrBuffer = (uint8_t *)&gbAtrBuffer;
tDataParams.bSizeOfATRbuffer = 32;
/*Initialize the TDA*/
eStatus = phhalTda_Init();
CHECK_SUCCESS(eStatus);
/*Switch to auxiliary slot, because SAM is will be used from auxiliary slot*/
phhalCt_SwitchSlot(E_AUXILIARY_SLOT);
/*Select the Auxiliary slot number*/
eStatus = phhalTda_SelectSlot((uint32_t)gbTdaSlotNum);
/*Check the presence of SAM in the selected slot*/
eStatus = phhalTda_GetStatus(E_PRESENCE);
if(eStatus != SAM_CARD_PRESENT_IN_SLOT)
{
break;
}
phpalCt_SetConfig(E_EMV_ENABLE,0);
/*Activate the SAM card*/
eStatus = phhalTda_ActivateCard(&tDataParams);
I'm using DoorAcceessExample_AUX_slot software example provided by NXP and developed by Anish Ahammed in 2016.