1

I have an ATMega168 that I am programming via my Arduino Uno as ISP. I can burn the bootloader and transfer a hex file just fine, but I can't seem to be able to change the fuse bits. I found a lot of people having similar problems, but most still weren't resolved after many years or can't connect to their chip at all.

A weird thing I notice is that my ATMega is recognized as an 328p all the time. I know they're practically identical, but nothing works when I change settings to an 168, I always have to set it to 328p. Avrdude tells me the signature is wrong, whenever I try it with 168. Might that already be an indicator for something being wrong!? I ordered a 168 and it's printed on the chip, so it should be an actual 168.

Furthermore I noticed that I can only use the Baud rate of 115200, but I read that only 19200 should be correct and when I use that I get no response as well.

This is the command I'm trying to use:

avrdude -Cavrdude.conf -patmega328p -PCOM3 -carduino -b115200 -U efuse:w:0x00:m -U hfuse:w:0xDD:m -U lfuse:w:0xFF:m

And the response I get is:

avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0x0000
         0x00 != 0xdd
avrdude: verification error; content mismatch

I tried different software and different USB cables, to no avail.

If anyone could provide any direction I can try and look for a solution or mistakes I might have made, I'd be really grateful!

1 Answer 1

2

I got an answer on another forum. I was missing a 10μF capacitor between the Ground and Reset of the Arduino. Not a single documentation, image or video I saw mentioned that. Everything works fine now.

6
  • 2
    so you could burn the bootloader without the capacitor, but not set fuses?
    – Juraj
    Nov 30, 2021 at 7:35
  • 2
    This official doc mentions the capacitor in the text. Though it is not very clear and is not shown in the wiring diagrams. The official Arduino docs are often not that good
    – chrisl
    Nov 30, 2021 at 20:26
  • @Juraj It seems that I was addressing the ATMega328p on the Arduino itself the whole time so I probably uploaded everything to that instead of the 168. Dec 1, 2021 at 9:58
  • @chrisl Thanks for pointing that out! Apparently it's also sufficient to directly bridge the +5V and Reset pin, but I haven't treid that, yet. Dec 1, 2021 at 9:59
  • it is not possible to burn bootloader to the as ISP programmer Arduino
    – Juraj
    Dec 1, 2021 at 10:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.