Not getting any help on the Arduino forum so I wll ask here.
I have this as an include file,
#include <EEPROM.h>
#include <WProgram.h>
// Functions to read/write lots of data from EEPROM
template <class T> int EEPROM_writeAnything(int ee, const T& value)
{
const byte* p = (const byte*)(const void*)&value;
int i;
for (i = 0; i < sizeof(value); i++)
EEPROM.write(ee++, *p++);
return i;
}
template <class T> int EEPROM_readAnything(int ee, T& value)
{
byte* p = (byte*)(void*)&value;
int i;
for (i = 0; i < sizeof(value); i++)
*p++ = EEPROM.read(ee++);
return i;
}
Under Arduino 0022 it compiles with my program just fine. With Arduino 1.0 I get this error
"expected initializer before '*' token
I'm not real good with C