更新时间:2018-06-26 10:47:19
IC卡辅助工具

IC卡辅助工具

该工具以SDK开发包的形式提供商户,帮助商户组装IC卡脱机交易的标准文件,并负责和银联商户服务系统对接通信,完成文件传输和反馈文件获取。

更新时间:2015-09-10    工具大小:33MB                软件支持:XP/Vista/Win7/Win8

        点击此处下载

        

image.png


        image.png

</>示例代码

c语言:

ic_load_cfg();
tmp_ret=ic_open(argv[1]);
tmp_ret=ic_add(in_str_buf, strlen(in_str)/2);
tmp_ret=ic_close();
或者:
ic_load_cfg();
tmp_ret=ic_open(argv[1]);
Struct ic_trans_def *ic_trans=(struct ic_trans_def*)malloc(sizeof(struct ic_trans_def));
tmp_ret=ic_trans_init(ic_trans);
tmp_ret=ic_trans_iso_fld_set(ic_trans,25, 2,"07");
tmp_ret=ic_trans_factor_set(ic_trans,0,8, "00000002");
tmp_ret=ic_trans_fld_set(ic_trans,0,4, "0221");
tmp_ret=ic_add(in_str_buf, strlen(in_str)/2);
tmp_ret=ic_close()


java语言:

ICFile icFile=ICFile.getInstance();
tmp_ret=icFile.open("D:\\aa.txt");
tmp_ret=icFile.add(StringUtil.hexStr2Chars("00AA60000000006022000000000220302004C034C0801900000000000000777700001302100606376223330450442215D0000101108801001010800104996223330450442215D1561560500050000000015010108214000000001D0218888885D000000000D040000000210000000000003030333032383030303030303031393837363534333231303030303031313536001324000002000500001600000200001204204644353444323135"));
tmp_ret=icFile.close();
或者:
ICFile icFile=ICFile.getInstance();
tmp_ret=icFile.open("D:\\aa.txt");
ICTrans icTrans=null;
try {
icTrans=new ICTrans(StringUtil.hexStr2Chars("00AA60000000006022000000000220302004C034C0801900000000000000777700001302100606376223330450442215D0000101108801001010800104996223330450442215D1561560500050000000015010108214000000001D0218888885D000000000D040000000210000000000003030333032383030303030303031393837363534333231303030303031313536001324000002000500001600000200001204204644353444323135"));
} catch (Exception e)
{
// TODO Auto-generated catch blocke.printStackTrace();
icTrans=null;
}
tmp_ret=icTrans.addISOFld(25, "07".toCharArray());
tmp_ret=icTrans.addFactor(0, "00000002".toCharArray());
tmp_ret=icTrans.addFld(0, "0221".toCharArray());
tmp_ret=icFile.add(icTrans);
tmp_ret=icFile.close();


咨询与服务