CMOS sensor based cameras are becoming more and more popular among both new astrophotographers but also among current CCD users. Many people in this latter group wonder if the work with these new electronic devices will look the same like before. Well, in general it will, however there will be some differences in details. And as you probably know, the details is the place where God is, so adjusting good CMOS camera settings may be a kind of challenge 🙂

CMOS settings challenge

CMOS camera settings

When it comes to CMOS cameras there are a few more settings to fiddle around, that were not present in oldie goldie CCD cameras.

GAIN – this one is probably the easiest to understand, yet there are some problems to select desired setting. Gain is more less the same as ISO setting in digital cameras. When we increase the gain, all the signal from sensor is higher, so the image will be brighter. But also visible noise will increase and dynamic range will decrease. I wrote more about gain here and here.

OFFSET (or sometimes BIAS) – this is constant value added to signal read from sensor. The idea behind is to avoid pixels that have value of zero and could cause artifacts in the image.

USB traffic – determines the bandwith of USB port that will be reserved for the camera. To ensure highest possible transfer rate USB traffic should be set as high as possible (or low – see later in the post). But increasing it too much may effect in unstable work

Soap Bubble nebula
Soap Bubble nebula

How to set all these new parameters?

USB traffic is probably the easiest to adjust. We need to set it to the highest value where system works stable. Of course it does not need to be very granular setting. You can choose for example 60 or 70, but does not make much sense to choose between 64 and 63. When we already have the optimal value it is worth to expose one test bias frame. Then we can lower USB traffic by 1/3 and expose one more bias frame and compare. If both have similar noise distribution then we can stay at our USB traffic setting.
Also in some cases (especially when we use camera with USB2.0 port) increasing USB traffic may cause slower transfer and longer frame download. Then we need to decrease USB traffic, so the frame download time is shorter. In some versions of CMOS camera drivers lowering USB traffic settings effects in higher transfer. In this case we need to do changes in reverse mode. Set this setting as low as possible, so the transfer will be fastest, but system works stable. 

Offset setting is also quite straightforward to set. For each gain setting we need to adjust offset, so there will be clear gap in bias frame histogram to the left of histogram peak. And there will be no pixels with zero value in the whole frame. For high gain settings it is sometimes impossible to eliminate all zero value pixels even at maximum offset. Then we need to leave offset set at maximum and that is all we can do.

And now gain setting that is sometimes most problematic to select when it comes to the CMOS settings. For planetary imaging when we operate in milisecond range exposure times we set gain to high value. In this case we can use image preview to see if the gain is good for us. For example if the planet image is not oversaturated. For so called “lucky imaging” when exposure time varies from fraction of second to a few seconds we can set gain to values between unity gain 1) and unity gain multiplied by 2-3. And for long exposure astroimaging, where exposure time is 1 minute or more – well there are two approaches to adjusting gain:

  1. we set gain to minimum value and expose frames as for CCD cameras
  2. we set gain to “some value” between minimum and unity gain and expose frames with time shorter than for CCD cameras

Higher gain vs lower gain

In theory the second way allows us to achieve maximum possible signal to noise ratio and also maximum possible dynamic range in the final image. This is due to two facts. First – increasing gain also reduces in the same time read noise (but (!) it also reduces effective pixel capacity, so effective dynamic range). At low gains this increase is significant, for higher gains this increase is minimal. And second – collecting the same amount of material with short exposed subframes we will have larger number of frames. Since the analog to digital converter (ADC) resolution of CMOS cameras is usually 12 or 14 bits that in theory would give us better dynamic range in final image.

 Moon mosaic made with QHY163 camera and SCT8"
Moon mosaic made with QHY163 camera and SCT8″  

In real life these advantages are not so obvious. First – in long exposure astrophotography read noise is small fraction of total noise in the image. And since the read noise in CMOS cameras is very low anyway, there is no visible benefit when it will be lowered. And second – when we split material to larger number of short frames the dynamic range increase in the final image will not be substantial. This is again to the same fact as before. The dynamic range of the camera (so the ratio between pixel depth and read noise) sensor can be larger than ADC resolution. But dynamic range of the registered image (so the ratio between pixel depth and total noise in the frame) will be definitely lower than 12 bits (for long exposure astroimaging). And, as I mentioned before, increasing gain reduces effective pixel capacity. So dynamic range will be limited, and also more stars may be oversaturated.

Quantization error

There is one more possible advantage of using shorter exposed frames at increased gain – quantization error. If the camera sensor pixel has depth 16000e, and ADC resolution is 12 bit, so 4096ADU levels, then the read value of 100ADU 2) may indicate 399 or 400 or 398 or 401 registered electrons and that will be additional source of noise. Quantization error may play a little role for single frames, where background is very dark – like in narrowband imaging. But quantization error is not a systematic error, but random error, so when we stack subframes to final image this error will also be decreasing. In general – the less noise sensor registers (dark sky, slow instrument, filters, short exposures) the more read noise and quantization noise will affect the final image. In extreme cases it may happen, that for example under exceptionally dark skies with color camera (RGB filters) and f/10 telescope exposure times 3-5 minutes would require some gain increase to achieve optimum outcome. Or the single exposure time may be increased.

There is one sweet spot for CMOS camera settings that would give minimum effect of read and quantization noise to final stacked image. It lays somewhere between zero and unity gain for gain setting, and somewhere between 30 and 300 seconds for exposure time, and will also vary with the number of single frames we collect. But the benefit achieved with this sweet spot can be easily compensated by just collecting a few percent more of subframes with gain just set to zero. In my opinion it makes life much easier (consider collecting also calibration frames for each combination of settings).

That’s for the theory. Some time ago I made small comparison and exposed the same target with two different settings. First attempt was at gain=0 and I exposed 10 frames 5 minutes each (with luminance filter). Second attempt was at gain=10 and I exposed 50 frames 1 minutes each. After calibrating and stacking I was not able to see and probe any difference between final images. I mean – any difference that would be larger than just an uncertainity error. That’s why I stay at gain=0 for long exposure astroimaing till the moment I will find out there is a better way 🙂

In the next part I will write about calibrating frames at CMOS cameras. So far there is one important thing to remember about CMOS settings: each combination of temperature, gain, offset and USB traffic usually requires separate set of calibration frames. So if you want to play with all settings – reserve much time for it.

Clear skies!

1) unity gain is a gain where one recorded electron is trasformed to 1ADU in analog to digital converter. At this setting pixel effective depth is reduced to ADC resolution (so for 12 bit ADC it will be 4096)

2) one need to remember that ADC resolution in CMOS cameras is usually 12 or 14 bit, but the signal transferred to computer is expanded to 16 bit anyway. So when 12bit ADC reads 100ADU it is stored in computer as 1600ADU