source: trunk/include/imp_exp_gen.h @ 5054

Revision 1840, 2.2 KB checked in by dietz, 13 years ago (diff)

Added HEARTSEQ definition (for export*ack/import_ack) and cleaned
up formatting.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1
2/*
3 *   THIS FILE IS UNDER RCS - DO NOT MODIFY UNLESS YOU HAVE
4 *   CHECKED IT OUT USING THE COMMAND CHECKOUT.
5 *
6 *    $Id$
7 *
8 *    Revision history:
9 *     $Log$
10 *     Revision 1.3  2005/04/28 23:14:19  dietz
11 *     Added HEARTSEQ definition (for export*ack/import_ack) and cleaned
12 *     up formatting.
13 *
14 *     Revision 1.2  2000/07/24 18:54:14  lucky
15 *     Added MAX_ALIVE_STR definition so that import and export can
16 *     agree on the max length.
17 *
18 *     Revision 1.1  2000/02/14 20:05:54  lucky
19 *     Initial revision
20 *
21 *
22 */
23
24#ifndef IMP_EXP_GEN_H
25#define IMP_EXP_GEN_H
26
27/* This is the include file for import_generic and export_generic, created
28   to deal with  binary messages . Alex 10/10/96 */
29/*
30Modified to read binary messages, alex 10/10/96:
31The scheme (I got it from Carl) is define some sacred characters.
32Sacred characters are the start-of-message and end-of-message framing
33characters, and an escape character. The sender's job is to cloak
34unfortunate bit patterns in the data which look like sacred characters
35by inserting before them an 'escape' character.  Our problem here is to
36recognize, and use, the 'real' start- and end-of-messge characters,
37and to 'decloak' any unfortunate look-alikes within the message body.
38*/
39
40/* The sacred characters for framing messages
41 ********************************************/
42#define STX  2    /* Start Transmission: used to frame beginning of message  */
43#define ETX  3    /* End Transmission:   used to frame end of message        */
44#define ESC 27    /* Escape: used to 'cloak' unfortunate binary bit patterns */
45                  /*         which look like sacred characters               */
46
47/* Define States for Socket Message Interpretation
48 *************************************************/
49#define SEARCHING_FOR_MESSAGE_START   0
50#define EXPECTING_MESSAGE_START       1
51#define ASSEMBLING_MESSAGE            2
52 
53/* Other useful definitions
54 **************************/
55#define MAX_ALIVE_STR  256   /* maximum size of the socket alive string        */
56#define INBUFFERSIZE   100   /* buffer Size for Socket Receiving Buffer        */
57#define HEARTSEQ       255   /* sequence# always assigned to socket alive msgs */
58
59#endif
Note: See TracBrowser for help on using the repository browser.