Go Down

Topic: Invalid signature for m168 chip???? (Read 3671 times) previous topic - next topic

KenH

Hello all, I used AVRdude to burn a bootload using the big-banging described on this page: http://www.geocities.jp/arduino_diecimila/bootloader/index_old_en.html

When reading the m168 (ATmega168) chip avrdude returns

avrdude: Device signature - 0x1e940b
avrdude: expected signature for m168 = 0x1e9406

I use the -F switch to force avrdude to burn the bootloader and it seems ok.  I can load the blink sketch with arduino IDE and it blinks happy.

Why does my m168 give wrong signature?  I've tried two new chips received from Mouser.com a few months back with same results.  Both chips have the "blink" sketch loaded and are blinking happily.

Also, the above referenced webpage says to write the lock bit = 0 0x0f - will that not "lock" my m168?  OR can it be reprogrammed again with HV programming?

Thank ya'll for any help or suggestions.

Ken H>

Coding Badly

Is this printed on the top...

[font=Courier New]ATMEGA168PA-20AU[/font]

KenH

Almost - it has ATmega168P-20PU - no "A" - just the "P"

Is the "P" a problem by itself?

Thanks - different version of chip has different signature?  That's why forcing the burn works?  Is there some info I could change in the avrdude.conf file to make it happy with the "P" version....  "IF" that is the problem.

Thank you for your help,

Ken H>

Coding Badly

Is the "P" a problem by itself?


Not a problem.  I believe the "P" indicates "pico-power" meaning the processor is a good choice for low power applications.  The topic has arisen several times on the forum if you'd like details.  If you cannot find anything relevant, report back and I'll try.

Quote
Thanks - different version of chip has different signature?


In this case, yes.  I don't think that is always the case.

Quote
That's why forcing the burn works?


Yes.

Quote
Is there some info I could change in the avrdude.conf file to make it happy with the "P" version....


The "P" variant may already be in avrdude.conf.  Try "m168p" instead of "m168". 

If that does not work, renaming the ATmega168 section will very likely work.

Or, copying the ATmega168 section and changing the part designator will very likely work.

Other folks have successfully done both of those with the ATmega328 (versus ATmega328P).

Quote
Thank you for your help,


You are welcome.

KenH

I didn't see an edit button - but if this line in the avrdude.conf file was changed:

signature       = 0x1e 0x94 0x06;

That line is from the ATmega168 chip description. I'll bet that means "0x1e9406" which is what avrdude is looking for?

Could a new definition for the ATmega168P chip be written to say "0x1e940b"

Well, I just tried it - I changed "0x1e9406" to "0x1e940b" and avrdude seems to be happy now.  Is that how it's done?  Do I need to change it back?  OR will it be ok to leave both m168 and m168P chip definitions?

Thanks ya'll for the help - and comments.

Ken H>

When tried to post you made your post - Just changing the to "m168p" shouldn't work - it will still read the signature and not be happy since they don't match. 

I think you are correct , the "p" indicates low power version.  When I placed the order (10 of them for price break) I didn't think the "P" would affect anything, but I'll bet the signature is changed - maybe that's all?

Thank you again for the help,

Ken H>

KenH

Oh, I did a search looking for the m168p chip and the only m168 listed was the one m168.  I changed the signature as indicated above and it seems to be working.  I'll also add the original m168 section in for those chips in case I have any of those.  Might as well keep avrdude happy and now have to force anything.

Thank you again.

Ken H>

Go Up