)rawliteral";
NVR[0] - NVR[7]
Non-volatile memory. Unlike the STR[x]$ command, it does not damage the flash memory.
n: number of stored variables (0-7)
No RTC: stores a total of 256-(n+1) characters, forgets when power is lost, but not on reset.
DS1302: stores a total of 31-(n+1) characters, does not forget when power is lost thanks to the battery on the RTC module.
DS1307: stores a total of 56-(n+1) characters, does not forget when power is lost thanks to the battery on the RTC module.
STR[0]=important
NVR[0]=Stored Variable
NVR[0]=STR[0]
Stores the variable in non-volatile memory.
NVR[0]@
Sends the stored variable to STDOUT.
Examples
Adjusts the brightness of the built-in LED with buttons, turns on with the last value after a power outage.
Works properly in the boot.txt file.
GPIO[D6]INPR|
GPIO[D6]CL:NUM[0]@+1|
GPIO[D7]INPR|
GPIO[D7]CL:NUM[0]@-1|
GPIO[D]PR=15|
GPIO[D]IR=100|
NUM[0]VL=0|
NUM[0]VH=15|
NUM[0]CC:NVR[0]=NUM[0];GPIO[D4]PI=NVR[0]|
NUM[0]=NVR[0]|
GPIO[D4]PI=NVR[0]