SW500008 Microchip Technology, SW500008 Datasheet - Page 209

PICC-18 STD

SW500008

Manufacturer Part Number
SW500008
Description
PICC-18 STD
Manufacturer
Microchip Technology
Type
Compilerr
Series
PIC18r
Datasheets

Specifications of SW500008

Supported Families
PIC18
Core Architecture
PIC
Software Edition
Standard
Kit Contents
Software And Docs
Mcu Supported Families
PIC18
Tool Function
Compiler
Tool Type
Compiler
Lead Free Status / RoHS Status
Not applicable / RoHS Compliant
For Use With/related Products
PIC18 Series
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
Other names
015
778-1001
778-1001
Library Functions
EEPROM_READ, EEPROM_WRITE
Synopsis
Description
These functions allow access to the on-chip eeprom (when present). The eeprom is not in the
directly-accessible memory space and a special byte sequence is loaded to the eeprom control regis-
ters to access this memory. Writing a value to the eeprom is a slow process and the eeprom_write()
function polls the appropriate registers to ensure that any previous writes have completed before
writing the next datum.
completion.
Example
See Also
flash_erase, flash_read, flash_write
Reading data is completed in the one cycle and no polling is necessary to check for a read
#include <htc.h>
unsigned char eeprom_read (unsigned int address);
void eeprom_write (unsigned int address, unsigned char value);
#include <htc.h>
void
main (void)
{
}
unsigned char data;
unsigned int address = 0x0010;
data=eeprom_read(address);
eeprom_write(address, data);
195

Related parts for SW500008