Flash storage
The YOS utilizes an effective, fault-proof, fast, flash-erase-write-friendly, fifo-like storage for maintaining nonvolatile logs, parameters, permanent variables etc. The following picture shows an overview about storage usage of various parts of the system:
Parameter storage
There are two locations reserved for storage of the value of all the parameters. Main and backup. User can select which one to use to load/save the values from with arguments provided to the load/save commands. Upon startup, the system always uses the main parameter storage. If the storage consistency is violated, parameter values are not loaded / saved, but initialized with their defeault values.
Permanent variables storage
This storage is used to automatically save/load the values of peramnent variables, to make them appear like non-volatile towards the user. Due to the nature of redundant, fifo-like architecture of the flash storage driver, user can also retrieve the history of the permanent variables (the state at which they were in previous boots). The command 'pmlog' can be used for this purpose.
User storage
User storage allows you to store variables in the device's non-volatile memory. This means that the variables will be saved even after the device is turned off.
Process log
This is a dedicated process loging storage for data sampling service configured through 'plot'
Internal script
This is a dedicated storage for holding an internal script. Once the scrip is installed, it is automatically executed at each full system boot. That way, the device functionality can be arbitrarily extended without the need of relying on external appliances.
Event log
YOS devices are equipped with event logging mechanism. It's used to log important system events. Event log can be viewed by command 'log' without parameters. Log has allocated size for a few hundred text line events. When memory is full, oldest entries are re-written with the newest ones. Event log memory can be found in virtual filesystem in /flash/syslog. When important system event occurs, following entires are usually logged by the utility driver:
- Unsuccesfull start : device did not pass start-up self-diagnostics
- Runtime errors : (overcurrent, overvoltage, undervoltage, over-temperature, some communication errors)
- Number of error
- Number of run
- Number of seconds after start
- Error textual description