使用Vx820 Pinpad的Verifone ADK中的EMV非接触式

时间:2018-08-14 15:06:27

标签: c++ emv verifone

我已经有一个完整的EMV应用程序,现在我想实现EMV Contactless,到目前为止,我已经做到了:

  • 在编译中导入库:“%VRX_IMPORT%\ lib \ ctls.o”
  • 添加此行“ -l CTLS.LIB = N:/CTLS.LIB”
  • 在终端中加载库“ libEMV_CT_Framework.vsl”和“ libEMV_CTLS_Client.vsl”。

此函数中发生错误:

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

呼叫后:

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

终端有时会保持黑色,有时会重新启动。

这是完整的EMV初始化功能代码:

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 个答案:

没有答案