Annotation of researchv9/jerq/src/32ld/proto.h, revision 1.1.1.1

1.1       root        1: /*
                      2:  *     Packet format:
                      3:  *
                      4:  *     0x80^Seq | Size | 4 bytes of address | 0 or more data bytes | CRC1 | CRC2
                      5:  *
                      6:  *     where PKTASIZE <= Size <= (PKTASIZE+MAXPKTDSIZE).
                      7:  *
                      8:  *     If Size == PKTASIZE then the address is the start address.
                      9:  *     If Size > PKTASIZE then load data contiguously at the address.
                     10:  *
                     11:  *     Acknowledgements consist of the first byte
                     12:  *     from each correctly received packet (Seq)
                     13:  *     acks apply to all packets sent, up to and including the one acked.
                     14:  *     Timeouts cause retransmission of all unacknowledged packets
                     15:  */
                     16: 
                     17: #define        MAXPKTSIZE      128             /* Efficient size for system */
                     18: #define        PKTHDRSIZE      2               /* Seq + Size */
                     19: #define        PKTCRCSIZE      2               /* CRC 16 */
                     20: #define        PKTASIZE        4               /* sizeof(long) on MC68000 */
                     21: #define        MAXPKTDSIZE     MAXPKTSIZE-(PKTHDRSIZE+PKTCRCSIZE+PKTASIZE)
                     22: 
                     23: #define        PTYP            0xc0            /* Masked with Seq to guarantee non-zero */
                     24: #define        ACKON           0x80            /* Ack expected for this packet */
                     25: #define        ACKOFF          0xc0            /* No ack expected, but remember errors */
                     26: #define        NOCRC           0x40            /* No error detection on packet */
                     27: #define        SEQMASK         (~PTYP)
                     28: #define SEQMOD         0x40            /* SEQMASK+1 */
                     29: 
                     30: #define        WAIT    1
                     31: #define        OK      2
                     32: 
                     33: #define NPBUFS 2
                     34: 
                     35: extern char freepkts;                  /* 0 or 1 */

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.