ADC gain estimator#

The sub-exposure measured signals are in counts units, however we know that the detector output is reported in \(adu\) units. ExoSim simulates the Analog to Digital Converter (ADC) thanks to AnalogToDigital, which converts the \(counts\) units of sub-exposures into \(adu\) units of NDRs (see Analog to Digital conversion)

ADC output are unsigned integers defined in a certain number of bits. Because this objects can represent numbers up to a maximum value of \(2^{n_{bits}} -1\), we need a conversion factor to rescale the floats value NDRs to fit in the new data type range. This conversion factor is defined by ADC_gain. as:

\[g_{ADC} = \frac{2^{n_{bits}}-1 }{ADC_{max}}\]

where \(n_{bits}\) is the number of bits set for the ADC and \(ADC_{max}\) is the maximum value we want the ADC to handle. Assuming a 16 bits ADC, \(2^{16} -1 = 65535\) and a desired \(ADC_{max} = 120000\), then we have \(g_{ADC} = \frac{65535}{120000} = 0.546125\).

This condition can be expressed in the tools configuration files as:

<channel> channel_name
    <detector>
        <ADC_num_bit> 16 </ADC_num_bit>
        <ADC_max_value> 120000 </ADC_max_value>
    </detector>
</channel>