EasyManua.ls Logo

VeriFone MX800 Series - Serial Communication Control Structure; Protocol

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
Serial Communication Control Structure
M
X
800 SERIES PROGRAMMERS GUIDE 93
Serial
Communication
Control
Structure
The following are the structures defined for configuring serial ports on the M
x
800
series of terminals. They contain all the necessary elements for defining the ports
into the different modes that each of them support.
typedef struct{
short status;
short comm_handle;
short visa_sel; /* 0 - visa not selected, 1 - visa selected */
int port;
void (*pEcrReceive) (void); /* ecr rx callback for application */
struct Opn_Blk openBlock;
}ECR_INFO;
/* --------------------- Packet Defines --------------------------*/
typedef struct
unsigned char stx_char;
unsigned char etx_char;
unsigned char count;
int max_pkt;
void (*pPktHandler) (char , int); /* rx callback for packet mode
*/
} packet_parm_t;
/* --------------------- ECR tailgate Defines ---------------------*/
typedef struct
{unsigned char poll_addr;
} ECRtailgate_parm_t;
/* -------------------- Open Block Structure ----------------------*/
struct Opn_Blk
{unsigned int rate;
unsigned int format;
unsigned int protocol;
unsigned int parameter;
packet_parm_t packet_parms;
union {
ECRtailgate_parm_t ECRtailgate_parms;
} trailer;
};
The structures defined above comprise the necessary settings needed to
configure a serial port for RS232/485, Tailgate, Visa, Packet mode or other
protocols.
Protocol
The main structure is the Open Block structure (Opn_Blk), which contains an
element called protocol. The protocol variable indicates what mode the port
should be configured for and further defines what other fields are applicable for
that mode.

Table of Contents

Other manuals for VeriFone MX800 Series

Related product manuals