Arduino Firmware

From ElectroDragon
Jump to: navigation, search

Use Arduino as ISP

There is sketch in the arduino IDE, for the wiring in the description should be:

pin name not-mega mega(1280 and 2560)
SS(Slave Reset) 10 53
MOSI 11 51
MISO 12 50
SCK 13 52

upload the sketch and use Avrdude to test it, and should success on following picture

Burning bootloader

  • Tools you will need:
  • USBASP programmer: in our test, it's much faster than the USBtinyISP, don't know really know why, burning with usbasp only need 5-10 seconds, but usbtinyisp need around 1-2 minutes
  • ISP 10-6 Pins converter: It's really helpful to convert ISP 10 pins to ISP 6 pins, and also help you to remember the pins for ISP-6, because the silk print indicate it! Works for all the ISP-10 programmer.And Arduino only have 6-pin ISCP connector
  • Your arduino board: The MCU is already on the board and need to be programmed.
  • Connect the programmer with the converter like below, only need to remember MISO is always to PIN1:
  • Connect the board with USBASP to your laptop and burn, no need USB connect to the board anymore

Burning bootloader with other programmer, directly via hex file

Use Avrdudess programming

You can find the avrdude we used here.programmer

Fuse bit

  • Atmega328p UNO
hfuse - 0xDE
lfuse - 0xFF
efuse - 0x05
  • Lock bit
  1. BLB12 BLB11 - app to bootloader
  2. BLB02 BLB01 - bootloader to app
  3. LB2 LB1 - visit control to Flash, EEPROM, Fuse (hfuse, lfuse, efuse) and Boot Lock Bit
  • bootloader area NOT visit-able - lfuse set to 0x0F
  • bootloader area visit-able - lfuse set to 0x3F

Other type bootloader