Wiring ground on a perfboard

Hi all,

I'm having some doubt about the way the ground should be wired when I use an ATMega328 on a perfboard. I wonder if it's correct this kind of wiring for a LED:

the photo is taken from a tutorial on arduino site (then those wirings are correct), just focus on the led I've drawn and the way I wired it:

is it correct?

Assuming you want the LED on digital pin 0 and you have it configured as output then yes, it's just fine. You want the LED coming from a +5v pin to a resistor to any ground. You could even have the resistor between the pin and the LED if you wanted to be different...

ok... I wanted to be sure at least this is right, because I'm dealing with my first project and was having some problem, so I started to check all wirings and I was unsure about the way I connect the ground with other components. thanks

The board in the picture is a breadboard. A perfboard is a different type of board with (mostly) non-interconnecting holes. A perfboard requires soldering. A breadboard needs no soldering.

I prefer putting the LED on a different pin. Pin 0 is used for serial communication.

yes, sorry I haven’t told you, but I do use a perfboard, I just took that photo because it shows what I implemented on my perfboard.

Pin 0 is used for serial communication.

ok, but if I don’t use it it should not be a problem, that’s correct?

Unless you don't want to program the chip once you put it on the perfboard or if you have ISP to program the chip.

You have no decoupling capacitors on that circuit, you will soon run into problems because they are missing. http://www.thebox.myzen.co.uk/Tutorial/De-coupling.html