R3 Device Signature Error

I have two new Ardunio Uno R3s and they both exhibit the same device signature error as follows:

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.01s

avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
avrdude: Expected signature for ATMEGA328P is 1E 95 14
avrdude: reading input file "grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex"
avrdude: error opening grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex: No such file or directory
avrdude: input file grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex auto detected as invalid format
avrdude: can't open input file grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex: No such file or directory
avrdude: read from file 'grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex' failed

avrdude: safemode: Fuses OK

avrdude done. Thank you.

As you can see, I changed the device signature from 1E 95 0F to 1E 95 14 (for PU chip). The original signature gave the type of error. I am able to run sketches including controlling a stepper motor using easy driver board.

Since I seem to be having a communication problem, I also tried a different usb cable and different modem ports…no luck.

I running a MacBook Pro with Mountain Lion installed. This is the code I'm using:

Arduino/build/macosx/dist/tools/avr/bin/avrdude -C/Users/myusername/Arduino/build/macosx/dist/tools/avr/etc/avrdude.conf -pm328p -cstk500v1 -P/dev/tty.usbmodem411 -D -Uflash:w:grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex -F

I have searched and searched but have found no solution. Help will be greatly appreciated.

Why did you change the Chip ID? Are your Atmegas '328-PU and not '328P-PU dips?

I changed the chip code based on information in the following forum link:

I had the same error message with the original chip code contained in avrdude.conf. as follows:
Reading | ################################################## | 100% 0.01s

avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
avrdude: Expected signature for ATMEGA328P is 1E 95 0F

My chips are 328P-PU. Is there a different code for these chips?

Thanks.

1E 95 0F is correct for your '328P. Does the Arduino IDE upload, say, Blink OK?

Yes, blink works OK. I have also been able to run all three of Brian Schmalz’s stepper motor examples. Today I added a joystick shield and it seems to work OK (position outputs show up the serial monitor). Thanks.

Still no luck with 328P-PU device codes. I tried everything I can of. I ran the Loop-Back test and it checked ok. I have run several sketches with serialWrite and digitalWrite with success. But, every time I try to upload a hex file for my CNC project, I get:

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.01s

avrdude: Device signature = 0x000000
avrdude: Yikes! Invalid device signature.
avrdude: Expected signature for ATMEGA328P is 1E 95 0F

This is the instruction I sending the board via the Mac Terminal.

/Users/myUserName/Ardunio/build/macosx/dist/tools/avr/bin/avrdude -C/Users/ myUserName /Ardunio/build/macosx/dist/tools/avr/etc/avrdude.conf -pm328p -cstk500v1 -P/dev/tty.usbmodem411 -D -Uflash:w:grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex –F

Desperately need help to keep my project going. Thanks.

Regarding the moderator comment "f you are seeing this:
avrdude: Expected signature for ATMEGA328P is 1E 95 0F

Then it looks to me that you do not have a '328P plugged in."

These are two new Unos purchased from amazon.com (different vendors). The chips on both are marked ATMEG328P-PU. Could they be counterfeit or clones? They were in nicely sealed packages and the boards are marked Made in Italy.

Also is there a way to determine the device code of a board? Thanks.

How are you getting code to load in? Are you using an external writer? Looks like you may have over written your bootloader on the 328P.

This is the instruction I am sending the board via the Mac Terminal.

/Users/myUserName/Ardunio/build/macosx/dist/tools/avr/bin/avrdude -C/Users/ myUserName /Ardunio/build/macosx/dist/tools/avr/etc/avrdude.conf -pm328p -cstk500v1 -P/dev/tty.usbmodem411 -D -Uflash:w:grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex –F

That's when I get Yikes!

See if changing -cstk500v1 to -carduino does anything.

Great! That got me past the device error problem. The change produced:

avrdude: Device signature = 0x1e950f
avrdude: reading input file "/Users/raymondjohnson/Arduino/build/macosx/dist/tools/avr/etc/grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex"
avrdude: error opening /Users/raymondjohnson/Arduino/build/macosx/dist/tools/avr/etc/grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex: No such file or directory

I now have some directory/path problems to resolve. Greatly appreciated.

Success at last. I put the hex file in my Ardunio user folder a provided an explicit path in my statement as follows:

/Users/myUserName/Ardunio/build/macosx/dist/tools/avr/bin/avrdude -C/Users/myUserName/Ardunio/build/macosx/dist/tools/avr/etc/avrdude.conf -pm328p -carduino -P/dev/tty.usbmodem411 -D -Uflash:w:/Users/myUserName/Ardunio/grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex

And got:

Writing | ################################################## | 100% 4.26s

avrdude: 23050 bytes of flash written
avrdude: verifying flash memory against /Users/myUserName/Ardunio/grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex:
avrdude: load data flash data from input file /Users/myUserName/Ardunio/grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex:
avrdude: input file /Users/myUserName/Ardunio/grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex auto detected as Intel Hex
avrdude: input file /Users/myUserName/Ardunio/grbl_v0_8b_edge_328p_16mhz_9600_build20121013.hex contains 23050 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 3.32s

avrdude: verifying ...
avrdude: 23050 bytes of flash verified

avrdude: safemode: Fuses OK

avrdude done. Thank you.

I really appreciate the help.