Yahoo Groups archive

AVR-Chat

Index last updated: 2026-04-28 22:41 UTC

Message

reading and writing EEPROM

2004-05-14 by Craig Limber

Hi there;

I am not sure how reading and writing the EEPROM works using avr-libc.
I was wondering if anyone could tell me the correct method of reading
and writing byte 0 of the EEPROM?  I only want to store and recover
3 different bytes of information.

Would this work to write "value" to location 0 of the EEPROM?

eeprom_write_byte((uint8_t *)0, value);

and would this read it back:

value = eepromt_read_byte((uint8_t *)0);

Thanks, eh.

Craig

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.