EasyManua.ls Logo

W&T Com-Server++ - Page 194

W&T Com-Server++
228 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...
194
W&T Expanded services of the Com-Server
The structure COM_ERROR
The COM_ERROR structure has a length of one WORD (16-bit
integer) and contains all the error states of the serial port.
typedef struct _com_error
{ union
{ word error_ags;
struct _err_ags
{ word f_data : 1; //not used/reserved
word f_net : 2; //not used/reserved
word f_com : 1; //Set when COM port error detected
word f_break : 1; //Reect the break ag
word f_cts_time : 1; //Time out while waiting on CTS
word f_dsr_time : 1; //Time out while waiting on DSR
word f_rlsd_time : 1; //Time out while waiting on RLSD (CD)
word f_overrun : 1; //Overrun error
word f_parity : 1; //Parity error
word f_frame : 1; //Framing error
word f_status : 1; //not used/reserved
word no_use_1 : 1; //not used
word no_use_2 : 1; //not used
word f_rx_over : 1; //Ring buffer overrun after handshake
word no_use_3 : 1; //not used
};
};
} COM_ERROR;
The structure COM_STAT
The COM_STAT structure has a length of three WORDS (16-bit
integer) and contains the status of the handshake lines as well
as the number of bytes which are in the send and receive buf-
fers of the serial port. It also allows you to directly influence
the handshake lines and buffer.
typedef struct _com_stat
{ union
{ word com_ags;
struct _com_ags
{ word cts_hold :1; //CTS line -LowByte
word dsr_hold :1; //DSR line |
word ri_hold :1; //not used/reserved |is set with every
word rlsd_hold :1; //reserved/reserved |received packet
word dtr_hold :1; //DTR line |
word rts_hold :1; //RTS line |
word x_receive :1; //XOFF received |
word x_send :1; //XOFF was send -

Table of Contents

Related product manuals