home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Misc / PsionPalmTopConnector.LHA / AmigaNCP09beta / Developer / Include / Libraries / ncplib.h
Encoding:
C/C++ Source or Header  |  1994-10-19  |  3.0 KB  |  108 lines

  1. #ifndef LIBRARIES_NCPLIB_H
  2. #define LIBRARIES_NCPLIB_H
  3.  
  4. /*
  5. **
  6. **  ncp.library
  7. **  -----------
  8. **
  9. */
  10.  
  11. #ifndef EXEC_TYPES_H
  12. #include <exec/types.h>
  13. #endif
  14.  
  15. #define NCP_NAME "ncp.library"
  16. #define NCP_VERSION 1
  17.  
  18. extern struct Library *NCPBase;
  19.  
  20. /*
  21. ** 'fake' types for intel byte order support 
  22. */
  23. typedef unsigned short IWORD;
  24. typedef unsigned long ILONG;
  25.  
  26. /*
  27. ** Error returns from Read/Write
  28. */
  29.  
  30. #define NCPE_INUSE -1        /* Read/Write already pending */
  31. #define NCPE_ABORTED -2        /* Aborted */
  32. #define NCPE_OFFLINE -3        /* Connection offline */
  33. #define NCPE_INACTIVE -4    /* Channel inactive */
  34. #define NCPE_NOTFOUND -5    /* Remote Process not found */
  35.  
  36.  
  37. /*
  38. **    SAS/C Pragmas
  39. */
  40.  
  41. #ifdef __SASC
  42.  
  43. #pragma libcall NCPBase NCP_Rexx 1E 0
  44. #pragma libcall NCPBase NCP_IWORD 24 001
  45. #pragma libcall NCPBase NCP_ILONG 2A 001
  46. #pragma libcall NCPBase NCP_OpenChannel 30 09803
  47. #pragma libcall NCPBase NCP_CloseChannel 36 801
  48. #pragma libcall NCPBase NCP_Read 3C 09803
  49. #pragma libcall NCPBase NCP_BeginRead 42 09803
  50. #pragma libcall NCPBase NCP_CheckRead 48 801
  51. #pragma libcall NCPBase NCP_AbortRead 4E 801
  52. #pragma libcall NCPBase NCP_WaitRead 54 801
  53. #pragma libcall NCPBase NCP_Write 5A 09803
  54. #pragma libcall NCPBase NCP_BeginWrite 60 09803
  55. #pragma libcall NCPBase NCP_CheckWrite 66 801
  56. #pragma libcall NCPBase NCP_AbortWrite 6C 801
  57. #pragma libcall NCPBase NCP_WaitWrite 72 801
  58. #pragma libcall NCPBase NCP_IWORDP 78 9802
  59. #pragma libcall NCPBase NCP_ILONGP 7E 9802
  60. #pragma libcall NCPBase NCP_IWORDPI 84 801
  61. #pragma libcall NCPBase NCP_ILONGPI 8A 801
  62. #pragma libcall NCPBase NCP_private1 90 A01
  63. #pragma libcall NCPBase NCP_ReadSig 96 801
  64. #pragma libcall NCPBase NCP_WriteSig 9c 801
  65. #pragma libcall NCPBase NCP_ibm2iso ae 001
  66. #pragma libcall NCPBase NCP_iso2ibm b4 001
  67. #pragma libcall NCPBase NCP_clnl ba 801
  68. #pragma libcall NCPBase NCP_Fault c0 198004
  69. #pragma libcall NCPBase NCP_LinkRemoteRun c6 09803
  70.  
  71. #endif
  72.  
  73. /*
  74. **    ANSI Prototypes
  75. */
  76.  
  77. #ifndef NO_PROTOS
  78.  
  79. IWORD NCP_IWORD( IWORD inval );
  80. ILONG NCP_ILONG( ILONG inval );
  81. APTR NCP_OpenChannel( STRPTR localname, STRPTR remotename, ULONG flags );
  82. VOID NCP_CloseChannel( APTR ncpchannel );
  83. LONG NCP_Read( APTR ncpchannel, APTR buffer, LONG len );
  84. LONG NCP_BeginRead( APTR ncpchannel, APTR buffer, LONG len );
  85. LONG NCP_CheckRead( APTR ncpchannel );
  86. LONG NCP_WaitRead( APTR ncpchannel );
  87. LONG NCP_AbortRead( APTR ncpchannel );
  88. LONG NCP_Write( APTR ncpchannel, APTR buffer, LONG len );
  89. LONG NCP_BeginWrite( APTR ncpchannel, APTR buffer, LONG len );
  90. LONG NCP_CheckWrite( APTR ncpchannel );
  91. LONG NCP_WaitWrite( APTR ncpchannel );
  92. LONG NCP_AbortWrite( APTR ncpchannel );
  93. IWORD NCP_IWORDP( APTR from, APTR to );
  94. ILONG NCP_ILONGP( APTR from, APTR to );
  95. IWORD NCP_IWORDPI( APTR from );
  96. ILONG NCP_ILONGPI( APTR from );
  97. ULONG NCP_ReadSig( APTR ncpchannel );
  98. ULONG NCP_WriteSig( APTR ncpchannel );
  99. UBYTE NCP_iso2ibm( UBYTE isoch );
  100. UBYTE NCP_ibm2iso( UBYTE ibmch );
  101. void NCP_clnl( STRPTR string );
  102. void NCP_Fault( LONG code, STRPTR header, STRPTR buffer, LONG buffersize );
  103. LONG NCP_LinkRemoteRun( STRPTR remotefilename, STRPTR cmdline, ULONG cmdlinelen );
  104.  
  105. #endif
  106.  
  107. #endif
  108.