Pin 1 to Arduino reset pin, through a 10K resistor, with a 22uF capacitor to avoid automatic resetting of the board
Pin 7 and 20 to 5V
Pin 8 and 22 to GND
Pin 9 and 10 connected to a 16MHz crystal with a 22pF capacitor on each end
Arduino pin 10 to ATMEGA Pin 1
Arduino pin 11, 12, and 13 to ATMEGA Pin 17, 18, and 19 respectively
Like this:
Now I open a sketch, for instance the Blink example (I added a LED to pin 19 of the ATMEGA in order to test if it is working), select "Arduino as ISP" as programmer from the Tool menu and upload the sketch.
I get a "Done uploading" message, with this error:
avrdude: stk500_getsync(): not in sync: resp=0xe0
Needless to say, the LED does not blink...
I am fairly new to all of this, so any solution or even hint would be much appreciated.
Really? I'm fairly new to this, always thought it was the other way around... don't know why, but it doesn't really matter, at least I'm consistent!
Anyway, back to the question. First of all thanks for spotting the wrong connection, not sure why I put that... I guess that was the result of too much thinkering...
So I don't need to add the clock when programming the ATMEGA or it was just not in your photos for other reasons?
In any case, with or without crystal the sketch always gets uploaded to the Arduino and not on the ATMEGA168, even if I choose "Arduino as ISP" as a programmer.