Trying to burn a bootloader to some ATMEGA328P chips I have but I'm not having any luck. When I choose the burn bootloader option from the arduino IDE I get this error:
avrdude: stk500v2_command(): command failed
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
Then I tried to burn a hex file I had directly from avrdude to make sure I hooked up the ISP right but I got the exact same error. I then switched chips with a new one right out of the packaging and tried to burn the same hex. It worked perfectly so I know everything is hooked up ok. Then I figured there might have been something wrong with the first chip so I tried to burn the bootloader again from the arduino IDE. Didn't work, got the same error as with the first chip. Went back to see if the hex would burn again after that and it WOULD NOT.
So in short something is happening when I try to burn the bootloader that is killing the chips. Anybody know what is going on here? Also...is there a way to restore the two chips I already screwed up back to how they were before. I don't have many left...