Home |
The ISO 9660 File System Structure The exFAT File System Structure RTFiles-32 in Embedded Applications Optimizing for Best Throughput Optimizing for Best Data Security Using RTFiles-32 with RTTarget-32 Win32 API Emulation with RTTarget-32 Using RTFiles-32 with RTKernel-32 |
Win32 API Emulation with RTTarget-32When RTFiles-32 is used with RTTarget-32, about 30 Win32 file I/O functions are emulated by RTFiles-32. RTTarget-32 supports installable file systems and several file systems can be active at the same time. When RTTarget-32 is used without RTFiles-32, it will by default use its file system for consoles, LPTs, and RAM files. RTFiles-32, however, replaces RTTarget-32's default configuration to use console files, LPT files, and RTFiles-32's file system, but not RAM files. Here is the RTTarget-32 file I/O configuration used by RTFiles-32: #include <Rttarget.h> #include <Rtfiles.h> static RTFileSystem Console = { RT_FS_CONSOLE, 0, 0, &RTConsoleFileSystem }; static RTFileSystem LPTFiles = { RT_FS_LPT_DEVICE, 0, 0, &RTLPTFileSystem }; static RTFileSystem FATFiles = { RT_FS_FILE | RT_FS_IS_DEFAULT, 0x7FFFFFFF, 0x00000FFF, &RTFilesFileSystem }; RTFileSystem * RTFileSystemList[] = { &Console, &LPTFiles, &FATFiles, NULL }; If, for example, you want to retain RTTarget-32's RAM files but exclude the LPT file system, you could include the following configuration in your program: #include <Rttarget.h> #include <Rtfiles.h> RTFileSystem Console = { RT_FS_CONSOLE, 0, 0, &RTConsoleFileSystem }; RTFileSystem RAMFiles = { RT_FS_FILE, 1 << ('R'-'A'), 0, &RTRAMFileSystem }; RTFileSystem FATFiles = { RT_FS_FILE | RT_FS_IS_DEFAULT, 0x0F, 0x03, &RTFilesFileSystem }; RTFileSystem * RTFileSystemList[] = { &Console, &RAMFiles, &FATFiles, (void*) 0 } ; With this configuration, logical drive 'R' can be used to access the RTTarget-32 RAM files. Logical drives 'A' through 'D' are reserved for RTFiles-32. For additional information about RTTarget-32's installable file systems, please refer to the RTTarget-32 Programming Manual. Using RTFiles-32 with RTTarget-32 Using RTFiles-32 with RTKernel-32
|