Section 2 - Architecture
HOW TO PROCESS CARD USING EXPRESSCARD 1000 API
To process card, follow these steps:
1.
Find the attached ExpressCard 1000 device by calling function
MTECSDK_GetDevice
.
2.
Use function
MTECSDK_OpenDevice
to open the device.
3.
ExpressCard 1000 is now ready to accept the XML options using function
MTECSDK_ProcessDoc
. For every document that is processed, a set of options must be sent to the
device. These options define how the document will be processed, i.e., image file, image type, text
line, text font, magstripe encode data, emboss data, etc. The options are stored as key/value pairs
in a buffer. The memory for this buffer must be allocated big enough to store all selected options.
These options must be sent to ExpressCard 1000 device using function
MTECSDK_ProcessDoc
.
Use function
MTECSDK_SetValue
to store the key/value pairs in the option buffer. The options
can be set in the buffer only once.
4.
Use function
MTECSDK_ProcessDoc
to send the process options to the ExpressCard 1000 device.
5.
ExpressCard 1000 processes the document with the given process options and returns the result of
the process operation. The result is stored in the third parameter of the function
MTECSDK_ProcessDoc
. The result contains only the information of the operation and information
of the device. It does not contain scanned data. Information such as the size of the scanned images
and the image identifier are included. The image information can be found under ImageInfo
section. Use function
MTECSDK_GetValue
to retrieve key/value pair for image information. If
there is no error returned in the document information, use function
MTECSDKGetImage
or
function
MTECSDKGetImages
to get image data.
6.
Go to step 4 to process the next card.
PROCESS OPTIONS
Process options are stored as key/value pairs in a buffer. The structure of the options follows XML
format. Use function
MTECSDK_SetValue
to add an option to this structure. Options are string-based
key/value pairs. Each option is stored only once in the buffer. Function
MTECSDK_GetValue
can be used
to retrieve a key/value pair from this buffer.
11
Содержание EXPRESSCARD 1000
Страница 6: ......