Hi All,
I recently purchases two ATmega 328P-PU Chips from Sparkfun preloaded with the optiboot. When I switch the chips onto my arduino Uno I can upload sketches from the IDE without a hitch. However, when I hook them up on my breadboard, I cannot upload the sketch and I get the following error message:
avrdude: stk500_getsync(): not in sync: resp=0x00
I found somewhere that adding 1k pullup resistors to TX/RX pins has resolved this issue in the past. So far no luck.
I have tried uploading to my breadboard from an OSEPP brand FTDI board (purchases from Frys), an FTDI cable (purchases from mad scientists for the Diavolino), and I have tried removing the chip from my arduino so that I can use the FTDI connected to the board. The error message is always the same.
If I load the "Blink" code to the chip while plugged into the UNO, and then remove the chip and power it up on the breadboard, it still cannot get the LED on IO 13 to blink...
I attached a picture of the ATmega on my breadboard. I am using the 16.000MGhz crystal. You'll notice a capacitor and resistor on the reset pin of the atmega. I swap these in and out depending on if I am trying to upload form the FTDI chip or the arduino board... Still unsure if the reset is positive or negative triggered
Any help would be great! I have not been able to find much documentation on the 328P-PU. I tried to burn a deumilanove bootloader but I got some kind eeprom/device id error when I tried using my UNO as an ISP...
Still unsure if the reset is positive or negative triggered
Reset is negative triggered, normally pulled high. Trying to use the auto-reset pulse from your arduino board may be problematic and may be what is tripping you up. Instead you should just add a reset switch between ground and the reset pin 1 on your breadboard. The timing can be tricky but what I do is press and hold down the reset switch then press upload on the IDE and when you see the compiled sketch size reported on the IDE release the reset button.
waymon91,
I use an FTDI friend from LadyAda so I can't say exactly about the cables/adapters you use but my .01uf cap goes between the reset pin and the dtr pin on my adapter, not to ground. Don't forget to cross the TX/RX lines from the adapter to the 328p-pu. I use these chips all the time, but load up bare chips from Digikey with Nick Gammons Opti-loader utility. Works like a charm. (Thanks Nick)
TomJ
Tumbleweed:
waymon91,
I use an FTDI friend from LadyAda so I can't say exactly about the cables/adapters you use but my .01uf cap goes between the reset pin and the dtr pin on my adapter, not to ground. Don't forget to cross the TX/RX lines from the adapter to the 328p-pu. I use these chips all the time, but load up bare chips from Digikey with Nick Gammons Opti-loader utility. Works like a charm. (Thanks Nick)
TomJ
Lefty - I've wired up a reset button like you said, and I have tried uploading sketches with the method you described. Still getting the same error message.
Tumbleweed- I am using the .1uF cap when trying to upload with my FTDI cable and breakout board... to no avail.
cjdelphi- Are you sure? I am not sure what the crystal would be doing if we were letting current pass right through it... All of the drawings/pictures I've seen have shown the the caps on the crystal connected to common, while leaving the crystal itself un-grounded. Regardless, I have tried grounding it (on both ends) still no luck...
I have tried all of your advice in combination without any success. Again, when I plug the arduino directly into the UNO board, I can load sketches to it without a problem. So I don't understand why I cannot just use the FTDI setup I have on the UNO to program the chip on the breadboard... In addition, if I am powering the chip correctly, shouldn't the blink sketch be running when I put it on the breadboard?