EMV Contactless in Verifone ADK using Vx820 Pinpad

423 Views Asked by At

I already have an application that makes the full flow of EMV and now I want to implement EMV Contactless, this I have done so far:

  • Import the library in the compilation: "% VRX_IMPORT% \ lib \ ctls.o"
  • Add this line "-l CTLS.LIB = N: /CTLS.LIB"
  • Load the libraries "libEMV_CT_Framework.vsl" and "libEMV_CTLS_Client.vsl" in the terminal.

The error occurs in this function:

EMV_CTLS_Init_Framework (64, (EMV_CT_CALLBACK_FnT) FrameworkEMVCallbackFunction, (void *) NULL, options, & Result);

after calling:

EMV_CT_Init_Framework (64, (EMV_CT_CALLBACK_FnT) FrameworkEMVCallbackFunction, (void *) NULL, options);

The terminal sometimes stays black and sometimes restarts.

This is the complete EMV Init Function code:

unsigned long initializeApplication(unsigned char virtualTerminal, unsigned char EnableTRACE, int autoRetap)
{
  EMV_ADK_INFO        erg;
  unsigned long       virtTerm;
  unsigned long       Result;
  unsigned long       options;

  virtTerm = ((virtualTerminal << 24) & 0xFF000000);

  initializeEmvParameters();

  // Init Framework
  options = virtTerm | EMV_CT_INIT_OPT_CONFIG_MODE | EMV_CT_INIT_OPT_L1_DUMP;
  if (EnableTRACE)
      options |= EMV_CT_INIT_OPT_TRACE | EMV_CT_INIT_OPT_TRACE_CLT;
  erg = EMV_CT_Init_Framework(64, (EMV_CT_CALLBACK_FnT)FrameworkEMVCallbackFunction, (void*)NULL, options);
  if(erg != EMV_ADK_OK)
  {
    APP_TRACE("Init EMV framework returned %d", erg);
    return(EMV_INIT_ERR_INIT_KERNEL);
  }

  options = virtTerm | EMV_CTLS_INIT_OPT_CONFIG_MODE | EMV_CTLS_INIT_OPT_L1_DUMP | autoRetap;
  if (EnableTRACE)
      options |= EMV_CTLS_INIT_OPT_TRACE | EMV_CTLS_INIT_OPT_TRACE_CLT; /*|EMV_CTLS_LED_CALLBACK_EXT*/
  erg = EMV_CTLS_Init_Framework(64, (EMV_CT_CALLBACK_FnT)FrameworkEMVCallbackFunction, (void*)NULL, options, &Result );
  if(erg != EMV_ADK_OK)
  {
    APP_TRACE("Init EMV framework (CTLS) returned %d", erg);
    return(EMV_INIT_ERR_CTLS_ONLY);
  }
}
0

There are 0 best solutions below