fat_io_lib finally works, implement virtual partition devices, manage devices via string keys
All checks were successful
Build documentation / build-and-deploy (push) Successful in 3m35s
All checks were successful
Build documentation / build-and-deploy (push) Successful in 3m35s
This commit is contained in:
19
include/devices.h
Normal file
19
include/devices.h
Normal file
@@ -0,0 +1,19 @@
|
||||
#ifndef _DEVICES_H
|
||||
#define _DEVICES_H
|
||||
|
||||
/* terminal device */
|
||||
#define TERMINAL_PUTSTR 0
|
||||
|
||||
/* keyboard device */
|
||||
#define KB_READ_KEY 0
|
||||
|
||||
/* drive devices */
|
||||
#define XDRV_TYPE_RAMDRV 0
|
||||
#define XDRV_TYPE_PARTDRV 1
|
||||
#define XDRV_GET_SIZE 0
|
||||
#define XDRV_GET_SECTOR_SIZE 1
|
||||
#define XDRV_GET_DEVICE_TYPE 2
|
||||
#define XDRV_READ 3
|
||||
#define XDRV_WRITE 4
|
||||
|
||||
#endif // _DEVICES_H
|
||||
@@ -1,8 +0,0 @@
|
||||
#ifndef _M_KB_DEVICE_H
|
||||
#define _M_KB_DEVICE_H
|
||||
|
||||
#define KB_DEVICE 1
|
||||
|
||||
#define KB_READ_KEY 0
|
||||
|
||||
#endif // _M_KB_DEVICE_H
|
||||
@@ -1,6 +0,0 @@
|
||||
#ifndef _M_RAMDISK_DEVICE_H
|
||||
#define _M_RAMDISK_DEVICE_H
|
||||
|
||||
#define RAMDISK_DEVICE 100
|
||||
|
||||
#endif // _M_RAMDISK_DEVICE_H
|
||||
@@ -18,5 +18,8 @@
|
||||
#define ST_TRY_AGAIN 14
|
||||
#define ST_NOT_DIR 15
|
||||
#define ST_DIR_NO_ENTRIES 16
|
||||
#define ST_FORMAT_ERROR 17
|
||||
#define ST_NOT_DRV 18
|
||||
#define ST_PARTITION_ERROR 19
|
||||
|
||||
#endif // _M_STATUS_H
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
#ifndef _M_TERMINAL_DEVICE_H
|
||||
#define _M_TERMINAL_DEVICE_H
|
||||
|
||||
#define TERMINAL_DEVICE 0
|
||||
|
||||
#define TERMINAL_PUTSTR 0
|
||||
|
||||
#endif // _M_TERMINAL_DEVICE_H
|
||||
@@ -1,11 +0,0 @@
|
||||
#ifndef _M_XDRV_DEVICE_H
|
||||
#define _M_XDRV_DEVICE_H
|
||||
|
||||
#define XDRV_TYPE_RAMDRV 0
|
||||
|
||||
#define XDRV_GET_SIZE 0
|
||||
#define XDRV_GET_SECTOR_SIZE 1
|
||||
#define XDRV_GET_DEVICE_TYPE 2
|
||||
#define XDRV_READ 3
|
||||
|
||||
#endif // _M_XDRV_DEVICE_H
|
||||
Reference in New Issue
Block a user