45 #define FILE_OK STM_OK 50 #define FILE_ERROR STM_TIMEOUT 55 #define FILE_EOF STM_RESET 66 #define _file_stream_methods \ 67 _base_sequential_stream_methods \ 69 msg_t (*close)(void *instance); \ 71 msg_t (*geterror)(void *instance); \ 73 msg_t (*getsize)(void *instance); \ 75 msg_t (*getposition)(void *instance); \ 77 msg_t (*lseek)(void *instance, fileoffset_t offset); 84 #define _file_stream_data \ 85 _base_sequential_stream_data 126 #define fileStreamWrite(ip, bp, n) streamWrite(ip, bp, n) 142 #define fileStreamRead(ip, bp, n) streamRead(ip, bp, n) 159 #define fileStreamPut(ip, b) streamPut(ip, b) 174 #define fileStreamGet(ip) streamGet(ip) 187 #define fileStreamClose(ip) ((ip)->vmt->close(ip)) 198 #define fileStreamGetError(ip) ((ip)->vmt->geterror(ip)) 209 #define fileStreamGetSize(ip) ((ip)->vmt->getsize(ip)) 220 #define fileStreamGetPosition(ip) ((ip)->vmt->getposition(ip)) 233 #define fileStreamSeek(ip, offset) ((ip)->vmt->lseek(ip, offset)) uint32_t fileoffset_t
File offset type.
FileStream virtual methods table.
#define _file_stream_data
FileStream specific data.
const struct FileStreamVMT * vmt
Virtual Methods Table.
#define _file_stream_methods
FileStream specific methods.