x68000:writing_drivers
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
x68000:writing_drivers [2014/07/11 00:56] – eidis | x68000:writing_drivers [2014/07/11 01:03] – [0x04 - Input (read)] eidis | ||
---|---|---|---|
Line 47: | Line 47: | ||
* __next header__ (long) : A single .SYS or .X file may contains more than one drivers, so this a pointer to the next driver header within this file. Set this member to -1 (0xFFFFFFFF) if this driver entry is the last one in the chain. | * __next header__ (long) : A single .SYS or .X file may contains more than one drivers, so this a pointer to the next driver header within this file. Set this member to -1 (0xFFFFFFFF) if this driver entry is the last one in the chain. | ||
- | |||
* __attributes__ (word): This 16 bits (1 word) member are flags that give informations about the driver behavior. Valid flags are : | * __attributes__ (word): This 16 bits (1 word) member are flags that give informations about the driver behavior. Valid flags are : | ||
* 0x8000 : Character device driver (any driver that' | * 0x8000 : Character device driver (any driver that' | ||
Line 58: | Line 57: | ||
* 0x0002 : STDOUT device. The driver will redefine the stdout, for example : screen, serial output, printers, | * 0x0002 : STDOUT device. The driver will redefine the stdout, for example : screen, serial output, printers, | ||
* 0x0001 : STDIN device. The driver will redefine the stdin : keyboard or serial input. | * 0x0001 : STDIN device. The driver will redefine the stdin : keyboard or serial input. | ||
- | |||
* __strategy routine (long)__: A pointer to the very first routine the kernel will execute ! This will initiate the driver loading. | * __strategy routine (long)__: A pointer to the very first routine the kernel will execute ! This will initiate the driver loading. | ||
- | |||
* __interrupt routine (long)__: A pointer to a routine that will perform the communication between the kernel and the device. | * __interrupt routine (long)__: A pointer to a routine that will perform the communication between the kernel and the device. | ||
- | |||
* __driver name (8 chars)__: An unique identifier, also used by userspace application when executing IOCTL commands. | * __driver name (8 chars)__: An unique identifier, also used by userspace application when executing IOCTL commands. | ||
Line 91: | Line 87: | ||
**Command execution result flags :** | **Command execution result flags :** | ||
- | This list contains all acceptable values to fill the result status flags in the request packet header. S_**** flags will display (or hide) the " | + | This list contains all acceptable values to fill the result status flags in the request packet header. S_**** flags will display (or hide) the " |
+ | |||
+ | " | ||
* 0x1000 - S_ABORT : " | * 0x1000 - S_ABORT : " | ||
Line 157: | Line 155: | ||
- | Output parameters : | + | **Output parameters :** |
^ Position | ^ Position | ||
Line 222: | Line 220: | ||
^ Position | ^ Position | ||
- | | 14 | Long | Pointer to a buffer that' | + | | 14 | Long |Pointer to a buffer that' |
- | | 18 | Long | Buffer size | | + | | 18 | Long |Buffer size | |
**Output parameters :** none | **Output parameters :** none | ||
Line 229: | Line 227: | ||
===== 0x04 - Input (read) ===== | ===== 0x04 - Input (read) ===== | ||
- | Command ID : 0x04 (C_INPUT) | + | **Command ID :** 0x04 (C_INPUT) |
**Availability :** Block/ | **Availability :** Block/ | ||
Line 240: | Line 238: | ||
| 13 | Byte |Block device driver only. Media type. | | | 13 | Byte |Block device driver only. Media type. | | ||
| 14 | Long |Pointer to a buffer that' | | 14 | Long |Pointer to a buffer that' | ||
- | | 18 | Long |Block device driver : number of sector to read. A sector length is normally specified by the BPB. | + | | 18 | Long |Block device driver : number of sector to read. A sector length is normally specified by the BPB. | |
- | Character device driver : Buffer size. | | + | |||Character device driver : Buffer size. | |
| 22 | Long |Block device driver only : logical start sector to read from. | | | 22 | Long |Block device driver only : logical start sector to read from. | | ||
x68000/writing_drivers.txt · Last modified: 2019/08/27 20:45 by 127.0.0.1