ImageCraft ICCAVR compile error in eeprom.h

Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

Threaded View
using: ImageCraft IDE v6.31 - ATMega64

One of the standard include files is "eeprom.h", included below.  I am
getting a compile error at the point marked with "#*#*".  As you can see,
this file does not include a test for ATMega64, so EEPROMwrite is not
defined, which I assume is the problem.

I'm getting into a realm that I don't understand.  I need to know if either
of the definitions provided are appropriate for the ATMega64 (can I just add
" || defined(ATMega64) ", or whether I need to create a new definition (or
whether I'm waaaay off track).

Any idea of what additional problems I might run into (even though this
version of ICCAVR is supposed to support the mega64)?

Scott Kelley

** Header file : eeprom.h
#ifdef _AVR
/* AVR EEPROM access functions */
#ifndef __EEPROM__H
#define __EEPROM__H

/* These defines are passed by the IDE as appropriate */
#if defined(ATMega169) || defined(ATMega48) || defined(ATMega88) ||
defined(ATMega168) || defined(ATMega165)
#define EEPROMread EEPROMread_extIO
#define EEPROMwrite EEPROMwrite_extIO
#define EEPROMReadBytes EEPROMReadBytes_extIO
#define EEPROMWriteBytes EEPROMWriteBytes_extIO

#elif defined(ATtiny13) || defined(ATtiny2313) || defined(ATtiny26) ||
defined(AT90S2313) || defined(AT90S2323) || defined(AT90S2333) ||
defined(AT90S2343) || defined(AT90S4414) || defined(AT90S4433) ||

#define EEPROMread EEPROMread_256
#define EEPROMwrite EEPROMwrite_256
#define EEPROMReadBytes EEPROMReadBytes_256
#define EEPROMWriteBytes EEPROMWriteBytes_256

#define _256EEPROMread EEPROMread_256
#define _256EEPROMwrite EEPROMwrite_256

#*#* int EEPROMwrite( int location, unsigned char);
unsigned char EEPROMread( int);

void EEPROMReadBytes(int addr, void *ptr, int size);
void EEPROMWriteBytes(int addr, void *ptr, int size);

#define EEPROM_READ(addr, dst) EEPROMReadBytes(addr, &dst, sizeof (dst))
#define EEPROM_WRITE(addr, src) EEPROMWriteBytes(addr, &src, sizeof (src))


Re: ImageCraft ICCAVR compile error in eeprom.h
Reply sent via email. BTW, we have our own mailing list (see sig in the
email I sent) and you will lots of customers there who can give you
feedback. Of course the best way to contact us is via email support @

Scott Kelley wrote:

Quoted text here. Click to load it

// richard

Site Timeline