2.9
EEPROM Read/Write Functions
There is a 16K-byte EEPROM in the main control unit in the PAC system.
This EEPROM is divided into 256 blocks (0 to 255), and each block is 64 bytes in
length from offset 0 to 63. This EEPROM with its accessing APIs provides
another mechanism for storing critical data inside non-volatile memory.
2.9.1 ReadEEP
Description:
This function is used to Read one byte data from EEPROM.
Syntax:
++
[C
]
unsigned char ReadEEP(int
Parameter:
block: [Input] the block number of EEPROM.
offset: [Input] the offset within the block.
Return Value:
Data read from the EEPROM.
Example:
int
block, offset;
unsigned char
data;
data= ReadEEP(block, offset);
//Returned value: data= read an 8-bit value from the EEPROM (block & offset)
Remark:
http://www.icpdas.com
block,
int
offset);
MP-8x43 Function Reference V 1.0
74