Question: What is the advanatge / disadvantage on using NVRAM - UPS(uninterruptable power supply )
The technical difference is:
NVRAM is a mapped area in which on each cycle the retain variable are updated
In case of using a UPS - this is the ram area and on shutdown of the runtime the runtime write the retain files (restore them on startup)
The result on this:
With nvram you have only a limited amount of retains for example 128k if the retain memory has this size.
With UPS there is not limit in size (sure your ram but this is nowadays not really a limit)
nvram: The cpu load (cycle time grow) could grow with increasing nvram occupancy, since this will lead to cyclic read and write access to this memory, for each used variable one access.
(Hint if you are using many retain variable with nvram:
Declare a structure which mirrors the retains data and copy the whole struct in the cycle, this is then only one access as oposed to many memory access if you have a bunch of single retain variables - this you should see immediately in the cycle time load)Back to FAQ overview