Fixed compatibility of output.
[AROS.git] / arch / m68k-amiga / devs / trackdisk / trackdisk_device.h
blob320391f7897d1af1e6f07deceeaaf66c5f18e2b5
1 /*
2 Copyright © 1995-2007, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Internal defs for trackdisk
6 Lang: English
7 */
8 #ifndef TRACKDISK_DEVICE_H
9 #define TRACKDISK_DEVICE_H
11 #include <exec/types.h>
12 #include <exec/devices.h>
13 #include <exec/semaphores.h>
14 #include <exec/interrupts.h>
15 #include <exec/tasks.h>
17 #include <devices/trackdisk.h>
18 #include <resources/disk.h>
20 /* Stack size - 4096 longwords should be enough */
21 #define STACK_SIZE 16384
23 /* Maximum number of units */
24 #define TD_NUMUNITS 4
26 /* something */
27 #define TDUF_WRITE (1<<0)
29 #define TDU_NODISK 0x00
30 #define TDU_DISK 0x01
32 #define TDU_READONLY 0x01
33 #define TDU_WRITABLE 0x00
35 #define DT_UNDETECTED 0
36 #define DT_ADOS 1
37 #define DT_PCDOS 2
39 struct TDU
41 struct TDU_PublicUnit pub;
42 struct List tdu_Listeners;
43 UBYTE tdu_UnitNum; /* Unit number */
44 UBYTE tdu_DiskIn; /* Disk in drive? */
45 UBYTE tdu_MotorOn; /* Motor on? */
46 UBYTE tdu_ProtStatus;
47 UBYTE tdu_flags;
48 BOOL tdu_hddisk; /* HD disk inserted */
49 BOOL tdu_broken; /* recalibrate didn't find TRACK0, drive ignored */
50 UBYTE tdu_sectors; /* number of sectors per track */
51 BOOL tdu_selected;
52 UBYTE tdu_disktype;
55 struct TrackDiskBase
57 struct Device td_device;
58 struct TaskData *td_TaskData;
59 struct TDU *td_Units[TD_NUMUNITS];
60 struct timerequest *td_TimerIO;
61 struct timerequest *td_TimerIO2;
62 struct MsgPort *td_TimerMP;
63 struct MsgPort *td_TimerMP2;
64 struct DiskBase *td_DiskBase;
65 struct DiscResourceUnit td_dru;
66 struct MsgPort td_druport;
67 struct MsgPort td_Port; // MessagePort
68 struct Task *td_task;
69 APTR td_DMABuffer; /* Buffer for DMA accesses */
70 UBYTE *td_DataBuffer;
71 ULONG td_sectorbits;
72 volatile struct Custom *custom;
73 volatile struct CIA *ciaa;
74 volatile struct CIA *ciab;
75 ULONG td_IntBit;
76 BOOL td_nomount;
77 BOOL td_supportHD;
78 WORD td_buffer_track;
79 BYTE td_buffer_unit; /* buffer contains this unit's track */
80 UBYTE td_lastdir; /* last step direction */
81 BOOL td_dirty;
82 UWORD *crc_table16; /* PCDOS checksum table */
85 #endif /* TRACKDISK_DEVICE_H */