File_ReadByte(), Byte
Return value
— The byte read from the open file.
Read a Single Byte from an Open File
This procedure reads a single byte from an open file. To read the n-th byte from the file, you need to call this function in a loop n-1 times before reaching the desired byte.
File_ReadByte()
|
TftSetUp(0, 0) 'Set screen TftResetScreen(BLACK) 'Reset screen TftSetSndFont(0,0) 'Set Font0 While File_Init() <> cErrOK : Wend 'Initialize SD Card TftPrintSndString("Sd Initialization OK",1,0,0,1,GREEN,BLACK,0) 'Confirm Initialize SD Card While File_Open("Open.txt") <> cErrOK : Wend 'Open file Open.txt to edit data TftPrintSndString("Open Open.txt OK",1,0,2,1,GREEN,BLACK,0) 'Confirm Open.txt is open bCounter = 0 'Print position counter Do TftPrintSndChar(File_ReadByte(),1,bCounter,3,1,GREEN,BLACK,0) 'Print data as text If File_EOF() = 1 Then Break 'Loop till end of file Inc bCounter Loop File_Close() 'close file TftPrintSndString("Close Open.txt OK",1,0,4,1,GREEN,BLACK,0) 'Confirm close file |
|
|
Created with the Personal Edition of HelpNDoc: Make the switch to CHM with HelpNDoc's hassle-free WinHelp HLP to CHM conversion tool