How can I solve atmega328p-pu resetting while it is supplied from power supply
You should first measure the output of the power supply. It looks like a brown-out reset issue. (Would like to comment instead of posting reply but my rep. isn't enough yet)