Difference between revisions of "Data mode"
Line 1: | Line 1: | ||
During normal readout (i.e. not raw mode), there are 4 data associated with each channel. These are: | During normal readout (i.e. not raw mode), there are 4 data associated with each channel. These are: | ||
* '''error''' calculated based on Series-Array Signal sampled by the ADC: <math> error= \sum_1^{sample\_num} (adc\_reading - adc\_offset)</math> | * '''error''' calculated based on Series-Array Signal sampled by the ADC: <math> error= \sum_1^{sample\_num} (adc\_reading - adc\_offset)</math> | ||
− | * '''sq1_fb''' or feedback applied by the MCE to the SQ1 calculated as: <math>sq1\_fb_{n+1} = [ | + | * '''sq1_fb''' or feedback applied by the MCE to the SQ1 calculated as: <math>sq1\_fb_{n+1} = [\quad gainp * error_n \quad + \quad gaini * \sum_1^n error \quad + \quad gaind * (error_n - error_{n-1})] \quad/ \quad 2^{12} </math> |
* '''sq1_fb_filtered''' or the low-pass filtered SQ1 feedback (see [[ Digital 4-pole Butterworth Low-pass filter | 4-pole Butterworth low-pass filter ]]). The effective DC gain, including quantization error, is approximately 1218. | * '''sq1_fb_filtered''' or the low-pass filtered SQ1 feedback (see [[ Digital 4-pole Butterworth Low-pass filter | 4-pole Butterworth low-pass filter ]]). The effective DC gain, including quantization error, is approximately 1218. | ||
Line 8: | Line 8: | ||
Depending on the data mode, these values will be windowed in a different way. The notes in the table below explain the windowing, in terms of how many bits are reported and the relative scaling of the windowed value relative to some reference data mode. | Depending on the data mode, these values will be windowed in a different way. The notes in the table below explain the windowing, in terms of how many bits are reported and the relative scaling of the windowed value relative to some reference data mode. | ||
− | See | + | See [[ MAS data.pro ]] which handles the loading of MCE flat file data into the IDL environment. |
− | + | '''Current as of RC firmware Revision 4.0.c ''' | |
{| border="1" | {| border="1" | ||
Line 115: | Line 115: | ||
= Note regarding units = | = Note regarding units = | ||
− | The scaling is quoted as being relative to some reference data mode. For example, in data mode 4, if I were to observe the same system's feedback in data_mode 4 and data_mode 1, and call the two measurements fb_4 and fb_1, then I would expect | + | The scaling is quoted as being relative to some reference data mode. The reference data modes for error, sq1_fb and sq1_fb_filtered are, respectively, 0, 1, and 2. |
+ | |||
+ | For example, in data mode 4, if I were to observe the same system's feedback in data_mode 4 and data_mode 1, and call the two measurements fb_4 and fb_1, then I would expect | ||
fb_4 = fb_1 >> 12 = floor[ fb_1 / 2^12 ] | fb_4 = fb_1 >> 12 = floor[ fb_1 / 2^12 ] | ||
where >> denotes the right-bit-shift operator. | where >> denotes the right-bit-shift operator. | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
Please note that, by default, [[ mas_data.pro ]] will rescale data in the following way: | Please note that, by default, [[ mas_data.pro ]] will rescale data in the following way: |
Revision as of 09:47, 1 October 2008
During normal readout (i.e. not raw mode), there are 4 data associated with each channel. These are:
- error calculated based on Series-Array Signal sampled by the ADC: <math> error= \sum_1^{sample\_num} (adc\_reading - adc\_offset)</math>
- sq1_fb or feedback applied by the MCE to the SQ1 calculated as: <math>sq1\_fb_{n+1} = [\quad gainp * error_n \quad + \quad gaini * \sum_1^n error \quad + \quad gaind * (error_n - error_{n-1})] \quad/ \quad 2^{12} </math>
- sq1_fb_filtered or the low-pass filtered SQ1 feedback (see 4-pole Butterworth low-pass filter ). The effective DC gain, including quantization error, is approximately 1218.
- num_flux_jumps or flux-jump counter
Depending on the data mode, these values will be windowed in a different way. The notes in the table below explain the windowing, in terms of how many bits are reported and the relative scaling of the windowed value relative to some reference data mode.
See MAS data.pro which handles the loading of MCE flat file data into the IDL environment.
Current as of RC firmware Revision 4.0.c
Data Mode | Summary | Pixel-Data Description | RC Firmware Revision |
---|---|---|---|
0 | Error | 32b (signed) co-added Error signal err[31:0].
error_mode0 = error |
all |
1 | Feedback | 32b (signed) SQ1 Feedback data fb[31:0]. When servo_mode = 3:
feedback_mode1 = sq1_fb * 2^12 |
all |
2 | Filtered feedback | 32b (signed) low-pass filtered SQ1 feedback data fb[31:0].
flt_fb_mode2 = sq1_fb_filtered |
2.0.5 and later |
3 | Raw 50 MHz | Raw 50 MHz ADC samples raw[13:6].
raw_mode3 = (adc_reading – adc_offset) / (26), except in rev. 4.3.7 where all 14 bits are reported. |
Only 3.0.6, 3.0.16, 3.0.25, 4.1.7, 4.2.7, 4.3.7 |
4 | 18:14 Mixed | Signed 18b SQ1 feedback fb[31] & fb[28:12] + signed 14b coadded error signal err[31] & err[12:0].
feedback_mode4 = sq1_fb / (212) error_mode4 = error |
2.0.9 and later |
5 | 24:8 mixed | Signed 24b SQ1 feedback fb[31:8] + signed 8b num_flux_jumps fj[7:0].
feedback_mode5 = sq1_fb / (28) |
all |
6 obsolete | 18:14 mixed | Signed 18b filtered data filter[31] & filter[27:11] + signed 14b coadded error signal err[31] & err[12:0].
filtered_fb_mode6 = sq1_fb_filtered / (211) error_mode6 = error |
3.0.30 to 4.0.6 only |
7 | 22:10 mixed | Signed 22b filtered data filter[31] & filter[27:7] + signed 10b coadded error signal err[31] & err[12:4].
filtered_fb_mode7 = sq1_fb_filtered / (27) error_mode7 = error / (24) |
4.0.2 and later |
8 obsolete | 24:8 mixed | Signed 24b filtered data filter[31:8] + signed 8b num_flux_jumps fj[7:0].
filtered_fb_mode8 = sq1_fb_filtered / (28) |
4.0.4 only |
9 | 24:8 mixed | Signed 24b filtered data filter[31] & filter[23:1] + signed 8b num_flux_jumps fj[7:0].
filtered_fb_mode9 = sq1_fb_filtered/ (21) |
4.0.5 and later |
10 | 25:7 mixed | Signed 25b filtered data filter[27:3] + signed 7b num_flux_jumps fj[6:0].
filtered_fb_mode10 = sq1_fb_filtered / (23) |
4.1.6, 4.0.b and later |
Note regarding units
The scaling is quoted as being relative to some reference data mode. The reference data modes for error, sq1_fb and sq1_fb_filtered are, respectively, 0, 1, and 2.
For example, in data mode 4, if I were to observe the same system's feedback in data_mode 4 and data_mode 1, and call the two measurements fb_4 and fb_1, then I would expect
fb_4 = fb_1 >> 12 = floor[ fb_1 / 2^12 ]
where >> denotes the right-bit-shift operator.
Please note that, by default, mas_data.pro will rescale data in the following way:
- error signals are rescaled to match the units of data mode 0.
- sq1 feedback is rescaled to sq1_DAC units (i.e. data mode 1 divided by 212)
- filtered sq1 feedback is rescaled to the units of data mode 2.