Skip to content

Enhance the environmental metrics export to the DCS

Laurent Petre requested to merge feature/dcs-export-smoothing into main


This MR is a follow-up on issues recently discovered in the DCS due to the publication of NaN values in the (DAQ) DIM services. Since the very first implementation, the DCS always had issues dealing with the large amounts of data produced by the DAQ. This MR takes a different approach consisting in the large overhaul of the DIM publication in order to provide pre-processed data.

The main change consits in the following: For each one of the metrics to be exported, up to N samples are recorded (by default 20 samples taken ~1s apart). The DIM publications are updated at regular intervals (by default every ~15s) taking the average of the recorded history, ignoring invalid values (i.e. NaN or no readout). Additionally, a dead band w.r.t. the currently published is applied in order to smooth out small variations (default to 0.5° for the temperatures and 0.05V for the voltages).

Other changes are technicalities to reach the end results. Also note the improvement on the GE1/1 temperature readings thanks to the better usage of the precision resistor.

Related Issue


How Has This Been Tested?

The initial version has been deployed in production at P5 for ~1 week. The latest version has been carefully tested on the GE1/1 setup in the 904 integration area.

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)


  • 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.
Edited by Laurent Petre

Merge request reports