A controller for a video surveillance camera enclosure including a method and
apparatus
for controlling a stepper motor by decoding a command for a specific camera action,
setting the state of a state machine, and instructing a position control process
and a speed control process based upon the state of the state machine. A drive
signal is send from said position control process to a motor current process and
a phase control process to generate the current and phase signals to control the
stepper motor. The stepper motor drive current is preferably a non-linear current.
The speed control signal includes ramp up and ramp down speed control for gradually
increasing motor speed and gradually decreasing motor speed, respectively. Another
aspect of the invention detects a plurality of pan and/or tilt positions to reset
the pan and/or tilt motor step count to a known count associated with a known location
without the need to pan and/or tilt past a preselected home position. Another aspect
controls a dome enclosure heater to operate over two different thermostat ranges
to provide for manual de-fogging of the dome bubble.