Copyright © Neoway Technology Co., Ltd
17.2 Reading Data from File: FSRF
AT+FSRF=<file_name>,<mode>,<size>[,<position>]<CR>
<file_name>: File name, at most 50 characters
<mode>: mode
0: Read data from the beginning of the file.
1: Read data from the <position> of the file.
<size>: data size, not exceed the size of the file, 0 is valid
<position>: the position in the file, where data to be read starts, valid when <mode>
is set to 1, 0 is invalid
AT+FSRF="test.txt",0,10
+FSRF: 10,start01234
OK
Read 10-byte data from the beginning
of the test.txt file.
AT+FSRF="test.txt",0,0
+FSRF: 0,
OK
Read 0-byte data from the beginning
of the test.txt file.
AT+FSRF="test.txt",0,1025
ERROR
ERROR is returned because <size>
exceeds the file size.
AT+FSRF="test.txt",1,20,2
+FSRF: 20,tart0123456789012345
OK
Read 20-byte data from the second
byte of the test.txt file.
The data is read successfully.
AT+FSRF="test.txt",1,0,2
+FSRF: 0,
OK
Read 0-byte data from the second
byte of the test.txt file.
AT+FSRF="test.txt",1,10,0
ERROR
ERROR is returned because the set
value exceeds the parameter range.
The data to be read should not exceed the size of the file.
<size> and <position> is determined by the file size.