Got some time to experiment with it a bit.
I used Nicks' Board detector to see what Fuses are written to the chip:
Atmega chip detector.
Written by Nick Gammon.
Version 1.17
Compiled on Jul 9 2015 at 01:30:19 with Arduino IDE 105.
Attempting to enter ICSP programming mode ...
Entered programming mode OK.
Signature = 0x1E 0x95 0x0F
Processor = ATmega328P
Flash memory size = 32768 bytes.
LFuse = 0xE2
HFuse = 0xDA
EFuse = 0xFF
Lock byte = 0xCF
Clock calibration = 0xC3
Bootloader in use: Yes
EEPROM preserved through erase: No
Watchdog timer always on: No
Bootloader is 2048 bytes starting at 7800
Extended fuse seems a bit off... So I restarted the whole procedure.
First burned the Lilo bootloader using Nicks' Board programmer:
Atmega chip programmer.
Written by Nick Gammon.
Version 1.35
Compiled on Jul 9 2015 at 01:32:15 with Arduino IDE 105.
Attempting to enter ICSP programming mode ...
Entered programming mode OK.
Signature = 0x1E 0x95 0x0F
Processor = ATmega328P
Flash memory size = 32768 bytes.
LFuse = 0xE2
HFuse = 0xDA
EFuse = 0xFF
Lock byte = 0xCF
Clock calibration = 0xC3
Type 'L' to use Lilypad (8 MHz) loader, or 'U' for Uno (16 MHz) loader ...
Using Lilypad 8 MHz loader.
Bootloader address = 0x7800
Bootloader length = 1932 bytes.
Type 'Q' to quit, 'V' to verify, or 'G' to program the chip with the bootloader ...
Erasing chip ...
Writing bootloader ...
Committing page starting at 0x7800
Committing page starting at 0x7880
Committing page starting at 0x7900
Committing page starting at 0x7980
Committing page starting at 0x7A00
Committing page starting at 0x7A80
Committing page starting at 0x7B00
Committing page starting at 0x7B80
Committing page starting at 0x7C00
Committing page starting at 0x7C80
Committing page starting at 0x7D00
Committing page starting at 0x7D80
Committing page starting at 0x7E00
Committing page starting at 0x7E80
Committing page starting at 0x7F00
Committing page starting at 0x7F80
Written.
Verifying ...
No errors found.
Writing fuses ...
LFuse = 0xE2
HFuse = 0xDA
EFuse = 0xFD
Lock byte = 0xEF
Clock calibration = 0xC3
Done.
Programming mode off.
Type 'C' when ready to continue with another chip ...
Attempting to enter ICSP programming mode ...
Entered programming mode OK.
Signature = 0x1E 0x95 0x0F
Processor = ATmega328P
Flash memory size = 32768 bytes.
LFuse = 0xE2
HFuse = 0xDA
EFuse = 0xFD
Lock byte = 0xEF
Clock calibration = 0xC3
Type 'L' to use Lilypad (8 MHz) loader, or 'U' for Uno (16 MHz) loader ...
Using Lilypad 8 MHz loader.
Bootloader address = 0x7800
Bootloader length = 1932 bytes.
Type 'Q' to quit, 'V' to verify, or 'G' to program the chip with the bootloader ...
Verifying ...
No errors found.
Done.
Programming mode off.
Type 'C' when ready to continue with another chip ...
Now, the fuse seems to be 0xFD.
Next I burned the ArduinoISP sketch on the uP on the Uno, changed board to the customer Breadboard one, and Burned the bootloader. This is what I got from the debug output:
First it programs the fuses:
C:\Users\nikosk\Desktop\arduino-1.0.5-r2\hardware/tools/avr/bin/avrdude -CC:\Users\nikosk\Desktop\arduino-1.0.5-r2\hardware/tools/avr/etc/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P\\.\COM4 -b19200 -e -Ulock:w:0x3F:m -Uefuse:w:0x07:m -Uhfuse:w:0xDA:m -Ulfuse:w:0xE2:m
among other output I observed the following:
avrdude: reading input file "0x07"
avrdude: writing efuse (1 bytes):
Writing | avrdude: Send: V [56] P [50] . [08] . [00] . [00] [20]
avrdude: Recv: . [14]
avrdude: Recv: . [fd]
avrdude: Recv: . [10]
avrdude: Send: V [56] . [ac] . [a4] . [00] . [07] [20]
avrdude: Recv: . [14]
avrdude: Recv: . [00]
avrdude: Recv: . [10]
avrdude: Send: V [56] P [50] . [08] . [00] . [00] [20]
avrdude: Recv: . [14]
avrdude: Recv: . [ff]
avrdude: Recv: . [10]
################################################## | 100% 0.06s
avrdude: 1 bytes of efuse written
avrdude: verifying efuse memory against 0x07:
avrdude: load data efuse data from input file 0x07:
avrdude: input file 0x07 contains 1 bytes
avrdude: reading on-chip efuse data:
Reading | avrdude: Send: V [56] P [50] . [08] . [00] . [00] [20]
avrdude: Recv: . [14]
avrdude: Recv: . [ff]
avrdude: Recv: . [10]
################################################## | 100% 0.02s
avrdude: verifying ...
avrdude: 1 bytes of efuse verified
So it seems the fuse is correct...
Next it writes the bootloader:
C:\Users\nikosk\Desktop\arduino-1.0.5-r2\hardware/tools/avr/bin/avrdude -CC:\Users\nikosk\Desktop\arduino-1.0.5-r2\hardware/tools/avr/etc/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P\\.\COM4 -b19200 -Uflash:w:C:\Users\nikosk\Desktop\arduino-1.0.5-r2\hardware\arduino\bootloaders\atmega\ATmegaBOOT_168_atmega328_pro_8MHz.hex:i -Ulock:w:0x0F:m
No error is reported and avrdude completes successfully both times.
But when using Nicks' Board detector again I get the following:
Atmega chip detector.
Written by Nick Gammon.
Version 1.17
Compiled on Jul 9 2015 at 01:30:19 with Arduino IDE 105.
Attempting to enter ICSP programming mode ...
Entered programming mode OK.
Signature = 0x1E 0x95 0x0F
Processor = ATmega328P
Flash memory size = 32768 bytes.
LFuse = 0xE2
HFuse = 0xDA
EFuse = 0xFF
Lock byte = 0xCF
Clock calibration = 0xC3
Bootloader in use: Yes
EEPROM preserved through erase: No
Watchdog timer always on: No
Bootloader is 2048 bytes starting at 7800
I would assume that the program detects the efuse wrongly but then again the chip does not run with 3.3 V but only with 5 V so the reading should be correct...
Am I doing something wrong?
Is there a avrdude command to read the fuses?
Thanks in advance,
Nikos