Svc_Req 57: Logic Driven Write To Nonvolatile Storage; Length Of Data Written; Write Frequency - GE PACSystems RX7i Cpu Programmer's Reference Manual

Hide thumbs Also See for PACSystems RX7i:
Table of Contents

Advertisement

6.33 SVC_REQ 57: Logic Driven Write to Nonvolatile Storage

PACSystems controllers support a 65,500 byte nonvolatile flash memory area that can be accessed
by the logic-driven read/write service requests. Values are stored in the nonvolatile storage area
using SVC_REQ 57. These values are applied to the controller user memory on power up.
SVC_REQ 57 specifies a range of reference addresses to read from a running PACSystems CPU and
write to nonvolatile storage. This feature is intended to retain a limited set of values, such as set
points or tuning parameters that need to change when the PACSystems is running.
This feature uses 65,536 bytes of nonvolatile storage. But not all of this memory is available for the
actual data being written by the service request. Some of the memory is used internally by the
controller to maintain information about the data being stored.
Note: Nonvolatile storage is intended for storing values that do not change frequently. Once the
nonvolatile storage area fills up, a power cycle or STOP Mode Store is required to store more
values. The logic-driven write is not a replacement for battery backed RAM for values that
change frequently or during every sweep. (Refer to When nonvolatile storage is full below.)
6.33.1

Length of Data Written

SVC_REQ 57 scans the nonvolatile storage to find the most recent values stored for the specified
range. If it finds no values for the range or the most recent stored values are different, the new
values are written to nonvolatile storage.
SVC_REQ 57 reports the length of data written in word 8 (starting address + 7) of the parameter
block. The number of words written is calculated from the first word that changed to the end of the
array. For example, if you specify 8 words to be written, but only the values of words 3 and 4 are
changed, the SVC_REQ identifies the first mismatch at word 3 and writes the values of words 3
through 8 (a length of 6 words).
You can write up to 32 words (64 bytes) inclusively per invocation of SVC_REQ 57. Each invocation
requires 4 words of command data (8 bytes). A 1-byte write requires 9 bytes whereas a 64-byte
write requires 72 bytes. You can generally make the most efficient use of nonvolatile storage by
transferring data in 56-byte increments, since this will actually write 64 bytes to the device. Given
the bookkeeping overhead required by the Controller and possible fragmentation, at least 54,912
bytes and no more than 64,000 bytes will be available for the reference data and the 8 bytes of
command data for each invocation. For additional information, refer to Fragmentation below.
6.33.2

Write Frequency

Multiple calls to SVC_REQ 57 in a single sweep may cause CPU watchdog timeouts. The number of
calls to SVC_REQ 57 that can be made requires consideration of many variables: the software
watchdog timeout value, how much data is being written, how long the sweep is, age of nonvolatile
storage (flash), etc. If the application attempts to write to flash too frequently, the CPU could
experience a watchdog timeout while waiting for a preceding write operation to complete.
The Logic Driven Read/Write to Flash service requests are not intended for high frequency use. We
recommend limiting the number of calls to SVC_REQ 57 to one call per sweep to avoid the potential
of for causing a watchdog timeout and the resulting transition to STOP-Halt mode.
GFK-2950C
Chapter 6. Service Request Function
February 2018
335

Advertisement

Table of Contents
loading

This manual is also suitable for:

Pacsystems rx3iPacsystems rsti-ep

Table of Contents