User`s guide
Chapter
5
BASIC
Commands
161
Remarks
"A%" is an integer variable to be assigned to the result.
Value Meaning
1
-1
-2
-3
-4
Write flash memory successfully.
The BASIC program is too large; no free flash memory available.
Error command for erasing the flash memory.
The given index is out of the range.
Fail to write (probably flash memory is not erased yet or something
goes wrong).
"N%" is an integer variable in the range of 1 to 256, indicating the ordinal number
of the record.
"A$" is a string variable, representing the data string to be saved to the flash
memory.
Before writing any data to the flash memory, it is necessary to use the following
command to erase the flash memory first:
err% = FLASH_WRITE(0,"ERASE")
Note that the index must be 0, and the string must be "ERASE". After erasing the
flash memory, you can then write data to it by one record at a time. However, when
you need to write data to any used index number, the whole flash memory needs to
be erased again; otherwise, the write command will fail.
Example
err% = FLASH_WRITE(1, "data number#1)
...
err% = FLASH_WRITE(256, "data number#256)
See Also
FLASH_READ$
FREE_MEMORY
Purpose
To get the size of free data memory (SRAM) in bytes.
Syntax
A& = FREE_MEMORY
Remarks
"A&" is a long integer variable to be assigned to the result.
Example
PRINT "Free memory = ", FREE_MEMORY
See Also
RAM_SIZE, ROM_SIZE