How do I upload a code to atmega8 with the arduino bootloader..??

I have written a code in the arduino platform which I want to upload to an atmega8 without the boot-loader...

  1. to save space..
  2. to skip the boot up time of the arduino bootloader..

If you want to save space, use an ISP (usbtiny, AVRISP mkII ...).

madworm:
If you want to save space, use an ISP (usbtiny, AVRISP mkII …).

As I have written the code in the arduino platform, how will I use the arduino program to upload via usbtiny, AVRISP mkII …???
Is it possible that I connect a STK500 programmer and upload it to the atmega8…??
If so that what will i have to select on the board option of the arduino progam, as the atmega8 will not have the arduino bootloader…??

"bootloader" is a kind of programmer. In "preferences.txt" it is set as the default:

upload.using=bootloader

I think you are supposed to create a "hardware/boards.txt" file that specifies a different programmer. Programmers are listed in "programmers.txt":

atmega8.name=Arduino NG or older w/ ATmega8

atmega8.upload.using=usbtinyisp atmega8.upload.protocol=stk500 atmega8.upload.maximum_size=7168 atmega8.upload.speed=19200

atmega8.bootloader.low_fuses=0xdf atmega8.bootloader.high_fuses=0xca atmega8.bootloader.path=atmega8 atmega8.bootloader.file=ATmegaBOOT.hex atmega8.bootloader.unlock_bits=0x3F atmega8.bootloader.lock_bits=0x0F

atmega8.build.mcu=atmega8 atmega8.build.f_cpu=16000000L atmega8.build.core=arduino

can you be more clear of how to do it...??

These are my notes on how to upload to the Atmega328 using my UsbTinyISP gadget:


To upload using ICSP header

  • Quit Arduino application.
  • Edit /Users/yourname/Library/Arduino/preferences.txt Change the line:

upload.using=bootloader

to:

upload.using=usbtinyisp

  • Then start Arduino (you can select Uno board) and upload in the normal way.

To change back, set the upload.using back to “bootloader”. Then you will need to re-upload the bootloader onto the chip using the Arduino IDE.