#define WAIT5 5
#define WAIT50 50
#define WAIT100 100
#define WAIT250 250
#define WAIT500 500
#define IFTYP_RAM 0
#define IFTYP_ROM 1
#define IFTYP_STREAM 2
#define IFTYP_NET 3
#define IFTYP_TCPSOCK 4
#define IFTYP_CHAR 5
#define IFTYP_CAN 6
#define IFTYP_BLKIO 7
#define IFTYP_FB 8
#define IFTYP_FS 16
| See: | Type struct _NUTDEVICE |
| struct _NUTDEVICE | |
| { | |
| NUTDEVICE* dev_next; | |
| char dev_name[9]; | |
| uint8_t dev_type; | |
| uintptr_t dev_base; | |
| uint8_t dev_irq; | |
| void* dev_icb; | |
| void* dev_dcb; | |
| int (*dev_init)(NUTDEVICE*); | |
| int (*dev_ioctl)(NUTDEVICE*,int,void*); | |
| int (*dev_read)(NUTFILE*,void*,int); | |
| int (*dev_write)(NUTFILE*,const void*,int); | |
| int (*dev_write_P)(NUTFILE*,const char*,int); | |
| NUTFILE* (*dev_open)(NUTDEVICE*,const char*,int,int); | |
| int (*dev_close)(NUTFILE*); | |
| long (*dev_size)(NUTFILE*); | |
| int (*dev_select)(NUTFILE*,int flags,HANDLE* wq,select_cmd_t cmd); | |
| } |
| See: | Type struct _NUTVIRTUALDEVICE |
| struct _NUTVIRTUALDEVICE | |
| { | |
| NUTVIRTUALDEVICE* vdv_zero; | |
| NUTVIRTUALDEVICE* vdv_next; | |
| uint8_t vdv_type; | |
| int (*vdv_read)(void*,void*,int); | |
| int (*vdv_write)(void*,const void*,int); | |
| int (*vdv_write_P)(void*,const char*,int); | |
| int (*vdv_ioctl)(void*,int,void*); | |
| int (*vdv_select)(void*,int,HANDLE*,select_cmd_t cmd); | |
| } |
| See: | Type struct _IFSTREAM |
| struct _IFSTREAM | |
| { | |
| int (*if_input)(NUTDEVICE*); | |
| int (*if_output)(NUTDEVICE*); | |
| int (*if_flush)(NUTDEVICE*); | |
| volatile uint8_t if_rx_idx; | |
| uint8_t if_rd_idx; | |
| volatile uint8_t if_tx_idx; | |
| uint8_t if_wr_idx; | |
| volatile uint8_t if_tx_act; | |
| uint8_t if_last_eol; | |
| uint8_t if_rx_buf[256]; | |
| uint8_t if_tx_buf[256]; | |
| } |
| Defined in: | nut/os/devreg.c |