In this circuit, a potentiometer controls both the speed and direction of a small bipolar stepping motor like those found in many 5 1/4" floppy disk drives. Note that the bipolar motors are distinguished from "unipolar" types, in that bipolar units have two coils instead of four, and four wires instead of five. With the potentiometer at the extreme counterclockwise position, the motor runs counterclockwise at the maximum speed. Rotating the potentiometer toward the center slows the motor, until it stops. Continuing potentiometer rotation clockwise, the motor starts to run clockwise, increasing in speed to the maximum clockwise position.
Operational amplifiers U1A and U1B and their associated components form an absolute value circuit with a reference of one half the supply voltage (+4.5 volts). With the potentiometer slider at either extreme position, the output at U1B is about 6 volts, decreasing linearly to +4.5 volts as the slider is moved to the center position.
Operational amplifier U1D is configured as an integrator, and U2B as a voltage comparator. Together, they form an oscillator. U1C, with its diode, is a voltage-controlled clamp that permits voltage control of the oscillator's frequency from the output of the U1A-U1B absolute-value circuit. The threshold of oscillation depends on the voltage present at U1D's positive input, approximately 4.7 volts. Oscillation will not occur below this level, corresponding to the central segment of the potentiometer's control arc, for which the motor is stopped.
The output pulses from U2B are fed to the clock input of the U3 up-down counter. Comparitor U2A detects which side the potentiometer slider is located with respect to center, and it controls the counter's direction. U3's Q1 and Q2 outputs are decoded into a one-of-four sequence by U4, that in turn drives the inputs of "or" gates U5A through D. A quadrature wave pattern, required for motor rotation, results at the four gate outputs. The eight MOSFET power transistors, configured as two "H" bridges, serve as current amplifiers to drive the motor's coils.
The values shown in the U1D and U2B oscillator section provide a frequency range of approximately 1 to 100 Hertz, corresponding to a motor speed of 0.6 to 60 RPM. Although 9 volts is indicated, the circuit will operate from 6 to 12 volts, with higher voltages providing greater torque. The circuit's speed range will be the same for any given supply voltage within the specified limits, due to the circuit's ratiometeric reference. The Matsushita KP39HM4-016 motor is rated 12 volts, 80 milliamperes per coil, and rotates 3.6 degrees per step.