Using Arduino as AVR ISP without bootloader

Hi there,

I have a chip ATmega16 and Arduino UNO and a code written in AVR Assembly I would like to upload on the chip.
Is there any way to load that code without a bootloader on the chip?
I found this tutorial, but it seems to be using the bootloader. I don’t have space in FLASH for that, though.
I decided to use Arduino as an ISP because it has USB port and because I already have it. There is no serial port on my computer.

Any help or suggestion will be much appreciated.


I hope you like command line interface…study this second (That Breadboard being first):

You are going to have to set the fuses first like this for another chip and ISP:
avrdude -c usbtiny -p attiny2313 -U lfuse:w:<0xHH>:m
avrdude -c usbtiny -p attiny2313 -U hfuse:w:<0xHH>:m
avrdude -c usbtiny -p attiny2313 -U efuse:w:<0xHH>:m

The “-c usbtiny” is going to be “-c arduino” and the COM port will be needed (i.e. “-P com5”). And your part is going to be…?

m169 = ATMEGA169 [C:\WinAVR\bin\avrdude.conf:4059]
m163 = ATMEGA163 [C:\WinAVR\bin\avrdude.conf:3916]
m162 = ATMEGA162 [C:\WinAVR\bin\avrdude.conf:3720]

You have some choices to make.

You are going to have to use the avrdude like spcomputing said.

You also may need an external programmer. I've found that the avrdude is funky towards using the Arduino as the programmer. Probably because it has to go through that FTDI chip or somethin.

If you aren't sure what the fuses should be set at and such, you can look for arduino bootloader cores for the Atmega 16 and then look at the boards.txt file in the arduino folder and just copy what is in there. You won't be using the bootloader like you said but the bootloader sets the same fuses that you would set yourself.

I have used AVRDude and ArduinoISP without problem to set fuses and program chips without the bootloader. I did compile and load the ArduinoISP using version 0.23 of the Arduino IDE as version 1.00 had a problem… I use a 120-Ohm resistor between +5 and Reset on the Arduino board I am running ArduinoISP on.

Actually it was much simpler than I thought.

  1. I connected everything like this:

| Arduino | |ATmega16 | | - | - | | 10 | |9 - RESET | | 11 | |6 - MOSI | | 12 | |7 - MISO | | 13 | |8 - SCK | | 5V | |10 - VCC | | GND | |11 - GND |

(This is minimalistic configuration. The bare minimum I need to load program on the chip. In normal operation I would connect AVCC, second GND and maybe crystal.)

  1. plugged Arduino to the computer with the USB cable. Now everything is powered from USB.

  2. compiled and loaded Examples>ArduinoISP to the Arduino. using Arduino IDE

  3. run avrdude -P /dev/ttyACM0 -b 19200 -c avrisp -p m16 -U flash:w:program.hex

Everything is in its default configuration and works without any settings needed.

Debian 6.0.2, GNU/Linux 2.6.32-5-amd64, Arduino Uno SMD, ATmega32-16PU

I proceeded mainly with this tutorial.

Thank you for your advices