I’m attempting to program an ATMega168 as described in tutorial 2. I’m using a serial port programmer which I’ve hooked up to my Mac via a USB->Serial adaptor. I’m using avrdude. Essentially, when I run this command:
I get this (apparently popular) message:avrdude -p atmega168 -P /dev/tty.KeySerial1 -cponyser
avrdude: AVR device not responding
avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override
this check.
avrdude done. Thank you.
This is driving me a bit nuts. I’ve used both my multimeter and a few LEDs to to try to debug this as follows :
(1) I’ve checked the vcc and ground on both the atmega and the ICSP (many, many times) and ensured that the vcc pins are getting 5v.
(2) Checked the pins and connections between the atmega and the ICSP (again, many, many times).
(3) Checked every pixel of the photos in the tutorials against my breadboard.
(4) Tried a few avrdude options like -b9600 and various values with -i
(5) Verified that the reset line from the ICSP goes low when I run the avrdude command, and that the SCK and MOSI lines show some activity. I’m unable to detect any change in signal on pin 18 of the atmega (the MISO line).
(6) Tried different atmega chips in case I happened to get a bad one
(7) Started from scratch (twice)
[8] Used a coworker’s AVR-P28B development board (a pre-built AVR programmer). This yielded the same exactly message.
I’m not sure what to make of this, especially after trying the development board. Am I misusing avrdude? Is my use of a USB-to-Serial adaptor screwing up the process?
Any help or advice would be very much appreciated.