Description
For variables stored in flash-backed RAM, values must be copied to flash memory with the SAVE command in order to be retained through a power-down or reset. The SAVE command operation can take up to 10 seconds. On power-up/reset, Turbo PMAC2 CPU automatically copies the last saved values for the P and Q-variables from flash memory to the flash-backed locations in main RAM memory. For variables stored in battery-backed RAM, values are automatically retained in the RAM by the battery voltage. No SAVE operation is required. These values are not affected by a SAVE command or a power-up/reset.
Access to battery-backed RAM is significantly slower than access to flash-backed RAM, because either read or write access to the battery-backed RAM requires 2 wait cycles of 9 instruction cycles each, but read or write access to the flash-backed RAM requires 2 wait cycles of only 1 instruction cycle each. Storing P and/or Q-variables in battery-backed RAM frees up flash-backed memory for user program and buffer storage. Storing either P or Q-variables alone in battery-backed RAM allots 8K additional words for user storage, on top of the standard 26K words (212K with the optional expanded user memory), for a total of 34K words (optionally 220K); storing both P and Qvariables in battery backed RAM allots 16K additional words, for a total of 42K words (optionally 228K).