Arduino Forum

Forum 2005-2010 (read only) => Hardware => Interfacing => Topic started by: snaggy on Jun 16, 2010, 05:38 pm

Title: Program Atmega328 with bootloader already loaded
Post by: snaggy on Jun 16, 2010, 05:38 pm
My problem: I have a circuit which uses an atmega328 which is connected only to the quartz and few other components.

Is it possible to program it without ICSP using the serial connection simply connecting the 2 serial pins of an arduino 2009 board to the pin on the circuit? The 2 microcontrollers should get programmed at the same time, no?

thanks!
Title: Re: Program Atmega328 with bootloader already loaded
Post by: Grumpy_Mike on Jun 16, 2010, 05:46 pm
Quote
The 2 microcontrollers should get programmed at the same time, no?

What two micro controllers you didn't mention where they came from.
The simple answer is no you can't do two at the same time because they respond at a different rate to be fed the next bytes/
Title: Re: Program Atmega328 with bootloader already loaded
Post by: snaggy on Jun 16, 2010, 05:49 pm
you are right.. let me ask it this way:

I have an arduino 2009 board with atmega328, and an atmega328 which is in a working circuit (not a board, it has no usb, serial or ICSP connections) and has the arduino bootloader preloaded in it.

What is the simplest way to program the in circuit microcontroller through the arduino 2009 board?

thanks
Title: Re: Program Atmega328 with bootloader already loaded
Post by: weirdo557 on Jun 16, 2010, 07:35 pm
solder some wires from the tx rx and ground connection of the one being used, take out the atmega from the arduino board, then connect those wires to the tx rx and ground of the now processor-less arduino board.
Title: Re: Program Atmega328 with bootloader already loaded
Post by: Grumpy_Mike on Jun 16, 2010, 08:10 pm
Make a programming header with the TX, RX, Reset, power and ground, just like this project:-
http://www.thebox.myzen.co.uk/Hardware/MIDI_Footsteps.html
Title: Re: Program Atmega328 with bootloader already loaded
Post by: retrolefty on Jun 16, 2010, 08:25 pm
Or if your standalone board's 328 is mounted in a IC socket, you could just take it out and replace it with the processor in your Arduino board, program it normally with the Arduino IDE and then put it back into your standalone socket.

Lefty
Title: Re: Program Atmega328 with bootloader already loaded
Post by: bill2009 on Jun 17, 2010, 01:42 am
Quote
Make a programming header with the TX, RX, Reset, power and ground, just like this project:-
http://www.thebox.myzen.co.uk/Hardware/MIDI_Footsteps.html


I strongly concur.  I have never regretted the board space or time to add a programming header with auto reset and I have had occasion to regret not doing so.