Eralt / arduino

Automatically exported from code.google.com/p/arduino
0 stars 0 forks source link

EEPROM class doesn't work on Mega 2560. #381

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Try running one of the EEPROM examples: 
http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1287507497

What is the expected output? What do you see instead?

In file included from C:\arduino-0021\libraries\EEPROM\EEPROM.cpp:24:
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h: In 
function 'void eeprom_read_block(void*, const void*, size_t)':
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h:290: 
error: ISO C++ forbids incrementing a pointer of type 'void*'
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h:290: 
error: ISO C++ forbids incrementing a pointer of type 'const void*'
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h:290: 
error: invalid conversion from 'const void*' to 'const uint8_t*'
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h:290: 
error:   initializing argument 1 of 'uint8_t eeprom_read_byte(const uint8_t*)'
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h: In 
function 'void eeprom_write_block(const void*, void*, size_t)':
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h:398: 
error: ISO C++ forbids incrementing a pointer of type 'void*'
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h:398: 
error: ISO C++ forbids incrementing a pointer of type 'const void*'
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h:398: 
error: invalid conversion from 'void*' to 'uint8_t*'
c:/arduino-0021/hardware/tools/avr/lib/gcc/../../avr/include/avr/eeprom.h:398: 
error:   initializing argument 1 of 'void eeprom_write_byte(uint8_t*, uint8_t)'
C:\arduino-0021\libraries\EEPROM\EEPROM.cpp: At global scope:
C:\arduino-0021\libraries\EEPROM\EEPROM.cpp:40: error: 'EEPROMClass' has not 
been declared
C:\arduino-0021\libraries\EEPROM\EEPROM.cpp:45: error: 'EEPROMClass' has not 
been declared
C:\arduino-0021\libraries\EEPROM\EEPROM.cpp:50: error: 'EEPROMClass' does not 
name a type

Original issue reported on code.google.com by dmel...@gmail.com on 19 Oct 2010 at 5:02

GoogleCodeExporter commented 9 years ago
Download this new version of the eeprom.h file:
http://www.cbxdragbike.com/arduino/new/

Original comment by mark.biz...@gmail.com on 30 Nov 2010 at 2:27

GoogleCodeExporter commented 9 years ago
https://github.com/arduino/Arduino/commit/867dee824514020f70afda81db4983bcc0bf49
6d
https://github.com/arduino/Arduino/commit/544cfafb36f2e73f49d29b11d78513c62b62c6
95

Using Mark Sproul's patched eeprom.h.

Original comment by dmel...@gmail.com on 24 Dec 2010 at 12:31

GoogleCodeExporter commented 9 years ago
This seems to have cropped back up on Windows.  We might have lost the part of 
the ant build.xml script that grabs the custom eeprom.h for Windows.

Original comment by dmel...@gmail.com on 15 Jun 2012 at 1:05

GoogleCodeExporter commented 9 years ago
Never mind, this still to still be fine on Windows...  I think there's 
something else going on with the user who's having trouble: 
http://arduino.cc/forum/index.php/topic,109989.0.html

Original comment by dmel...@gmail.com on 15 Jun 2012 at 3:08

GoogleCodeExporter commented 9 years ago
A very important function like save persistent data doesn't work!
You put the fix in a external website : who is this...how should I trust.
It's very poor and NOT PROFESSIONAL!

Original comment by ideedil...@tiscali.it on 30 Apr 2014 at 9:41