home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 3 / PDCD_3.iso / pocketbk / comms / x_sun_psio / code / psion.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-06-20  |  2.4 KB  |  111 lines

  1. /* (C) Tim Graves 20th April 1994
  2.    This code is supplied AS IS. no warrantee either expressed or implied 
  3.    is provided. This code may be freeley modified and modified as long as my
  4.    origional authorship is acknowledged. 
  5.    
  6.    Tim Graves
  7.     Sun Microsystems
  8.      
  9.      */
  10. /* This file containes the defines for the sun end of the psion comms program.
  11.    it should be included in any routines which cann the psion comms lib
  12.    */
  13. #include <sys/types.h>
  14. #include <sys/time.h>
  15. #include <string.h>
  16.  
  17.  
  18. /* debug settings */
  19. /*#define DEBUG 1*/
  20. /* basic constants */
  21. #define TRUE 1
  22. #define FALSE 0
  23.  
  24. /* comparisons */
  25. #define LESSTHAN -1
  26. #define EQUAL 0
  27. #define GREATERTHAN 1
  28.  
  29. /* sizes */
  30. #define MAXARGS 255
  31.  
  32. /* backup and restore stuff */
  33. #define BACKUP 1
  34. #define RESTORE 0
  35.  
  36. /* process operation return codes */
  37. /* process protection */
  38. #define PROCPROTON 1
  39. #define PROCPROTOFF 2
  40. /* process kill return codes */
  41. #define PROCKILLNOPROC -1
  42. #define PROCKILLERRPROC -2
  43.  
  44.  
  45. /* cm function result codes */
  46. #define OK -2
  47. #define BAD -3
  48. #define DISCONN -4
  49. #define BADCMD -5
  50.  
  51. /* parameters for the psisset routine */
  52. #define PATH -1
  53. #define BADPARAM -2
  54.  
  55. /* Returned error values */
  56. /* device string */
  57. #define DEVFILE "/dev/term/a"
  58.  
  59. /* transfer modes */
  60. #define ASCII 1
  61. #define BINARY 2
  62. #define XMDM 3
  63.  
  64. /* suffix for command files */
  65. #define PSCMDSUFFIX ".pscmd"
  66.  
  67. /* constants on ending */
  68. #define QUIT 1
  69. #define PAUSE 2
  70.  
  71. /* interactive or batch ? */
  72. #define INTERACTIVE 1
  73. #define BATCH 2
  74.  
  75. /* defines for variable subsystem variables used */
  76. #define VAR_VERBOSE "verbose"
  77. #define VAR_RMCHECK "rmcheck"
  78. #define VAR_HELPFULL "helpfull"
  79. #define VAR_FILEFILT "autofilefilter"
  80. #define VAR_DOLOWERPATH "dolower"
  81. #define VAR_BACKUPNOCHECK "backupnocheck"
  82. #define VAR_XMDMSENDARGS "xmdmsendargs"
  83. #define VAR_XMDMRECARGS "xmdmrecargs"
  84. #define VAR_XMDMCMD "xmdmcmd"
  85. #define VAR_CHKSUM_WARN "chksumwarn"
  86. #define VAR_CHKSUM_CORRECT "chksumcorrect"
  87. #define VAR_BAD_CHKSUM_SAVE "chksumsave"
  88. #define VAR_BACKUPNODO "backupnodo"
  89. #define VAR_BACKUPASK "backupask"
  90. #define VAR_RESTOREASK "restoreask"
  91. #define VAR_PROCPROC_NO_CHECK "procprotnocheck"
  92. #define VAR_PROCKILL_NO_CHECK "prockillnocheck"
  93.  
  94. /* file responses */
  95. #define PSBADPATH -1
  96.  
  97. /* access types */
  98. #define PSFILERW 1
  99. #define PSFILERO 2
  100.  
  101. /* file types */
  102. #define PSFILEDIR 0x1
  103. #define PSFILETEXT 0x2
  104. #define PSFILEHIDDEN 0x4
  105. #define PSFILESYSTEM 0x8
  106. #define PSFILEVOLUME 0x10
  107. #define PSFILEFILE 0x20
  108.  
  109. /* debug information */
  110. #define MAXDEBUG 10
  111.