New avr - Problem uploading to board

I am trying to change the controller on the arduino board, so I put a new one and same controller "Atmel Atmega328p-pu". But when I try to upload a sketch at the new controller, presented a problem. The softoware says me: Problem uploading to board avrdude: stk500_getsync(): not in sync: resp=0x00 avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51

Why does this happen? What am I doing wrong? I need to change something else in the software settings?

Has the Atmega been pre-loaded with the bootloader, or just a blank chip?

Texy

?ow I have a new blank chip. What should the upload to work well?
Note: the original (genuine) chip operates normally if I put it at the boar…
Thank you

If the old chip operates normally, and you do not have other tools, then you can use the arduino to download a bootloader into teh new blank chip. You will need a solderless breadboard, 16 MHz xtal, two 22 pF caps, and a 10K pullup resistor, and a 100nF capacitor.

You will wire up to-be-programmed chip as shown here http://www.arduino.cc/playground/BootCloner/BootCloner you can leave off the LEDs/resistors.

Then come back here for more directions. member westfw has written a new sketch that runs on the working chip, reads some information from the blank chip, and loads the correct bootloader into it. I'll see if I can find the forum link for that, or perhaps someone else will post it.

Either way, you need to get a few parts and wire up the blank chip.

Just now, I learned that need to load the drivers on the chip to operate in arduino... Thank you very much for the shape and the sketch. Is very useful ...

If someone has not the original (genuine) atmega328 controller, can program the new chip? Can I schedule the new avr chip with the arduino board as isp perhaps?

I think this is the thread I was thinking of, regarding burning of bootloaders

http://arduino.cc/forum/index.php/topic,64105.msg481752.html#msg481752

If someone has not the original (genuine) atmega328 controller, can program the new chip? Can I schedule the new avr chip with the arduino board as isp perhaps?

Do you have a working arduino now? With either a '168 or a '328 chip? Then I think the answer is yes. You will download the sketch from the thread above and run that to download a bootloader into a blank part.

If you do not have a working arduino, the answer is maybe. A Duemilanove can have a few pins added (4 pins to the X3 header) and be used a bootloader. This lets the FTDI chip connect to the ICSP 6-pin header to control the D11-12-13 pins to program a blank part. An Uno, I don't think supports that.

I have the arduino Duemilanove but without the original atmega328 chips on it. Also, i have 3 new atmega328 chip.

I was wondering if I can schedule the new chip using the arduino board as the serial programmer. I saw this device http://arduino.cc/en/Tutorial/ArduinoToBreadboard, but in both cases need to have the original 328 controller ... Is there another way to do this?

Yes :sweat_smile:! The best solution is here http://www.geocities.jp/arduino_diecimila/bootloader/index_en.html with few changes

If you have a duemilanove, adding the pins to the X3 connector and using the directions in the link above works great. Its a lot of setup steps, but it does work. I did the same myself before I got this avr isp to use with a different chip ('1284), and now I use that instead with surface mount parts.

http://www.mdfly.com/index.php?main_page=product_info&cPath=5&products_id=415

I have one of these as well, but have not tried it yet.

http://store.nkcelectronics.com/pocket-avr-programmer.html