Class CrossCorrelation
Two-channel cross-correlation block. Consumes a Matrix<double> [rows x 2] (col0 = ch1, col1 = ch2) — or, as a fallback, an interleaved Vector<double> (even = ch1, odd = ch2). Pipeline per processed batch: z-normalize → 10-sample moving maximum → subtract a 500-sample forward mean → cross-correlate. Output lags ascend from -MaxLag to +MaxLag (0 selects the full range); the result has L2 norm 10, scaled to an L2 norm of 10 rather than expressed as a Pearson coefficient. Params: MaxLag (0), BufferLen (1000), ProcessEveryN packets (5). Named Lags parameters enable the selectable-channel/filter pipeline and publish [peak lag, sample rate / lag, reserved zero]; see CrossCorrelation.Configuration.cs.
JSON configuration
Use these block entries inside a pipeline configuration. Input names must match other blocks in that pipeline; device addresses and file paths must match your setup.
Block entry for a larger pipeline. Legacy Params: maximum lag (0 means full range), buffer length, processing interval in packets. Supply a multi-channel observation stream and wait for the buffer to fill. The legacy output is scaled to norm 10, not a Pearson coefficient.
{
"CrossCorrelation": {
"Type": "crosscorrelation",
"Inputs": ["Signal"],
"Params": [0, 1000, 5]
}
}
How Type, Inputs and Params work · Block catalogue and parameter reference
Implements
Inherited Members
Namespace: MOSAIC.Models.SignalProcessing
Assembly: MOSAIC.dll
Syntax
public sealed class CrossCorrelation : BaseBlock, INotifyPropertyChanged, INotifyPropertyChanging, ISubscriber, IPublisher, IBaseBlockProps, IJsonExportable, IDisposable, IAsyncDisposable
Remarks
A BaseBlock represents one node in a processing graph. Blocks are typically created and linked based on a JSON configuration (pipeline definition).
Two Rate Properties:
| Property | Purpose |
|---|---|
| DesiredRate | Emission / display rate in Hz. Determines how often a block publishes output. Modified by windowing blocks (e.g. SlidingWindow: input rows/s divided by stride). Used for status monitoring and tick rate display. |
| SignalRate | True sample rate of the underlying signal in Hz. Used for DSP coefficient design (filter cutoffs, FFT bins, spectral resolution). Passes through windowing blocks unchanged — a SlidingWindow with stride 100 at 2000 Hz input still outputs data whose samples are at 2000 Hz, even though the windows arrive at 20 Hz. |
Rate Inheritance: Both rates propagate downstream automatically via TryInheritRate(BaseBlock). Publication rates initially fill unset values; use UpdateAndPropagateRate(double, bool) for runtime changes. Sample rates refresh downstream unless a block declares that it derives its own rate.
Publishing: The Publish(object) method is thread-safe and non-blocking. If a publish call is already in progress, the new value is dropped and the block enters a "stumbling" state reflected in Status.
Automatic CSV Logging: Every successful Publish(object) call feeds
Dumper whenever one is open. A dumper opens either because the config named a
Path — BlockFactory calls
InitDumper(IServiceProvider, string?) for every block it builds — or because IsRecording was
switched on, which writes to the shared session folder instead. Either way the file is named by
DumpFilePrefix. A block whose Path means something other than a recording
folder overrides PathIsDumpFolder.
Constructors
CrossCorrelation(string, double, int, int, int)
Declaration
public CrossCorrelation(string name, double desiredRate, int maxLag, int bufferLen, int processEveryN)
Parameters
| Type | Name | Description |
|---|---|---|
| string | name | |
| double | desiredRate | |
| int | maxLag | |
| int | bufferLen | |
| int | processEveryN |
Fields
EnvelopeWindow
Declaration
private const int EnvelopeWindow = 10
Field Value
| Type | Description |
|---|---|
| int |
FlatStdThreshold
Declaration
private const double FlatStdThreshold = 1E-06
Field Value
| Type | Description |
|---|---|
| double |
LegacyHighPassWindow
Declaration
private const int LegacyHighPassWindow = 500
Field Value
| Type | Description |
|---|---|
| int |
MinimumBufferLength
Declaration
public const int MinimumBufferLength = 511
Field Value
| Type | Description |
|---|---|
| int |
_bufCh1
Declaration
private readonly List<double> _bufCh1
Field Value
| Type | Description |
|---|---|
| List<double> |
_bufCh2
Declaration
private readonly List<double> _bufCh2
Field Value
| Type | Description |
|---|---|
| List<double> |
_bufferLen
Declaration
[ObservableProperty]
private int _bufferLen
Field Value
| Type | Description |
|---|---|
| int |
_bufferLock
Declaration
private readonly object _bufferLock
Field Value
| Type | Description |
|---|---|
| object |
_ch1Dumper
Declaration
private CsvDumper? _ch1Dumper
Field Value
| Type | Description |
|---|---|
| CsvDumper |
_ch1Std
Declaration
[ObservableProperty]
private double _ch1Std
Field Value
| Type | Description |
|---|---|
| double |
_ch2Dumper
Declaration
private CsvDumper? _ch2Dumper
Field Value
| Type | Description |
|---|---|
| CsvDumper |
_ch2Std
Declaration
[ObservableProperty]
private double _ch2Std
Field Value
| Type | Description |
|---|---|
| double |
_counter
Declaration
private int _counter
Field Value
| Type | Description |
|---|---|
| int |
_fullLagRange
Declaration
private bool _fullLagRange
Field Value
| Type | Description |
|---|---|
| bool |
_inputFlat
Declaration
[ObservableProperty]
private bool _inputFlat
Field Value
| Type | Description |
|---|---|
| bool |
_maxLag
Declaration
[ObservableProperty]
private int _maxLag
Field Value
| Type | Description |
|---|---|
| int |
_processEveryN
Declaration
[ObservableProperty]
private int _processEveryN
Field Value
| Type | Description |
|---|---|
| int |
_resourcesDisposed
Declaration
private bool _resourcesDisposed
Field Value
| Type | Description |
|---|---|
| bool |
_selectedChannel1
Declaration
private int _selectedChannel1
Field Value
| Type | Description |
|---|---|
| int |
_selectedChannel2
Declaration
private int _selectedChannel2
Field Value
| Type | Description |
|---|---|
| int |
_statusMessage
Declaration
[ObservableProperty]
private string _statusMessage
Field Value
| Type | Description |
|---|---|
| string |
_updatesComputed
Declaration
[ObservableProperty]
private long _updatesComputed
Field Value
| Type | Description |
|---|---|
| long |
Properties
BufferLen
Declaration
[ExcludeFromCodeCoverage]
public int BufferLen { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
Ch1Std
Declaration
[ExcludeFromCodeCoverage]
public double Ch1Std { get; set; }
Property Value
| Type | Description |
|---|---|
| double |
Ch2Std
Declaration
[ExcludeFromCodeCoverage]
public double Ch2Std { get; set; }
Property Value
| Type | Description |
|---|---|
| double |
ChannelCount
Declaration
public int ChannelCount { get; private set; }
Property Value
| Type | Description |
|---|---|
| int |
CorrelogramOverTime
Declaration
public SpectrogramMonitor CorrelogramOverTime { get; }
Property Value
| Type | Description |
|---|---|
| SpectrogramMonitor |
DumpFilePrefix
File name (without extension) this block records under. Defaults to Name, which is unique within a pipeline; override only where a block writes something the block name does not describe.
Declaration
protected override string DumpFilePrefix { get; }
Property Value
| Type | Description |
|---|---|
| string |
Overrides
Remarks
This is the single file-name authority for configuration-driven and UI-driven recording, ensuring both paths write the block to the same destination.
HighPassWindow
Declaration
public int HighPassWindow { get; private set; }
Property Value
| Type | Description |
|---|---|
| int |
InputFlat
Declaration
[ExcludeFromCodeCoverage]
public bool InputFlat { get; set; }
Property Value
| Type | Description |
|---|---|
| bool |
JsonTypeName
Block type identifier for JSON serialization. Override for a custom name.
Declaration
protected override string JsonTypeName { get; }
Property Value
| Type | Description |
|---|---|
| string |
Overrides
LowPassWindow
Declaration
public int LowPassWindow { get; private set; }
Property Value
| Type | Description |
|---|---|
| int |
MaxLag
Declaration
[ExcludeFromCodeCoverage]
public int MaxLag { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
MinLag
Declaration
public int MinLag { get; private set; }
Property Value
| Type | Description |
|---|---|
| int |
MovMedianWindow
Declaration
public int MovMedianWindow { get; private set; }
Property Value
| Type | Description |
|---|---|
| int |
ProcessEveryN
Declaration
[ExcludeFromCodeCoverage]
public int ProcessEveryN { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
RequiredSamples
Declaration
public int RequiredSamples { get; }
Property Value
| Type | Description |
|---|---|
| int |
SelectedChannel1
Declaration
public int SelectedChannel1 { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
SelectedChannel2
Declaration
public int SelectedChannel2 { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
SnapCh1
Declaration
public SnapshotMonitor SnapCh1 { get; }
Property Value
| Type | Description |
|---|---|
| SnapshotMonitor |
SnapCh2
Declaration
public SnapshotMonitor SnapCh2 { get; }
Property Value
| Type | Description |
|---|---|
| SnapshotMonitor |
SnapXCorr
Declaration
public SnapshotMonitor SnapXCorr { get; }
Property Value
| Type | Description |
|---|---|
| SnapshotMonitor |
StatusMessage
Declaration
[ExcludeFromCodeCoverage]
public string StatusMessage { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
UpdatesComputed
Declaration
[ExcludeFromCodeCoverage]
public long UpdatesComputed { get; set; }
Property Value
| Type | Description |
|---|---|
| long |
UsesLagSummary
Declaration
public bool UsesLagSummary { get; private set; }
Property Value
| Type | Description |
|---|---|
| bool |
Visualization
This block's visualization, or null when it has none.
Declaration
protected override BlockVisualization? Visualization { get; }
Property Value
| Type | Description |
|---|---|
| BlockVisualization |
Overrides
Remarks
Blocks own their scope as a public Viz property rather than inheriting one, so the
base class has no way to reach it. Overriding this is what lets the rate below be wired up
automatically. With correct publication metadata, the bundle derives the time axis for
one vector per publication or fixed-size contiguous sample packets from the feed shape.
When a plot needs a rate that publication frequency and feed shape cannot express (for
example, variable-sized packets or overlapping windows), declare it with
Viz.UpdateSignalRate. An explicit declaration wins over the derived rate. A block
with several bundles must configure each one; this hook exposes only one bundle.
Viz
Declaration
public BlockVisualization Viz { get; }
Property Value
| Type | Description |
|---|---|
| BlockVisualization |
Methods
BuildLagSummary(Vector<double>, int, bool)
Declaration
private Vector<double> BuildLagSummary(Vector<double> correlation, int firstLag, bool flat)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | correlation | |
| int | firstLag | |
| bool | flat |
Returns
| Type | Description |
|---|---|
| Vector<double> |
ComputeAndPublish()
Declaration
private void ComputeAndPublish()
ComputeCrossCorrelation(Vector<double>, Vector<double>, int)
Declaration
internal static Vector<double> ComputeCrossCorrelation(Vector<double> x, Vector<double> y, int maxLag)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | x | |
| Vector<double> | y | |
| int | maxLag |
Returns
| Type | Description |
|---|---|
| Vector<double> |
ComputeCrossCorrelationRange(Vector<double>, Vector<double>, int, int)
Declaration
internal static Vector<double> ComputeCrossCorrelationRange(Vector<double> x, Vector<double> y, int minLag, int maxLag)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | x | |
| Vector<double> | y | |
| int | minLag | |
| int | maxLag |
Returns
| Type | Description |
|---|---|
| Vector<double> |
ConfigureInput(IServiceProvider, JsonModel)
Declaration
public static CrossCorrelation ConfigureInput(IServiceProvider sp, JsonModel m)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceProvider | sp | |
| JsonModel | m |
Returns
| Type | Description |
|---|---|
| CrossCorrelation |
ConfigureLagSummary(IServiceProvider, JsonModel)
Declaration
private static CrossCorrelation ConfigureLagSummary(IServiceProvider sp, JsonModel model)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceProvider | sp | |
| JsonModel | model |
Returns
| Type | Description |
|---|---|
| CrossCorrelation |
Dispose(bool)
Releases managed resources: status subscription, output dispatcher, CSV dumper, subscriber references.
Declaration
protected override void Dispose(bool disposing)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | disposing | true when called from Dispose(). There is no finalizer, so a false pass has nothing to release. |
Overrides
GetJsonParams()
Block-specific parameters for JSON. Override to provide custom parameters.
Declaration
protected override IReadOnlyList<object>? GetJsonParams()
Returns
| Type | Description |
|---|---|
| IReadOnlyList<object> | The values for Params, in the order this block's |
Overrides
GetLagSummaryParams()
Declaration
private IReadOnlyList<object> GetLagSummaryParams()
Returns
| Type | Description |
|---|---|
| IReadOnlyList<object> |
HighPass(Vector<double>, int, int)
Declaration
private static Vector<double> HighPass(Vector<double> signal, int windowSize, int stepSize)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | signal | |
| int | windowSize | |
| int | stepSize |
Returns
| Type | Description |
|---|---|
| Vector<double> |
InitChannelDumpers(IServiceProvider, string?)
Creates CSV dumpers for the two normalized channel curves, mirroring the base InitDumper(IServiceProvider, string?) behaviour (only when Path is set).
Declaration
private void InitChannelDumpers(IServiceProvider sp, string? path)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceProvider | sp | |
| string | path |
MovMax(Vector<double>, int, int)
Declaration
private static Vector<double> MovMax(Vector<double> signal, int windowSize, int stepSize)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | signal | |
| int | windowSize | |
| int | stepSize |
Returns
| Type | Description |
|---|---|
| Vector<double> |
MovingMean(Vector<double>, int)
Declaration
private static Vector<double> MovingMean(Vector<double> signal, int window)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | signal | |
| int | window |
Returns
| Type | Description |
|---|---|
| Vector<double> |
MovingMedian(Vector<double>, int)
Declaration
private static Vector<double> MovingMedian(Vector<double> signal, int window)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | signal | |
| int | window |
Returns
| Type | Description |
|---|---|
| Vector<double> |
Normalize(Vector<double>)
Declaration
private static Vector<double> Normalize(Vector<double> signal)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | signal |
Returns
| Type | Description |
|---|---|
| Vector<double> |
OnBufferLenChanged(int)
Executes the logic for when BufferLen just changed.
Declaration
private void OnBufferLenChanged(int value)
Parameters
| Type | Name | Description |
|---|---|---|
| int | value | The new property value that was set. |
Remarks
This method is invoked right after the value of BufferLen is changed.
OnBufferLenChanged(int, int)
Executes the logic for when BufferLen just changed.
Declaration
private void OnBufferLenChanged(int oldValue, int newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| int | oldValue | The previous property value that was replaced. |
| int | newValue | The new property value that was set. |
Remarks
This method is invoked right after the value of BufferLen is changed.
OnBufferLenChanging(int)
Executes the logic for when BufferLen is changing.
Declaration
private void OnBufferLenChanging(int value)
Parameters
| Type | Name | Description |
|---|---|---|
| int | value | The new property value being set. |
Remarks
This method is invoked right before the value of BufferLen is changed.
OnBufferLenChanging(int, int)
Executes the logic for when BufferLen is changing.
Declaration
private void OnBufferLenChanging(int oldValue, int newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| int | oldValue | The previous property value that is being replaced. |
| int | newValue | The new property value being set. |
Remarks
This method is invoked right before the value of BufferLen is changed.
OnCh1StdChanged(double)
Executes the logic for when Ch1Std just changed.
Declaration
private void OnCh1StdChanged(double value)
Parameters
| Type | Name | Description |
|---|---|---|
| double | value | The new property value that was set. |
Remarks
This method is invoked right after the value of Ch1Std is changed.
OnCh1StdChanged(double, double)
Executes the logic for when Ch1Std just changed.
Declaration
private void OnCh1StdChanged(double oldValue, double newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| double | oldValue | The previous property value that was replaced. |
| double | newValue | The new property value that was set. |
Remarks
This method is invoked right after the value of Ch1Std is changed.
OnCh1StdChanging(double)
Executes the logic for when Ch1Std is changing.
Declaration
private void OnCh1StdChanging(double value)
Parameters
| Type | Name | Description |
|---|---|---|
| double | value | The new property value being set. |
Remarks
This method is invoked right before the value of Ch1Std is changed.
OnCh1StdChanging(double, double)
Executes the logic for when Ch1Std is changing.
Declaration
private void OnCh1StdChanging(double oldValue, double newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| double | oldValue | The previous property value that is being replaced. |
| double | newValue | The new property value being set. |
Remarks
This method is invoked right before the value of Ch1Std is changed.
OnCh2StdChanged(double)
Executes the logic for when Ch2Std just changed.
Declaration
private void OnCh2StdChanged(double value)
Parameters
| Type | Name | Description |
|---|---|---|
| double | value | The new property value that was set. |
Remarks
This method is invoked right after the value of Ch2Std is changed.
OnCh2StdChanged(double, double)
Executes the logic for when Ch2Std just changed.
Declaration
private void OnCh2StdChanged(double oldValue, double newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| double | oldValue | The previous property value that was replaced. |
| double | newValue | The new property value that was set. |
Remarks
This method is invoked right after the value of Ch2Std is changed.
OnCh2StdChanging(double)
Executes the logic for when Ch2Std is changing.
Declaration
private void OnCh2StdChanging(double value)
Parameters
| Type | Name | Description |
|---|---|---|
| double | value | The new property value being set. |
Remarks
This method is invoked right before the value of Ch2Std is changed.
OnCh2StdChanging(double, double)
Executes the logic for when Ch2Std is changing.
Declaration
private void OnCh2StdChanging(double oldValue, double newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| double | oldValue | The previous property value that is being replaced. |
| double | newValue | The new property value being set. |
Remarks
This method is invoked right before the value of Ch2Std is changed.
OnInputFlatChanged(bool)
Executes the logic for when InputFlat just changed.
Declaration
private void OnInputFlatChanged(bool value)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | value | The new property value that was set. |
Remarks
This method is invoked right after the value of InputFlat is changed.
OnInputFlatChanged(bool, bool)
Executes the logic for when InputFlat just changed.
Declaration
private void OnInputFlatChanged(bool oldValue, bool newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | oldValue | The previous property value that was replaced. |
| bool | newValue | The new property value that was set. |
Remarks
This method is invoked right after the value of InputFlat is changed.
OnInputFlatChanging(bool)
Executes the logic for when InputFlat is changing.
Declaration
private void OnInputFlatChanging(bool value)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | value | The new property value being set. |
Remarks
This method is invoked right before the value of InputFlat is changed.
OnInputFlatChanging(bool, bool)
Executes the logic for when InputFlat is changing.
Declaration
private void OnInputFlatChanging(bool oldValue, bool newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| bool | oldValue | The previous property value that is being replaced. |
| bool | newValue | The new property value being set. |
Remarks
This method is invoked right before the value of InputFlat is changed.
OnMaxLagChanged(int)
Executes the logic for when MaxLag just changed.
Declaration
private void OnMaxLagChanged(int value)
Parameters
| Type | Name | Description |
|---|---|---|
| int | value | The new property value that was set. |
Remarks
This method is invoked right after the value of MaxLag is changed.
OnMaxLagChanged(int, int)
Executes the logic for when MaxLag just changed.
Declaration
private void OnMaxLagChanged(int oldValue, int newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| int | oldValue | The previous property value that was replaced. |
| int | newValue | The new property value that was set. |
Remarks
This method is invoked right after the value of MaxLag is changed.
OnMaxLagChanging(int)
Executes the logic for when MaxLag is changing.
Declaration
private void OnMaxLagChanging(int value)
Parameters
| Type | Name | Description |
|---|---|---|
| int | value | The new property value being set. |
Remarks
This method is invoked right before the value of MaxLag is changed.
OnMaxLagChanging(int, int)
Executes the logic for when MaxLag is changing.
Declaration
private void OnMaxLagChanging(int oldValue, int newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| int | oldValue | The previous property value that is being replaced. |
| int | newValue | The new property value being set. |
Remarks
This method is invoked right before the value of MaxLag is changed.
OnProcessEveryNChanged(int)
Executes the logic for when ProcessEveryN just changed.
Declaration
private void OnProcessEveryNChanged(int value)
Parameters
| Type | Name | Description |
|---|---|---|
| int | value | The new property value that was set. |
Remarks
This method is invoked right after the value of ProcessEveryN is changed.
OnProcessEveryNChanged(int, int)
Executes the logic for when ProcessEveryN just changed.
Declaration
private void OnProcessEveryNChanged(int oldValue, int newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| int | oldValue | The previous property value that was replaced. |
| int | newValue | The new property value that was set. |
Remarks
This method is invoked right after the value of ProcessEveryN is changed.
OnProcessEveryNChanging(int)
Executes the logic for when ProcessEveryN is changing.
Declaration
private void OnProcessEveryNChanging(int value)
Parameters
| Type | Name | Description |
|---|---|---|
| int | value | The new property value being set. |
Remarks
This method is invoked right before the value of ProcessEveryN is changed.
OnProcessEveryNChanging(int, int)
Executes the logic for when ProcessEveryN is changing.
Declaration
private void OnProcessEveryNChanging(int oldValue, int newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| int | oldValue | The previous property value that is being replaced. |
| int | newValue | The new property value being set. |
Remarks
This method is invoked right before the value of ProcessEveryN is changed.
OnReceive(object, object)
Processes incoming data from an upstream block. Must be implemented by derived classes.
Declaration
protected override void OnReceive(object sender, object value)
Parameters
| Type | Name | Description |
|---|---|---|
| object | sender | The publishing block, or whatever else delivered the value. |
| object | value | The payload. Blocks are wired by config rather than by type, so an implementation has to check the run-time type and reject or handle a shape it cannot use. Status is updated automatically from publication activity; it is not a per-value validation result. |
Overrides
Remarks
Called on the dispatching thread, not the UI thread.
OnStatusMessageChanged(string)
Executes the logic for when StatusMessage just changed.
Declaration
private void OnStatusMessageChanged(string value)
Parameters
| Type | Name | Description |
|---|---|---|
| string | value | The new property value that was set. |
Remarks
This method is invoked right after the value of StatusMessage is changed.
OnStatusMessageChanged(string?, string)
Executes the logic for when StatusMessage just changed.
Declaration
private void OnStatusMessageChanged(string? oldValue, string newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| string | oldValue | The previous property value that was replaced. |
| string | newValue | The new property value that was set. |
Remarks
This method is invoked right after the value of StatusMessage is changed.
OnStatusMessageChanging(string)
Executes the logic for when StatusMessage is changing.
Declaration
private void OnStatusMessageChanging(string value)
Parameters
| Type | Name | Description |
|---|---|---|
| string | value | The new property value being set. |
Remarks
This method is invoked right before the value of StatusMessage is changed.
OnStatusMessageChanging(string?, string)
Executes the logic for when StatusMessage is changing.
Declaration
private void OnStatusMessageChanging(string? oldValue, string newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| string | oldValue | The previous property value that is being replaced. |
| string | newValue | The new property value being set. |
Remarks
This method is invoked right before the value of StatusMessage is changed.
OnUpdatesComputedChanged(long)
Executes the logic for when UpdatesComputed just changed.
Declaration
private void OnUpdatesComputedChanged(long value)
Parameters
| Type | Name | Description |
|---|---|---|
| long | value | The new property value that was set. |
Remarks
This method is invoked right after the value of UpdatesComputed is changed.
OnUpdatesComputedChanged(long, long)
Executes the logic for when UpdatesComputed just changed.
Declaration
private void OnUpdatesComputedChanged(long oldValue, long newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| long | oldValue | The previous property value that was replaced. |
| long | newValue | The new property value that was set. |
Remarks
This method is invoked right after the value of UpdatesComputed is changed.
OnUpdatesComputedChanging(long)
Executes the logic for when UpdatesComputed is changing.
Declaration
private void OnUpdatesComputedChanging(long value)
Parameters
| Type | Name | Description |
|---|---|---|
| long | value | The new property value being set. |
Remarks
This method is invoked right before the value of UpdatesComputed is changed.
OnUpdatesComputedChanging(long, long)
Executes the logic for when UpdatesComputed is changing.
Declaration
private void OnUpdatesComputedChanging(long oldValue, long newValue)
Parameters
| Type | Name | Description |
|---|---|---|
| long | oldValue | The previous property value that is being replaced. |
| long | newValue | The new property value being set. |
Remarks
This method is invoked right before the value of UpdatesComputed is changed.
ProcessConfigured(Vector<double>)
Declaration
internal Vector<double> ProcessConfigured(Vector<double> input)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | input |
Returns
| Type | Description |
|---|---|
| Vector<double> |
ReadChannel(Matrix<double>, int, int)
Declaration
private double ReadChannel(Matrix<double> values, int row, int channel)
Parameters
| Type | Name | Description |
|---|---|---|
| Matrix<double> | values | |
| int | row | |
| int | channel |
Returns
| Type | Description |
|---|---|
| double |
ReadChannel(Vector<double>, int, int)
Declaration
private double ReadChannel(Vector<double> values, int offset, int channel)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | values | |
| int | offset | |
| int | channel |
Returns
| Type | Description |
|---|---|
| double |
SelectChannel(ref int, int, string)
Declaration
private void SelectChannel(ref int field, int value, string property)
Parameters
| Type | Name | Description |
|---|---|---|
| int | field | |
| int | value | |
| string | property |
Std(Vector<double>)
Declaration
private static double Std(Vector<double> s)
Parameters
| Type | Name | Description |
|---|---|---|
| Vector<double> | s |
Returns
| Type | Description |
|---|---|
| double |
TrimBuffers()
Declaration
private void TrimBuffers()