SPLat Logo

HMI430/700: NVEM1 (Read/Write)

NOTICE: SPLat Controls has moved. We are now at 1/85 Brunel Rd, Seaford, 3198. map

HMI430/700: NVEM1 (Read/Write)

NVEM Page 1 is both readable and writable.  It has 3968 bytes of storage space and a typical write endurance of 500,000 cycles per individual byte.  There's no limit on the number of times you can read from it.  The system is smart enough to know if a write is writing the same data and will avoid performing a write in such cases.

NVEM1 cannot be written to by SPLat/PC, so you can't have an preloaded data in your source code like NVEM0.  It can only be written to by your running application.  Hence it is most useful for storing configuration information, or for logging a small amount of data.

Loading a new application into the HMI430 will not erase anything you've stored in NVEM1.  There's no automatic way to know if you have already written something to NVEM1, so be sure to implement some sort of checksum or flag.

At power on, when your application starts, NVEM defaults to page 0.  Therefore to access NVEM1 you must call the NVSetPage instruction.

For example, store the number 42 in NVEM1 @ address 10:


NVSetPage 1 ;ensure we're using NVEM1
NVSetPtr 0 ;set the ptr to start of NVEM1
NVSetRecLen 0 ;not using records
NVSetRecNum 0 ;not using records
LoadX 42 ;the number we're going to write
NVPopByte 10 ;write the byte to location 10


Here is a full list of NVEM instructions.