OpenCores
URL https://opencores.org/ocsvn/gecko3/gecko3/trunk

Subversion Repositories gecko3

[/] [gecko3/] [trunk/] [GECKO3COM/] [gecko3com-fw/] [firmware/] [src/] [eeprom_io.c] - Diff between revs 9 and 32

Show entire file | Details | Blame | View Log

Rev 9 Rev 32
Line 34... Line 34...
#include "eeprom_io.h"
#include "eeprom_io.h"
#include "i2c.h"
#include "i2c.h"
#include "delay.h"
#include "delay.h"
#include "debugprint.h"
#include "debugprint.h"
 
 
#define EEPROM_HIGH_ADDR 0x3FFF
#define EEPROM_HIGH_ADDR 0x3FFF /**< highest available addres, length */
#define PAGE_LEN  0x40
#define PAGE_LEN  0x40          /**< lenght of a memory page */
 
/** bit mask to get the corresponding page start adress */
#define PAGE_START_MASK 0xFFC0
#define PAGE_START_MASK 0xFFC0
 
/** bit mask to select the adress inside a memory page */
#define PAGE_MASK 0x003F
#define PAGE_MASK 0x003F
 
 
 
 
/* returns non-zero if successful, else 0 */
/* returns non-zero if successful, else 0 */
uint8_t eeprom_read (uint16_t eeprom_offset, xdata uint8_t *buf, uint8_t len)
uint8_t eeprom_read (uint16_t eeprom_offset, xdata uint8_t *buf, uint8_t len)

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.