Scripting Resources for DigitalMicrograph™ |
CCD Temperature Monitor |
|
Function |
Monitors the temperature of a CCD camera either indirectly from the dark counts produced by the camera (universally applicable) or from temperature information sourced directly from the camera controller (only supported on newer controllers). |
Version |
20180607, v1.0 |
Author |
D. R. G. Mitchell |
Acknowledgements |
Thanks to Takanori Sato of University of Sydney for testing this script. |
Comments |
CCD temperature measurement using dark counts relies on the fact that the dark counts produced by a CCD is an exponential function of temperature. As the temperature is lowered, so the dark counts decrease. However, the dark counts measured from a camera is actually made up of two components. When the camera is cold, the major component is the read-out noise. This is a systematic component which is not random. This means that if you sum several images, this component of the noise does not cancel. Instead it accumulates. The second component is the stochastic CCD noise, which is random and is temperature-sensitive. In order to deconvolute these two components this script will capture two images. One will be a very short exposure image (0.04s). The second image is acquired at a user-specified exposure - usually somewhere between 1 and 4s. Here, there is random CCD noise in addition to read-out noise. By subtracting the short exposure image from such a long exposure image, the random CCD noise can be extracted. This is then normalised to random noise counts per pixel per second. This is the parameter which is temperature-sensitive. In order to convert random ccd noise into temperature a relationship between the two must be used. Plotting ln(random ccd noise per pixel per second) vs 1/Temperature (in Kelvin), produces a straight line.This relationship can be then used for the counts to temperature conversion. Here I have measured the counts from a Gatan Ultrascan 2k x 2k (US1000XP) at various temperatures (reported by the built-in Gatan camera temperature function). If you have a different camera, you will need to measure the relationship and modify the slope and intercept constants for your camera. Even if the constants are not correct and the temperature is not accurate, you can still use the script to monitor the absolute temperature stability or the time the camera is taking to reach steady-state during cool-down. The script runs the monitoring as a background thread, so DM can be used while monitoring is ongoing provided no attempt to access the camera is made. The script produces a plot of either dark counts or temperature vs time. |
System Requirements |
Tested on GMS 2.32 but should work on GMS 1 and 3. Compatibility with older cameras/controllers is unknown. It has been tested on Ultrascan and Orius cameras. |
Known Issues |
The temperature readout from dark counts becomes very noisy at low temperature, due to the very low counts coming from the camera. The direct temperature readout (from the camera controller), produces a much more stable temperature. The value is probably sourced from a diode or thermocouple on the camera. If this script produces an error with your camera in direct readout mode, your controller may not support it. In which case use the dark counts method. If the script will not run, try commenting out the commands suggested at the start of the script to deactivate the direct readout code. If the rate of cool down of your camera lies outside the range specified by the camera firmware, it may deactivate the controller (it disappears from the DM interface). One reason may be inadequate cooling. Try increasing the water flow to the upper limit specified for your camera, and if that fails, try backflushing the camera cooling loop, in case it is obstructed by debris. |
Supported |
Yes |
Included Files |
Source code |
Source Code |
See attached script |