Handle the VFAT hysteresis during special (calibration) runs
Description
This merge request addresses recent (re-)discoveries made when operating the VFAT in low gain, (very) low noise, and low threshold environments. More specifically, such environments require better handling of the VFAT hysteresis feature, particularly during calibration runs.
In order to avoid problems during special runs, this MR implements the following behavior:
- Regular runs -- The HYST register is taken from the VFAT configuration file and left untouched.
- Special runs -- The hysteresis feature is disabled via the EN_HYST VFAT register. (Only when involving static or dynamic modification of the threshold.)
In the future (i.e. when the cmsgemos
configuration system will be enhanced), an obvious improvement would be to dynamically adjust the HYST register value whenever the THR_ARM_DAC one is modified, applying a configurable multiplicative factor (which could itself be overwritten in the calibration Web GUI).
The second commit deals with improvements to the default VFAT configuration, regarding the HYST register, but not only. It should contain the ideal configuration of the VFAT in our current understanding of the chip (gain, comparator mode,...)
Related Issue
None.
How Has This Been Tested?
Tested successfully on the GE1/1 integration setup in B904. All registers are modified as expected.
Types of changes
-
Bug fix (non-breaking change which fixes an issue) -
New feature (non-breaking change which adds functionality) -
Breaking change (fix or feature that would cause existing functionality to change)
Checklist:
-
My code follows the code style of this project. -
My change requires a change to the documentation. -
I have updated the documentation accordingly. -
I have read the CONTRIBUTING document. -
I have added tests to cover my changes. -
All new and existing tests passed.