home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Misc / DC-POS24.LZX / pOS / Guide.lzx / Guide / Device / Trackdisk.h < prev    next >
Encoding:
C/C++ Source or Header  |  1997-03-11  |  5.8 KB  |  164 lines

  1. @DATABASE "Device/Trackdisk.h"
  2. @MASTER   "Work2:AD/IInc/Device/Trackdisk.h"
  3. @REMARK   This file was created by ADtoHT 2.0 on 11-Mär-97  13:33:50
  4. @REMARK   Do not edit
  5. @REMARK   ADtoHT is © 1993-1995 Christian Stieber
  6.  
  7. @NODE MAIN "Device/Trackdisk.h"
  8. @TOC "__pOS_Dev.guide/MAIN"
  9.  
  10. @{"Device/Trackdisk.h" LINK File}
  11.  
  12.  
  13. @{b}Structures@{ub}
  14.  
  15. @{"pOS_DriveGeometry" LINK "Device/Trackdisk.h/File" 102}  @{"pOS_TrackdiskIO" LINK "Device/Trackdisk.h/File" 18}
  16.  
  17. @ENDNODE
  18. @NODE File "Device/Trackdisk.h"
  19. #ifndef __INC_POS_DEVICE_TRACKDISK_H
  20. #define __INC_POS_DEVICE_TRACKDISK_H
  21. /*******************************************************************
  22.  Includes Release 24
  23.  (C) Copyright 1995-1997 proDAD
  24.      All Rights Reserved
  25.  
  26.  $AUT Holger Burkarth
  27.  $DAT >>Trackdisk.h<<   23 Dec 1996    13:25:52 - (C) ProDAD
  28. *******************************************************************/
  29. #ifndef __INC_POS_PEXEC_DEVICE_H
  30. #include <@{"pExec/Device.h" LINK "pExec/Device.h/File"}>
  31. #endif
  32.  
  33.  
  34. /*----------------------------------
  35. -----------------------------------*/
  36. struct pOS_TrackdiskIO
  37. {
  38. /* @{"struct pOS_IOStdReq" LINK "pExec/Device.h/File" 66} */
  39.  
  40.   @{"struct pOS_Message" LINK "pExec/MsgPort.h/File" 41}  tdio_Message;
  41.   @{"struct pOS_Device" LINK "pExec/Device.h/File" 21}  *tdio_Device;    /* device node pointer  */
  42.   @{"struct pOS_Unit" LINK "pExec/Device.h/File" 29}    *tdio_Unit;      /* unit (driver private)*/
  43.   @{"UWORD" LINK "pExec/Types.h/File" 93}               tdio_Command;   /* (enum pOS_IOReqCommands) */
  44.   @{"UBYTE" LINK "pExec/Types.h/File" 95}               tdio_Flags;     /* (enum pOS_IOReqFlags) */
  45.   @{"SBYTE" LINK "pExec/Types.h/File" 94}               tdio_Error;     /* (enum pOS_IOReqErrors) */
  46.   @{"ULONG" LINK "pExec/Types.h/File" 91}               tdio_Actual;    /* actual number of bytes transferred */
  47.   @{"ULONG" LINK "pExec/Types.h/File" 91}               tdio_Length;    /* requested number bytes transferred */
  48.   @{"APTR" LINK "pExec/Types.h/File" 87}                tdio_Data;      /* points to data area */
  49.   @{"ULONG" LINK "pExec/Types.h/File" 91}               tdio_HOffset;   /* High - Offset */
  50.   @{"ULONG" LINK "pExec/Types.h/File" 91}               tdio_LOffset;   /* Low - Offset */
  51.   @{"UBYTE" LINK "pExec/Types.h/File" 95}               tdio_Pad[8];
  52.   @{"ULONG" LINK "pExec/Types.h/File" 91}               tdio_Count;     /* Diskchange counter */
  53.   @{"ULONG" LINK "pExec/Types.h/File" 91}               tdio_SecLabel;
  54.  
  55.   @{"UBYTE" LINK "pExec/Types.h/File" 95} tdio_Reserved[32];
  56. };
  57.  
  58.  
  59. enum pOS_TrackdiskIOReqCommands
  60. {
  61.   TDCMDF_ExtCom = 0x8000,
  62.  
  63.   TDCMD_Motor=CMD_NONSTD,
  64.   TDCMD_Seek,
  65.   TDCMD_Format,
  66.   TDCMD_Notify,      /* Notify: Replyed by diskchange */
  67.   TDCMD_ChangeNum,
  68.   TDCMD_ChangeState,
  69.   TDCMD_ProtStatus,
  70.   TDCMD_RawRead,
  71.   TDCMD_RawWrite,
  72.   TDCMD_GetDriveType,
  73.   TDCMD_GetNumTracks,
  74.  
  75.   TDCMD_AddChangeInt, /* (@{"struct pOS_Interrupt" LINK "pExec/Interupt.h/File" 17}*) */
  76.   TDCMD_RemChangeInt, /* NOT AMIGA COMPATIBLE */
  77.  
  78.   TDCMD_GetGeometry,
  79.   TDCMD_Eject,
  80.   TDCMD_LastComm,
  81.  
  82.   TDCMDE_Write    = TDCMDF_ExtCom | CMD_WRITE,
  83.   TDCMDE_Read     = TDCMDF_ExtCom | CMD_READ,
  84.   TDCMDE_Motor    = TDCMDF_ExtCom | TDCMD_Motor,
  85.   TDCMDE_Seek     = TDCMDF_ExtCom | TDCMD_Seek,
  86.   TDCMDE_Format   = TDCMDF_ExtCom | TDCMD_Format,
  87.   TDCMDE_Update   = TDCMDF_ExtCom | CMD_UPDATE,
  88.   TDCMDE_Clear    = TDCMDF_ExtCom | CMD_CLEAR,
  89.   TDCMDE_RawRead  = TDCMDF_ExtCom | TDCMD_RawRead,
  90.   TDCMDE_RawWrite = TDCMDF_ExtCom | TDCMD_RawWrite,
  91.  
  92. };
  93.  
  94.  
  95. enum pOS_TrackdiskIOReqErrors
  96. {
  97.   TDIOERR_NotSpecified=    20, /* general catchall */
  98.   TDIOERR_NoSecHdr=        21, /* couldn't even find a sector */
  99.   TDIOERR_BadSecPreamble=  22, /* sector looked wrong */
  100.   TDIOERR_BadSecID=        23, /* ditto */
  101.   TDIOERR_BadHdrSum=       24, /* header had incorrect checksum */
  102.   TDIOERR_BadSecSum=       25, /* data had incorrect checksum */
  103.   TDIOERR_TooFewSecs=      26, /* couldn't find enough sectors */
  104.   TDIOERR_BadSecHdr=       27, /* another "sector looked wrong" */
  105.   TDIOERR_WriteProt=       28, /* can't write to a protected disk */
  106.   TDIOERR_DiskChanged=     29, /* no disk in the drive */
  107.   TDIOERR_SeekError=       30, /* couldn't find track 0 */
  108.   TDIOERR_NoMem=           31, /* ran out of memory */
  109.   TDIOERR_BadUnitNum=      32, /* asked for a unit > NUMUNITS */
  110.   TDIOERR_BadDriveType=    33, /* not a drive that trackdisk groks */
  111.   TDIOERR_DriveInUse=      34, /* someone else allocated the drive */
  112.   TDIOERR_PostReset=       35, /* user hit reset; awaiting doom */
  113. };
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120. struct pOS_DriveGeometry
  121. {
  122.   @{"ULONG" LINK "pExec/Types.h/File" 91}   dg_SectorSize;    /* in bytes */
  123.   @{"ULONG" LINK "pExec/Types.h/File" 91}   dg_TotalSectors;  /* total # of sectors on drive */
  124.   @{"ULONG" LINK "pExec/Types.h/File" 91}   dg_Cylinders;     /* number of cylinders */
  125.   @{"ULONG" LINK "pExec/Types.h/File" 91}   dg_CylSectors;    /* number of sectors/cylinder */
  126.   @{"ULONG" LINK "pExec/Types.h/File" 91}   dg_Heads;         /* number of surfaces */
  127.   @{"ULONG" LINK "pExec/Types.h/File" 91}   dg_TrackSectors;  /* number of sectors/track */
  128.   @{"ULONG" LINK "pExec/Types.h/File" 91}   dg_BufMemType;    /* preferred buffer memory type */
  129.                             /* (usually MEMF_PUBLIC) */
  130.   @{"UBYTE" LINK "pExec/Types.h/File" 95}   dg_DeviceType;    /* (enum pOS_DriveGeometryType) */
  131.   @{"UBYTE" LINK "pExec/Types.h/File" 95}   dg_Flags;         /* (enum pOS_DriveGeometryType) */
  132.   @{"ULONG" LINK "pExec/Types.h/File" 91}   dg_Reserved[16];
  133. };
  134.  
  135.  
  136.  
  137. enum pOS_DriveGeometryType /** dg_DeviceType **/
  138. {
  139.   DGEOTYP_DirectAccess = 0,
  140.   DGEOTYP_SequentialAccess,
  141.   DGEOTYP_Printer,
  142.   DGEOTYP_Processor,
  143.   DGEOTYP_Worm,
  144.   DGEOTYP_CDRom,
  145.   DGEOTYP_Scanner,
  146.   DGEOTYP_OpticalDisk,
  147.   DGEOTYP_MediumChanger,
  148.   DGEOTYP_Communication,
  149.  
  150.   DGEOTYP_Unknown = 31
  151. };
  152.  
  153.  
  154. enum pOS_DriveGeometryFlags  /** dg_Flags **/
  155. {
  156.   DGEOB_Removable = 0,
  157.  
  158.   DGEOF_Removable = 1,
  159. };
  160.  
  161.  
  162. #endif
  163. @ENDNODE
  164.