if you want to reverse the direction of the motor and it's not a brushless motor. every motor driver should be able to do that. some use a high or low pin others use serial communication.
with no motor driver just theoretically if the mcu could output enough power for the motor just make one pin high and another low. and reverse that for reverse