(updated) based on comments. I am trying to dump the Uno (Uno and R3) EEPROM using avrdude tool. I am able to download the EEPROM but the data is "garbage"
I wrote a quick program to test. I load the EEPROM with 0,1,2,3,4
(using INO Serial from command line) Terminal ready
0 0
1 1
2 2
once I download the EEPROM
[path]avrdude -c avrdude.conf -p atmega328p -c arduino -P /dev/cu.usbmodemfd121 -b 115200 -u -U eeprom:r:eeprom.hex:i
I get the following (eeprom.hex)
:200000000C9435000C945D000C945D000C945D000C945D000C945D000C945D000C945D0020
No 0,1,2,3,4 to be found.
I try the same on a Nano, and it works fine.
Help?
thank you
(complete commands)
540 rm eeprom.hex
541 head eeprom.hex
542 /Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/bin/avrdude -C /Applications/Arduino.app/Contents/Resources/Java/hardware/tools/avr/etc/avrdude.conf -p atmega328p -c arduino -P /dev/cu.usbmodemfd121 -b 115200 -u -U eeprom:r:eeprom.hex:i
543 vi eeprom.hex
544 cat eeprom.hex
----- - ------------ UPDATE --------------------------
Sketch - Loaded to Uno and Uno R3 - both can't download EEPROM from AVRDUDE. The Mac and Raspi are both connected via USB to Arduino UNO R3 producing similar results (I can't say identical data, but they look identical). Raspi is running Arduino 1.0.5 environment. Mac is running 1.05.
/*
- EEPROM Read
- Reads the value of each byte of the EEPROM and prints it
- to the computer.
- This example code is in the public domain.
*/
#include <EEPROM.h>
// start reading from the first byte (address 0) of the EEPROM
int address = 0;
byte value;
void setup()
{
// initialize serial and wait for port to open:
Serial.begin(9600);
while (!Serial) {
; // wait for serial port to connect. Needed for Leonardo only
}
}
void loop()
{
// read a byte from the current address of the EEPROM
value = EEPROM.read(address);
Serial.print(address);
Serial.print("\t");
Serial.print(value, HEX);
Serial.println();
EEPROM.write(address+1,address+1);
// advance to the next address of the EEPROM
address = address + 1;
// there are only 512 bytes of EEPROM, from 0 to 511, so if we're
// on address 512, wrap around to address 0
if (address == E2END)
address = 0;
EEPROM.write(address,address);
delay(500);
}
bash-3.2$ ino serial
Searching for Serial monitor (picocom) ... /opt/local/bin/picocom
Guessing serial port ... /dev/tty.usbmodemfd121
picocom v1.6
port is : /dev/tty.usbmodemfd121
flowcontrol : none
baudrate is : 9600
parity is : none
databits are : 8
escape is : C-a
local echo is : no
noinit is : no
noreset is : no
nolock is : yes
send_cmd is : sz -vv
receive_cmd is : rz -vv
imap is :
omap is :
emap is : crcrlf,delbs,
Terminal ready
0 0
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
9 9
10 A
11 B
12 C
13 D
14 E
Thanks for using picocom
ava/hardware/tools/avr/etc/avrdude.conf -p atmega328p -c arduino -P /dev/cu.usbmodemfd121 -b 115200 -u -U eeprom:r:eeprom.hex:i
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.00s
avrdude: Device signature = 0x1e950f
avrdude: reading eeprom memory:
Reading | ################################################## | 100% 2.11s
avrdude: writing output file "eeprom.hex"
avrdude done. Thank you.
bash-3.2$ head eeprom.hex
:200000000C9435000C945D000C945D000C945D000C945D000C945D000C945D000C945D0020
:200020000C945D000C945D000C945D000C945D000C945D000C945D000C945D000C945D00D8
:200040000C94D3000C945D000C94B0010C94FE010C945D000C945D000C945D000C945D004C
:200060000C945D000C945D006C0311241FBECFEFD8E0DEBFCDBF11E0A0E0B1E0E6EBFAE0B9
:2000800002C005900D92A231B107D9F711E0A2E1B1E001C01D92A93CB107E1F710E0CAE685
:2000A000D0E004C02297FE010E945505C836D107C9F70E94C2030C9459050C94000060918C
:2000C00012017091130185E191E00E94C00080931401609112017091130187EA91E04AE072
:2000E00050E00E94FC0487EA91E060E071E00E940F0587EA91E06091140140E150E00E942A
:20010000AA0487EA91E00E94FB036091120170911301462F4F5F85E191E06F5F7F4F0E945E
:20012000C7008091120190911301019690931301809312018F5F934021F41092130110927D