Apply your PWM signal from the micro to the TIP31 directly. Emitter grounded. PWM into base via resistor. Motor connected from power supply + to collector of the TIP.
Remember to put a reverse diode across motor for commutation. TIP31 is rated for 3A , so it would work , but a higher current device would be preferable.
Depending on the current available from your micro pin , you may need another transistor to make a Darlington configuration , like the tip/3055 in your drawing.
You could also use a logic level mosfet in place of the bipolar , which would be a better idea anyway I think.
Neddie
- - - Updated - - -
Simple schematic attached
- - - Updated - - -
Sorry , small mod , R2