|
RTX allows two options for file input and output (I/O). You can write to the supported file I/O functions in the Win32 API or to the supported file I/O functions in the C run-time library. The API delivers low-overhead, fast access to Windows file I/O capabilities using standard APIs. A subset of CreateFile flags are supported with file I/O. Please refer to the Reference Guide for more details. File I/O does not include support for asynchronous file operations.
Because RTSS applications have no current-directory notion, RTSS file I/O requests must use fully qualified path names, such as:
c:\temp\MyFile.txt (for a file system object)
\\.\MyDevice0 (for a device object)
RTSS file I/O calls are made from the Windows kernel environment: RTX actually translates Win32 names such as c:\MyFile.txt and \\.\MyDevice0 to Windows internal names \??\c:\MyFile.txt and \Device\MyDevice0, respectively. You can, therefore, use Windows internal names from your RTSS applications, although such calls fail in Win32. Using an internal Windows name lets you access a device object for which Win32 has no symbolic link, such as \Device\beep or \Device\Harddisk0\Partition1\testfile.txt.
With boot-time file I/O, you may only use paths such as:
\\Device\\Harddisk0\\Partition1\foo.txt
Paths such as this are not supported:
\\??\\C:\\foo.txt and C:\\foo.txt