Atmega328p on breadboard not working

i have been trying to use the atmega328p microcontroller without the arduino uno . i went through this circuit a million times and i cant figure out whats wrong.
the bootloader is loader on the micro controller and i have a LED blink scetch loaded on it . tested and working on the arduino uno , but when i remove the chip and plug it into the breadboard it doesnt work.

  • pin 1 (RESET) on the Atmega328p in connected through a 10k resistor to 5V
    -pin 7 and 20 connected to 5V
    -pin 8 and 22 connected to gnd
    -pin 19 connected to an led through a 150R resistor.
    -pins 9 and 10 connected to a 16mhz crystal.
  • crystal legs connected each through a 22pf capacitor to gnd.

blue led on pin 19 should blink but its not .
any suggessions ?

Should have bypass caps, but I suspect the power supply caps are close enough that it should do something without them...

Is that left-hand power rail actually also 5V? It looks like it could be connected directly to Vin, which would be ... bad.

Are you sure the LED is inserted correctly?

yea i am sure . all connections are correct . led is inserted correctrly, there is a capacitor on the power board thats why i didnt use extra caps on power pins. but tried it also without the power board same result.
im out of solutions , replaced everything twice even crystal , caps , resistors, breadboard even chip.
i couldnt even burn the bootloader on the bread board , i had to use two arduinos .

I suggest to add the required bypass capacitors, as shown here:

2 Likes


this is an updated picture with the capacitos. still not workinng!

The picture isn't clear and close enough to tell if your wiring is correct, and breadboards are often unreliable.

Double check everything, comparing every connection to Nick Gammon's page, remove and reinsert wires, and use your multimeter to measure the voltages at Vdd, AVdd and AREF pins. In extreme cases of bad breadboard tracks, you might even have to move the chip to a different place on the breadboard.

Do not change any wiring or remove/insert the chip with the power connected!

i checked the wiring multiple times to make sure its right. tried almost everything i knoww to make it workk but its nott.

Long shot it can't hurt thing to try: try it without the 22pF caps.

i ll provide more picture so you check the wiring if possible. thank you



Against what drawing?

Is the crystal body shorted to anything other than the capacitor lead?

If:

  • you have loaded the Blink sketch into the ATmega328P while it was socketed in an Uno
  • you have wired up the breadboard as shown with the appropriate components
  • your breadboard is not defective
  • your power supply module is supplying ground and 5V to the breadboard rails

I can say with some degree of confidence that the circuit Just Works. See below.

So at least one of the four conditions must not be being met for yours to fail. Check, double check, and assume nothing.

i can see you have a capacitor between aref pin 21 and gnd. does it make any difference?

The 0.1uF cap from West to ground is recommended, but the circuit worked for me without that and without both the bypass caps. It even worked with the crystal body shorted to either 22pF cap lead.


here is an updated picture of the breadboard with clear connection , nothing shorted, all as described and still not working . thats crazy, any help at this point is appreciated.

...

Here's an off the wall thought: does your LED work?

yes

i tested all the components separately and they all workk