I was having a problem with my atmega328p, so I figured I'd do a complete reset on it.
so far so good. However, I noticed the lockbits are set to 0x3F; when I try to reset it to 0xFF, I get an error:
avrdude.exe: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.01s
avrdude.exe: Device signature = 0x1e950f
avrdude.exe: reading input file "0xFF"
avrdude.exe: writing lock (1 bytes):
Writing | ***failed;
################################################## | 100% 0.07s
avrdude.exe: 1 bytes of lock written
avrdude.exe: verifying lock memory against 0xFF:
avrdude.exe: load data lock data from input file 0xFF:
avrdude.exe: input file 0xFF contains 1 bytes
avrdude.exe: reading on-chip lock data:
Reading | ################################################## | 100% 0.01s
avrdude.exe: verifying ...
avrdude.exe: verification error, first mismatch at byte 0x0000
0xff != 0x3f
avrdude.exe: verification error; content mismatch
avrdude.exe done. Thank you.
~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~
avrdude.exe: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.01s
avrdude.exe: Device signature = 0x1e950f
avrdude.exe: reading lock memory:
Reading | ################################################## | 100% 0.01s
avrdude.exe: writing output file "C:\Users\josh\AppData\Local\Temp\12f4ac26-6697-4bc9-b61f-1f02406a8557.TMP"
avrdude.exe done. Thank you.
writing the other fuse bits is no problem... just the lock bits. Ideas?