Programming ATmega8 with AVR-USBASP

ATmega8, having Advanced Virtual RISC Architecture is a microcontroller having breadboard friendly 28 pin DIP package.This post is intended to help beginners program ATmega8 IC’s using USBASP.

IMG_0013 copy


The USBASP is a serial programmer having Serial Peripheral Interface for programming . The programmer consists of 10 pin standard serial connector for connecting to the target board for programming. The USBASP consists of the ATmega8 IC which can be connected through USB port as ELEMENTZ AVR PROGRAMMER by providing suitable driver from here.

The target pinout is as follows


Pinout description is as follows.

Net Description
Connection pin- ATMEGA8
MOSI Master Out Slave In 6
MISO Master Out Slave In 7
SCK Serial Clock 8
TRST Target Reset 9
TVCC Target VCC 10
GND Ground 11

The connection is to be made as follows.

IMG_0016 copy

After connecting the USBASP programmer to the USB port for the first time user have to locate the driver file from the above said link. On successful  installation the device manager should list device as ‘ELEMENTZ AVR-USB PROGRAMMER‘.


Then connect the AVR Programmer to your project board. A compatible project board can be purchased from this link. For other boards connect the 10 pin connector by making use of the pinout mentioned above.

For programming your IC AVRDUDE GUI is required which can be downloaded from this link.

Open AVRDUDE GUI. Make sure the configuration is done properly according to the picture shown below.



Inorder to make external crystal oscillators to work, fuse settings should be changed. Click on fuses tab and provide Low and High Fuse settings, select write and press Execute.


Some popular fuse settings are as follows.

Low Fuse High Fuse
E1 D9 Factory Default– Works with internal 1 MHz RC Oscillator
E4 D9 Works with Internal 8 MHz RC Oscillator
FF D9 Works with External 8-16 MHz Crystal Oscillator


Program can be loaded to flash memory by providing the hex file in Flash tab. Select the write button and press execute.


Other resources and links.

1) Elementz AVR- USBASP Driver — link

2) AVRDUDE GUI — link

3) USBASP Usermanual — link

4) ATMEGA 8 Project Board — link

5) USBASP Ebay product — link

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s