Programming is working when pressing reset button

I have an issue with the Pocket AVR Programmer… I need to hold the reset button in order to make the programmer works. If I do not hold the reset button, I sometimes get the message ‘initialization failed, rc=-1’ and sometimes it starts to work but then I get ‘Yikes! Invalid device signature.’

I have doubleétriple check my design and everything seems to be correctly connected. I guess there is an issue with the reset not correctly handled…

I am trying to program a atmel 328p

Any suggestions ?

If I remove the 10K ohm resistor connected to VCC and the reset pin of the AVR, I can program the AVR without holding the reset button. When I unplug the AVR Pocket Programmer, it seems the AVR remains in reset … So I need to insert back the resistor.

What am I doing wrong ?

Hi,

I have manage to make it works. The VCC and GROUND is coming from my wall mart. When I use the AVR pocket programmer, I need to connect the ground of the AVR pocket programmer to my main ground in order to make it works. Is this normal ?

Connecting a ground comming from a wallwart, to a ground comming from as USB device is a bad idea. There is likely a voltage level difference between the grounds, (and a return path through the wallwart, mains, pc/laptop PSU, USBport to programmer to device). And as such will start to cause current to flow, and logic levels to mismatch. It could potentially (no pun intended) ruin your USB port, or worse your pc.

You should not power/connect the device from the wallwart when you program it with the pocket programmer.

Sorry, I might have confuse you a bit. I am using the wall power adapter (12V) to supply power to the power supply I built on the breadboard from the schematic http://dlnmh9ip6v2uc.cloudfront.net/dat … %20v10.pdf which is exactly https://www.sparkfun.com/products/114

On a side note, the same problem happens when I am using the FT232RL USB to Serial. I need to connect the GND of the FT232RL USB to Serial in order to make it works (otherwise I receive garbage from the UART). At first, I connected only the RX and TX of the AVR to the FT232RL USB to Serial (but that did not worked). Should I connect the GND and VCC of the FT232RL USB to Serial to the power lines ? From the tutorial http://arduino.cc/en/Main/Standalone, they have built a simple power supply (note that the GND is the same as the wall power adapter). They also connected the VCC and GND of the FT232RL USB to Serial with power lines (which connects the power supply). Should I do that ? Can I also feed the power supply while the USB is connected ?

What I wish to acheive is to leave everything connected and ready to operate without to plug/unplug. (i.e leave the AVR powered by the power supply (build from the shchematic), leave the AVR pocket programmer ready to program at any time and also leave the FT232RL USB to Serial for debug). What should be connected to what then ?

try running a small cap (.1uf should suffice) in series from reset on your FT232RL to your chips reset pin.

If you’re using external power for your chip, you may or may not need to hook up 5V from your programmer to your chip. Items like the FT232RL you DON’T want to attach the 5V line (but still grounds), but programmers like the AVRISP series you will need to. Its a matter of whether the 5v from the programmer is to actually provide power or not.