How to wire a mega328p-AU

You don't have to ask that, you can look it up.

Look at the schematics of the Teensy 4.0, Arduino Uno and Arduino Nano. Then you see three different ways. It is all open-source. That's all online.
There are also MKR boards with a connector for a battery.