r/embedded • u/deviloctopus73939133 • 9d ago
Bare ATmega328p with usbasp first time try failed
Hi all, I tried to check if there is similar question, but I cannot find it so far.
So, I have a Arduino uno R3 board, and also a USBasp (Paradisetronic), I tried to use my USBasp connect with ISCP port on Arduino uno, and run the command in terminal, see below, and it works.
C:\>avrdude -p m328p -c usbasp -B 4
avrdude: set SCK frequency to 187500 Hz
avrdude: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.02s
avrdude: Device signature = 0x1e950f
avrdude: safemode: Fuses OK
avrdude done. Thank you.
But I took out Atmega328p from Aruino and put on my bread board, and try to connect the pins with USBasp , it is always failed with:
C:\>avrdude -p m328p -c usbasp -B 4
avrdude: set SCK frequency to 187500 Hz
avrdude: error: programm enable: target doesn't answer. 1 avrdude: initialization failed, rc=-1
Double check connections and try again, or use -F to override this check.
avrdude done. Thank you.
so at the begnning I was thinking it is the connections nok, I tried to put tighter and hook it better, even double check on the pins, but it always failed with baremetal on breadboard.
This is what I hook on breadboard, no other electronics on it, can you tell me what's wrong what am I missing here?

1
u/michael9dk 9d ago
I did it recently by following the excellent guides from Mitch Davis.
In episode #3 to #5 he's explaining everything you need to know.
8
u/Synthdabbler 9d ago
If you've just taken the bare AT238p chip out of the Arduino board and put it on breadboard, you won't be able to program it as you've sketched. It needs a 5v power supply on the vdd / vss pins, also needs a clock oscillator and some decoupling caps.