# Downloading a program into AVR without development board?

**URL:** <https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709>\
**Category:** MicroMod\
**Tags:** avr-atmel\
**Created:** [December 21, 2009, 3:36pm UTC](https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709 "2009-12-21T15:36:16Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![smdFan](https://avatars.discourse-cdn.com/v4/letter/s/c68b51/32.png) [@smdFan](https://community.sparkfun.com/u/smdFan)\
**Post date:** [December 21, 2009, 3:36pm UTC](https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709/1 "2009-12-21T15:36:16Z")

</div>

Hello

I want to program an AVR directly without the help of any development board. My AVR is installed on a breadboard.

How do you program it using SPI method?

I would like to have a complete program. I know the read and write functions for SPI method but I could not put them to use. I like a complete program that uses those functions to download a .hex file into the microcontroller.

Regards

Thanks

---

<div class="post-metadata">

**Author:** ![leon\_heller](https://yyz1.discourse-cdn.com/sparkfun/user_avatar/community.sparkfun.com/leon_heller/32/7602_2.png) [@leon\_heller](https://community.sparkfun.com/u/leon_heller)\
**Post date:** [December 21, 2009, 4:12pm UTC](https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709/2 "2009-12-21T16:12:43Z")

</div>

Find someone to program a boot-loader into your AVR.

Leon

---

<div class="post-metadata">

**Author:** ![smdFan](https://avatars.discourse-cdn.com/v4/letter/s/c68b51/32.png) [@smdFan](https://community.sparkfun.com/u/smdFan)\
**Post date:** [December 21, 2009, 4:54pm UTC](https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709/3 "2009-12-21T16:54:26Z")

</div>

> leon\_heller:  
> Find someone to program a boot-loader into your AVR.
> 
> Leon

You missed the whole point. I do not want to use any development board or anything else. I know you can program a stand alone micro using SPI but I need a sample program of how it is done.

smdfan

---

<div class="post-metadata">

**Author:** ![leon\_heller](https://yyz1.discourse-cdn.com/sparkfun/user_avatar/community.sparkfun.com/leon_heller/32/7602_2.png) [@leon\_heller](https://community.sparkfun.com/u/leon_heller)\
**Post date:** [December 21, 2009, 4:58pm UTC](https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709/4 "2009-12-21T16:58:55Z")

</div>

The whole point of a boot-loader is that you don’t need a development system, just SPI or RS-232.

Anyway, if you want to write your own software look at the SP12 source code:

[http://www.xs4all.nl/~sbolt/e-spider\_prog.html](http://www.xs4all.nl/~sbolt/e-spider_prog.html)

The SP12 programmer uses the PC printer port as the SPI programming interface. You should be able to see how it works.

Leon

---

<div class="post-metadata">

**Author:** ![smdFan](https://avatars.discourse-cdn.com/v4/letter/s/c68b51/32.png) [@smdFan](https://community.sparkfun.com/u/smdFan)\
**Post date:** [December 21, 2009, 5:02pm UTC](https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709/5 "2009-12-21T17:02:16Z")

</div>

> leon\_heller:  
> The whole point of a boot-loader is that you don’t need a development system, just SPI or RS-232.
> 
> Anyway, if you want to write your own software look at the SP12 source code:
> 
> [http://www.xs4all.nl/~sbolt/e-spider\_prog.html](http://www.xs4all.nl/~sbolt/e-spider_prog.html)
> 
> The SP12 programmer uses the PC printer port as the SPI programming interface. You should be able to see how it works.
> 
> Leon

I thought you do not need any kind of bootloader if you are using SPI programming. Was I wrong?

---

<div class="post-metadata">

**Author:** ![leon\_heller](https://yyz1.discourse-cdn.com/sparkfun/user_avatar/community.sparkfun.com/leon_heller/32/7602_2.png) [@leon\_heller](https://community.sparkfun.com/u/leon_heller)\
**Post date:** [December 21, 2009, 6:23pm UTC](https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709/6 "2009-12-21T18:23:40Z")

</div>

It can be more convenient as no special software is required - just a clocked bitstream. Actually, I’m not sure if the AVR can be booted that way, it works for some other chips.

Is the SP12 software the sort of thing that you were looking for?

Leon

---

<div class="post-metadata">

**Author:** ![stevech](https://avatars.discourse-cdn.com/v4/letter/s/ba8739/32.png) [@stevech](https://community.sparkfun.com/u/stevech)\
**Post date:** [December 21, 2009, 6:27pm UTC](https://community.sparkfun.com/t/downloading-a-program-into-avr-without-development-board/13709/7 "2009-12-21T18:27:39Z")

</div>

Downloading code to flash

In-system programmer (ISP), such as

[http://www.atmel.com/dyn/Products/tools … ol\_id=2726](http://www.atmel.com/dyn/Products/tools_card.asp?tool_id=2726)

Most commonly used

JTAG - fancy or cheap, such as

[http://www.nkcelectronics.com/avr-jtag- … r-kit.html](http://www.nkcelectronics.com/avr-jtag-ice-clone-debugger-programmer-kit.html)

works with free AVR studio

Serial port bootloader firmware. Lots of free ones

To get the bootloader firmware into the chip

Buy a board or chip with a bootloader already installed. Quite a few availble as on [avrfreaks.net](http://avrfreaks.net)’s listing of vendor.

or use/borrow an ISP to place your freeware bootloader into flash. One bootloader + PC side software is

[http://www.avrfreaks.net/index.php?modu … tem\_id=625](http://www.avrfreaks.net/index.php?module=Freaks%20Academy&func=viewItem&item_type=project&item_id=625)
