David Knight / Mbed 2 deprecated lichtspiel

Dependencies:   PololuLedStrip mbed

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers EEPROM.cpp Source File

EEPROM.cpp

00001 #include "EEPROM.h"
00002 
00003 uint8_t EEPROM::eeprom_data[EEPROM_SIZE] = {0};         //initialise to all 0's
00004 
00005 uint8_t EEPROM::read(uint32_t address)
00006 {
00007     if (address < EEPROM_SIZE)
00008         return eeprom_data[address];
00009     
00010     return 0;
00011 }
00012 
00013 void EEPROM::update(uint32_t address, uint8_t value)
00014 {
00015     if (address < EEPROM_SIZE)
00016         eeprom_data[address] = value;
00017 }