A cam timer or drum sequencer is an electromechanical system for controlling a sequence of events automatically. It is like a mechanical music-machine with movable pins, controlling electrical switches instead of musical notes.
An electric motor drives, usually through a reduction gearbox, at a fixed speed and usually extremely slowly, or in steps (using stepper motors), a shaft on which is arranged a series of cams or a drum studded with pegs along its surface. Associated with each cam is one or more switches. The motor rotates at a fixed speed, and the camshaft follows, usually extremely slowly. Indentations or protrusions on the cams operate the switches at different times. By arrangement of the cams and switches, complex sequences of opening and closing switches can be made. The switches then operate different elements of the controlled system - for example motors, valves, etc.
A programmer may change or rearrange (reprogram) peg or cam positions. Much like the pegs in a music box cylinder activate notes, in a drum sequencer, as the drum of the sequencer spins, the pegs run across switches activating machine processes. The placement of the pegs along the length of the cylinder determine which switch along the length of the drum it will activate. Where the peg lies along the circular circumference of the drum determines at what point in the spin of the drum the peg will activate the switch. By controlling the timing and sequence of switches, the drum replaces a human operator and takes on the responsibility of performing repetitive switching and operations ideally with no weariness and fewer errors.
Most cam timers use a miniature mains synchronous motor to rotate the mechanism at an accurate constant speed. Occasionally more complex timers with two motors are seen.
Cam timers are related to internal combustion engine camshafts, but instead of the cam physically pushing a valve, a cam timer switches signals, and the signals actually effect the physical changes. Also, in a camshaft, the cam rotation is synchronized to the engine configuration by the timing belt or timing gears.