added ignore file (cvs)
[smp-waschbecken/ser_cp.git] / ser.h
1 /*
2  * ser.h -- ser_serv and serv_get
3  *
4  */
5
6 #include <termios.h>
7
8 #define BAUDRATE B38400
9 #define BUFSIZE 1024
10
11 #define CONN_REQ 1
12 #define CONN_ACK 2
13 #define CONN_EST 4
14
15 typedef struct info_s {
16   char ttsdev[32];
17   int ttsfd;
18   struct termios ttsconf;
19 } info_t;
20
21 /* function prototypes */
22 int ser_init(info_t *info);
23 int ser_config(info_t *info);
24 int ser_send_hello(info_t *info);
25 int ser_read_and_out(info_t *info);
26 int ser_read_and_write(info_t *info);
27 int ser_connect(info_t *info);
28 int ser_listen_and_accept(info_t *info);