ST_CM_InstantaneousPhase_InitPars
Function block-specific structure with initialization parameters, which are analyzed when the function block is initialized.
TYPE ST_CM_InstantaneousPhase_InitPars EXTENDS ST_CM_Object_InitPars :
STRUCT
nFFT_Length : UDINT := 512; (* Length of FFT. *)
nWindowLength : UDINT := 400; (* Length of analysis window. *)
eUnwrapMethod : E_CM_UnwrapMethod := eCM_ThresholdUnwrapping; (* Unwrap method for phase values. *)
fPhaseThreshold : LREAL := cCM_MinArgDiv; (* Minimum value for calculating the instantaneous phase. *)
nChannels : UDINT := 1; (* Number of channels. *)
END_STRUCT
END_TYPE
nFFT_Length
is the length of the FFT. It must be greater than one and an integral power of two.nWindowLength
is the length of the analysis window in samples. The length must be greater than one and an even number.eUnwrapMethod
defines the method used for phase-unwrapping with regard to the phase in multiples of2 PI
(see E_CM_UnwrapMethod).fPhaseThreshold
limit value for calculating the instantaneous phase. The value is related to the signal envelope. Interpretation: If the signal level is too low, the calculation of the phase is numerically too uncertain and cannot be evaluated reliably. 0 is then output as the phase.
Requirements
Development environment | Target platform | PLC libraries to include |
---|---|---|
TwinCAT v3.1.4022.25 | PC or CX (x86, x64) | Tc3_CM_Base |