home *** CD-ROM | disk | FTP | other *** search
/ Media Share 9 / MEDIASHARE_09.ISO / hamradio / s920603.zip / QTSO.H < prev    next >
C/C++ Source or Header  |  1992-04-30  |  1KB  |  56 lines

  1. #ifndef _QTSO_H
  2. #define _QTSO_H
  3. #ifndef    _GLOBAL_H
  4. #include "global.h"
  5. #endif
  6.  
  7. #ifndef    _MBUF_H
  8. #include "mbuf.h"
  9. #endif
  10.  
  11. #ifndef    _IFACE_H
  12. #include "iface.h"
  13. #endif
  14.  
  15. /* PPP definitions */
  16. #define    PPP_ALLOC    128    /* mbuf allocation increment */
  17.  
  18. /* HDLC envelope constants */
  19. #define HDLC_ENVLEN    8    /* Max bytes for HDLC envelope (outgoing) */
  20.  
  21. #define HDLC_FLAG    0x7e    /* HDLC async start/stop flag */
  22. #define HDLC_ESC_ASYNC    0x7d    /* HDLC transparency escape flag for async */
  23. #define HDLC_ESC_COMPL    0x20    /* HDLC transparency bit complement mask */
  24.  
  25. #define HDLC_FCS_START    0xffff    /* Starting bit string for FCS calculation */
  26. #define HDLC_FCS_FINAL    0xf0b8    /* FCS when summed over frame and sender FCS */
  27.  
  28. #define PPP_ESCAPED    0x01
  29. #define PPP_TOSS    0x02
  30.  
  31. struct qtso {
  32.     struct qtso *next;
  33.     int32 sendframes;
  34.     int32 aborts;
  35.     int32 crcerrs;
  36.     int32 goodframes;
  37.     struct iface *iface;
  38. };
  39. #define    NULLQTSO    (struct qtso *)0
  40.  
  41. extern struct qtso *Qtso;
  42.  
  43. /* In qtso.c: */
  44. int qtso_free __ARGS((struct iface *ifp));
  45. int qtso_send __ARGS((struct mbuf *data,struct iface *iface,int32 gateway,
  46.     int tos));
  47. int qtso_output __ARGS((struct iface *iface, char dest[], char source[],
  48.     int16 type, struct mbuf *data));
  49. void qtso_recv __ARGS((int dev,void *p1,void *p2));
  50.  
  51. int qtso_init __ARGS((struct iface *iface,int vj));
  52. void qtso_proc __ARGS((struct iface *iface, struct mbuf *bp));
  53.  
  54. #endif    /* _PPP_H */
  55.  
  56.