home *** CD-ROM | disk | FTP | other *** search
/ Frozen Fish 1: Amiga / FrozenFish-Apr94.iso / bbs / alib / d3xx / d346 / packetsupport.lha / PacketSupport / PacketSupport.doc < prev    next >
Encoding:
Text File  |  1990-04-15  |  1.6 KB  |  53 lines

  1.  
  2.     Packetsupport.lib
  3.     -----------------
  4.  
  5.     This is a tiny little link.lib to support synchronus dos packet
  6.     sending. It is intended to be used with Lettuce C V5.04, but it should
  7.     be simple to port it to any less sophisticated tool :^} Source is
  8.     included.
  9.  
  10.     The routines are loosely based on an very old packet doc I found on
  11.     Fish 6? by Carolyn Scheppner.
  12.  
  13.     Use in whatever you want, on your own risk :^D
  14.  
  15.     no © by Oliver Wagner,
  16.         Landsberge 5,
  17.         4322 Sprockhövel
  18.         West Germany
  19.  
  20.  
  21.     The functions:
  22.  
  23.     sendpacket(struct MsgPort *deviceproc,
  24.            long ACTION_what?,
  25.            long arg1,arg2,...arg7);
  26.  
  27.     Will send a StandardPacket with type ACTION_what? to the device
  28.     process deviceproc (can be obtained by a call to DeviceProc(name))
  29.     with the arg1, arg2 set (you can cut of the number of args) and
  30.     return the dp_Res1 field (or 0 if anything went wrong)
  31.  
  32.  
  33.     getres2()
  34.  
  35.     Will return the dp_Res2 field of last packet send via sendpacket()
  36.  
  37.  
  38.     dosinhibit(char *devicename,
  39.            long what)
  40.  
  41.     Will send the packet ACTION_INHIBIT to the deviceproc of device
  42.     "devicename" (e.g. "DF0:") with dp_Arg1 set to what. Inhibit will
  43.     prevent DOS to access a specified device any longer if what = TRUE.
  44.     If what = FALSE, access will be allowed and DOS will act as if a
  45.     disk has been inserted (can be used to force a DOS diskchange).
  46.  
  47.     Note1: dosinhibit() SHOULD be used before *ANY* low level access to
  48.     a device (e.g. via "trackdisk.device"), otherwise you can severly
  49.     corrupt disk structures...
  50.  
  51.     Note2: "devicename" can also be a volume name or anything like
  52.     that.
  53.