Unitech mr350 mkii Software Guide

Page of 33
 
12
Chapter 3.  Function library 
This chapter introduces whole function library by function name sequence. It includes function 
description, input/output parameter and data structure. This C function library can be included into 
user’s application program and please use LARGE MEMORY MODEL to compile it. 
 
3.1  Files description of Smart Card function library 
     There are 4 files in our function library. It shows as below 
 
Smart CardINCL.H    : C Include file for function library 
GEMSmart Card.LIB  : Library file of Smart Card function library 
GEMSmart Card.OBJ  ; Object file of Smart Card function library 
MAKE.BAT ; Batch file to compile and link user’s program 
 
3.2  How to build-up application program 
If user’s application program is SAMPLE01.C, just follow below steps to compile and link the your 
program. 
 
Step 1 : Compile the main program with Large memory model 
 
 
Cl /AL /c SAMPLE01.c 
Step 2 : User can use GEMSmart Card.LIB or GEMSmart Card.OBJ to link the program   
Step 2.1 Use GEMSmart Card.LIB as library file 
link /stack:0x1000 sample01 
[.exe] enter 
[.map] enter 
[.lib] GEMSmart Card enter 
[.def] enter 
Note : stack size should be more than 0x1000. 
Step 2.2 : Use GEMSmart Card.OBJ   
link sample01+GEMSmart Card /stack:0x1000;