included jitter correction on client

This commit is contained in:
Martino Ferrari
2026-08-13 10:28:43 +02:00
parent a49ab5ba25
commit ff5ad22447
8 changed files with 598 additions and 138 deletions
@@ -106,6 +106,15 @@ public:
*/
void CheckSample(float64 t, float64 v);
/**
* @brief Fire the trigger unconditionally at the most recent sample time of
* the watched signal, latching the pre/post window exactly as CheckSample
* does. Any state except COLLECTING → COLLECTING.
* @return false when no sample has been seen yet, or a capture is already
* being collected.
*/
bool Force();
/** @return Current FSM state. */
TrigState GetState() const;
@@ -127,6 +136,8 @@ private:
bool stopped_;
float64 prevValue_; ///< Last sample (edge detection)
bool prevValid_; ///< First-sample guard in ARMED state
float64 lastTime_; ///< Timestamp of the newest watched sample
bool lastTimeValid_;///< true once a watched sample has been seen
float64 trigTime_; ///< Latched trigger time (Unix s)
float64 firedPreSec_; ///< Window pre-part latched at fire time
float64 firedPostSec_; ///< Window post-part latched at fire time