SILOS – Save input string, load output string
Block SymbolLicensing group: STANDARD
Function Description
The SILOS block can be used to export or import a string to/from a file. The string is saved when a rising
edge (offon) occurs
at the SAVE input and the string is also set to the sy output. The string is loaded at startup and when a
rising edge (offon)
occurs at the LOAD input.
If the APPEND input is set to on, the string from the input is appended to the end of the file. This mode is suitable for logging events to text files. This entry has no effect on loading from a file.
The LLO parameter is intended for choosing whether to load the entire file (off) or its last line only (on).
The outputs E and lastErr indicate an error during disk operation. The E indicator is reset on falling edge at the SAVE or LOAD input while the lastErr output holds the value until another disk operation is invoked.
Alternatively it is possible to write or read the string continuously if the corresponding flag (CSF, CLF) is set to on. The disk operation is then performed when the corresponding input is set to on. Beware, in that case the disk operation is executed in each cycle, which can cause excessive use of the storage medium. Thus it is necessary to use this feature with caution.
The fname parameter defines the location of the file on the target platform. The path is relative to the data folder of the RexCore runtime module.
This block does not propagate the signal quality. More information can be found in the 1.4 section.
Input
su | String input of the block 0 | String |
SAVE | Save string to file | Bool |
LOAD | Load string from file | Bool |
APPEND | Append saved string to file | Bool |
Parameter
fname | Name of persistent storage file | String |
CSF | Continuous saving | Bool |
CLF | Continuous loading | Bool |
LLO | Last line only loading | Bool |
nmax | Allocated size of string 0 65520 | Long (I32) |
Output
sy | String output of the block | String |
E | Error indicator | Bool |
|
|
|
lastErr | Result of last operation | Long (I32) |
[Previous] [Back to top] [Up]
2024 © REX Controls s.r.o., www.rexygen.com