Have you ever loaded your sketch plugged in your chip only to find out you need to tweak the code a little? Why keep moving the chip from socket to socket risking damage to the pins or static discharge? Did you know that when using an Arduino UNO as your isp there are only 4 wires needed to load a sketch with no special programming?
Step 1: Introduction
Step 2: Parts Needed
1 x Arduino uno.
1 x 5 pin in line wire harness.
1 x 5 pin male header.
2 x PNP transistors such as the SN2907, SN3906,
or the SN4403.
2 x 1k ohm resistors
3 x 330 ohm resistors.
1 x Red led
1 x Yellow led
1 x Green led
1 x Arduino prototype shield.
Any type of enclosure that you would like to use.
I recycled an old case.
Step 3: Remove the ATMEGA328 From the UNO
Step 4: Select Your Cable
Reset, RX, TX, and Ground.
Take your 5 pin wiring harness and remove one of the center wires. In my case pin 2. Fill in the missing hole with some hot glue or a toothpick. This will give you a one way pattern that you can use repeatedly from one project to another ensuring that you don't get the plug in backwards and preventing damage to the chip.
Step 5: Useing the Arduino Prototype Shield.
I used three leds to show status outside the case.
Red is for power from USB port. Yellow for RX and Green for TX.
Using the above schematic drawing, create your circuit on the prototype shield.
You have two options for your led inputs (TX and RX):
One is to connect the TX and RX of this circuit to the TX and RX of the I/O pins....or
Two (the method I chose) You can soldier the TX and RX of the circuit directly to the left side of the leds on the UNO itself.
Step 6: Wiring the Connector.
I used the colors on the connector as follows:
Red = Reset on UNO to reset on ATMEGA 168/328 (chip pin 1). Keep in mind you still need to install the reset button with the 10k pull up resistor on the reset pin.
Black = Ground. You must establish a common ground connection, commonly known as bonding.
Yellow = Data in or TX connection on UNO digital pin 1 to the ATMEGA 168/328 digital pin 1 (chip pin 3)
Green = Data out or RX connection on UNO digital pin 0 to the ATMEGA 168/328 digital pin 0 (chip pin 2)
Step 7: Final Step
Connect each pin of the header to the corresponding chip pins. Again you can use any order you wish as long as they match on both ends.
Remove the same position pin from the 5 pin male header as you did the harness earlier.
In this case I used header pins 1-5 removing pin 2:
1 = TX chip pin 3
2 = no connection
3 = Reset chip pin 1
4 = Ground
5 = RX chip pin 2
Once you have your "sketch loader" built and as long as you use the same header pin lineup on all your future projects you will be able to load all your sketchs straight into your project as well as making "on the fly" updates.
I used two of my projects to show how the "sketch loader" works.
Step 8: Programming
On the back I wrote down the pin layout as reference for each new project. Now all you have to do is load your sketch just like a normal UNO.
I hope this is helpful. It sure made things easier for me.