Hello I am beginner with electronics and I just need to know if the schematics is fine. I tried this with UNO and external power supply, with GND's connected and worked fine. Now I am not sure if it will work, I make PCB at home and don't want to waste time or money, thanks for help
You're at least missing one very very very important component which is the 100nF decoupling capacitor as close as possible to the ATmega328p.
And you always have to keep an eye on the power when you share power between micro and servo. Servo's are very power hungry and can draw a lot of current in bursts which can drop the voltage quite a bit. So I rather not share the 5V directly. I'll rather give both there own regulator or at least decouple the micro power from the servo power by adding a (Schottky) diode between general/servo Vcc and micro Vcc with an extra capacitor for the micro (which the servo's can't drain because of the diode).
Extra thing, add the option for a resistor between Vcc and every servo signal. You can add a 4k7 resistor onto that if you use SG90 servo's and make them a whole lot less violent at startup.
Aref must not be linked by wire to Vcc.
Aref can be programmatically linked to:
Vcc
Internal reference (1,1V)
External reference (any voltage between 1,1V and Vcc)
If you choose internal reference (1.1 V) and if Aref is connected by wire to Vcc you will destroy your microcontroller.
The most important concerning Aref:
It is absolutely necessary to place a capacitor (100 nF) between Aref pin of microcontroler and Gnd pin which is just beside. As close as possible of the two pins Aref and Gnd, it is very important.
It is not by hazard that Atmel has placed a Gnd pin right next to Aref that is why it is compulsory to make good analog measurements. Otherwise measurement will be noisy.
I usually add pads for all I/O pins, in this case D9-13.
This way you can easily solder things to the PCB if you need to for unfoseen items.
Example you might need to add a switch.
I would also recommend you to have a few extra pads for future GND connections .