I'm currently trying to connect a 7x5 dot matrix to an AVR ATMega328p. I'm already using port B/D and I would like to use port C so that I have extra output pins. My question is, can I use port C as digital output pins without ruining the microcontroller? I know that this port is normally used for analog-digital conversion. If so, do I need to add additional configurations inside my C program?
can I use port A as digital output pins without ruining the microcontroller?
Yes you can.
Below table describes about Sink and source capabilities: VOH is when you try to output a high signal. The current should be less than a particular value which you can find in the same table. VOL is when you output a logic zero. Microcontroller can sink current and you should also care about limiting the current. Excess current may lead to damage of the IO Pin or the whole MCU.
Below are some notes about the analog function rich port C (in some packages, other ports) describing the GPIO capabilities and precautions to be taken.
do I need to add additional configurations inside my C program?
Follow the normal routine as configuring other pins.