|
|
|
|
|
|
|
||
|
||
|
|
||
May 1999 |
Revision 1.02 |
|
Persistor Instruments Inc. |
© 1998 All rights reserved. |
|
![]()
VEE stands for Virtual EEPROM. It's 7.5KB of persistent storage that can be used to hold small amounts of any kind of binary or text data (usually configuration data) that wants to stay with the CF1 (as opposed to on removable CompactFlash files) and uses named tags to store and fetch this data. The virtual part of the name is in the context of the familiar small serial EEPROM chips that are often associated with little embedded controllers and the EEPROM part is actually electrically erasable read-only memory, albeit two reserved 8KB sectors of the big flash array.
Some examples of usage can help shed light on how and when and where VEE is beneficial:
The VEE can store three types of standard data (longs, floats, and C strings) as well as arbitrary binary data for custom types and structures. Each entry is stored along with a 16 bit CRC, and the entire VEE is verified when PicoDOS initializes. Each fetch of a VEE entry also re-verifies the CRC. VEE lookup is considerable slower than conventional memory accesses, so a wise strategy for frequently accessed data is to fetch it once at the start of your program and keep a local copy in RAM for repeat access.
The SPI examples did not include a serial EEPROM device because the VEE approach is better. PicoDOS efficiently manages the 7.5KB VEE data by minimizing the writes and erases performed on a pair of 8KB flash memory sectors. The missing 512 bytes (x2) is reserved by PBM for controlling the boot process. From your programs, you use API calls like VEEFetch(), VEEStore(), and VEEDelete() to get data into and out of the virtual EEPROM, and from the PicoDOS command shell you can access the VEE data with the DOS-like SET command.
![]()
|
|
|
|
|
|
Tel: 508-759-6434 |
|
Fax: 508-759-6436 |
|
|
||