EasyManua.ls Logo

VeriFone MX800 Series - Initialize Packet Mode

VeriFone MX800 Series
344 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
DEVICE DRIVERS
Initialize Packet Mode
M
X
800 SERIES PROGRAMMERS GUIDE 95
Initialize Packet Mode
Prior to reading or writing messages in packet mode, startPktMode() must be
called to configure the packet mode parameters. The packet_parms structure
(in struct Opn_Blk) must be correctly completed before calling
StartPktMode(). Opening the ECR using ecrOpen() is automatically set. If
packet mode is required on a port that is not opened with ecrOpen(), then the
application is required to fill in this structure.
/* --------------------- Packet Defines --------------------------*/
typedef struct
{
unsigned char stx_char; // Define start character
unsigned char etx_char; // Define end character
unsigned char count; // Define number of characters for error
check
int max_pkt; // Maximum message length in bytes
void (*pPktHandler) (char *, int); // RX message callback function
} packet_parm_t;
Prototype
int startPktMode(int hCom, struct Opn_Blk *openBlock);
Parameters
Return Values
hCom Handle of a previously opened serial port
openBlock Serial communication control structure
0 Successful execution
< 0 Error

Table of Contents

Other manuals for VeriFone MX800 Series

Related product manuals