Control filterwheel to select a specific filter. Also selects the clock source, and monitors the battery level.
This is part of my PhD camera system, for controlling the filter-wheel.
filterctl -z Power down the dewar light-gates and motor (for observation)
filterctl -k Enable loopback mode
filterctl -c Ext Set the clock source to Ext.
filterctl -M Monitor the battery voltage, and alert when it dies.
The connected hardware consists of a USB/Parallel interface (ftdi245io) which controls a stepper motor via some optical fibres.
When the dewar is quiescent, the 3 bit interface is re-purposed to monitor the battery voltage.
With the 3 remaining bits, the clock-source can be set to internal/external, and the divider may be varied: from 50Hz - 5kHz.
The dewar can be powered-up (lightgates on), down (lightgates off), or placed in loopback mode (temperature sensor + digital clock) connected to 2 of the 4 ADC inputs.
This was written as part of my PhD Infrared Camera system.