Helios++
Helios software for LiDAR simulations
|
Class representing an oscillating mirror beam deflector. More...
#include <OscillatingMirrorBeamDeflector.h>
Public Member Functions | |
OscillatingMirrorBeamDeflector (double scanAngleMax_rad, double scanFreqMax_Hz, double scanFreqMin_Hz, int scanProduct) | |
Constructor for oscillating mirror beam deflector. More... | |
std::shared_ptr< AbstractBeamDeflector > | clone () override |
void | _clone (std::shared_ptr< AbstractBeamDeflector > abd) override |
void | applySettings (std::shared_ptr< ScannerSettings > settings) override |
void | doSimStep () override |
double | computeTurningVelocityOffset () |
Compute the turning velocity offset. More... | |
void | setScanAngle_rad (double scanAngle_rad) override |
void | setScanFreq_Hz (double scanFreq_Hz) override |
![]() | |
AbstractBeamDeflector (double scanAngleMax_rad, double scanFreqMax_Hz, double scanFreqMin_Hz) | |
Base constructor for beam deflectors. More... | |
virtual bool | lastPulseLeftDevice () |
Check if last pulse left device (true) or not (false) More... | |
Rotation | getEmitterRelativeAttitude () |
Get the relative emitter attitude. More... | |
Rotation & | getEmitterRelativeAttitudeByReference () |
Get the relative emitter attitude by referencce. More... | |
Public Attributes | |
int | cfg_device_scanProduct = 1000000 |
Scan product to limit maximum scan angle and the scanning frequency. | |
int | currentScanLinePulse = 0 |
Current scan line pulse. | |
int | cfg_device_turningPulses = 100 |
How many pulses are required for the turning around. More... | |
double | cfg_device_turningPulsesf = 100.0f |
Decimal encoding of cfg_device_turningPulses. More... | |
int | cached_pulsesPerScanline = 0 |
Pulses per scan line. | |
int | cached_thresholdPulse = -1 |
At which pulse step the turning around must be computed. cached_threshold_pulse = cached_pulsesPerScanline - cfg_device_turningPulses. More... | |
int | cached_aHalfThresholdPulse = -1 |
The starting point for first turning around stage on top peak. More... | |
int | cached_halfThresholdPulse = -1 |
The starting point for second turning around stage on top peak. More... | |
int | cached_bHalfThresholdPulse = -1 |
The ending point for second turning around stage on top peak. More... | |
double | cached_halfTurningPulses = -1.0 |
Half of the turning pulses, because they are required to compute turning velocity offset. More... | |
double | cached_offsetScaleFactor = -1.0 |
Offset scale factor used to speed-up turning velocity offset computations. cached_offsetScaleFactor = cached_halfTurningPulses * cached_angleBetweenPulses_rad. More... | |
![]() | |
double | cfg_device_scanFreqMax_Hz = 0 |
Minimum scanning frequency (hertz) | |
double | cfg_device_scanFreqMin_Hz = 0 |
Maximum scanning frequency (hertz) | |
double | cfg_device_scanAngleMax_rad = 0 |
Maximum scanning angle (radians) | |
double | cfg_setting_scanFreq_Hz = 0 |
Scanning frequency (hertz) | |
double | cfg_setting_scanAngle_rad = 0 |
Scanning angle (radians) | |
double | cfg_setting_verticalAngleMin_rad = 0 |
Minimum vertical scanning angle (radians) | |
double | cfg_setting_verticalAngleMax_rad = 0 |
Maximum vertical scanning angle (radians) | |
double | state_currentBeamAngle_rad = 0 |
Current beam angle (radians) | |
double | state_angleDiff_rad = 0 |
Angle differential (radians) | |
double | cached_angleBetweenPulses_rad |
Angle between pulses (radians) | |
Rotation | cached_emitterRelativeAttitude = Rotation(glm::dvec3(1, 0, 0), 0) |
Relative emitter attitude. | |
Class representing an oscillating mirror beam deflector.
|
inline |
Constructor for oscillating mirror beam deflector.
|
overridevirtual |
Reimplemented from AbstractBeamDeflector.
double OscillatingMirrorBeamDeflector::computeTurningVelocityOffset | ( | ) |
Compute the turning velocity offset.
The turning velocity offset can be expressed as a set of 4 equations. For this purpose, let \(l\) be the number of pulses per scan line, \(c\) the current scan line pulse, \(n\) the number of pulses the turning around takes, \(\Delta\) the angle between pulses in radians and \(\epsilon_{n}(x)\) the function corresponding to turning velocity offset.
Equation for down to bottom peak offset:
\[ \left\{\begin{array}{lll} x & = & l - c \\ \epsilon_{n}(x) & = & \frac{n\Delta}{2} \left(1 - \frac{x}{n}\right)^2 \end{array}\right. \]
Equation for up from bottom peak offset:
\[ \left\{\begin{array}{lll} x & = & c \\ \epsilon_{n}(x) & = & \frac{n\Delta}{2} \left(1 - \frac{x}{n}\right)^2 \end{array}\right. \]
Equation for up to top peak offset:
\[ \left\{\begin{array}{lll} x & = & c - \frac{l}{2} + n \\ \epsilon_{n}(x) & = & - \frac{n\Delta}{2} \left(\frac{x}{n}\right)^2 \end{array}\right. \]
Equation for down from top peak offset:
\[ \left\{\begin{array}{lll} x & = & \frac{l}{2} + n - c \\ \epsilon_{n}(x) & = & - \frac{n\Delta}{2} \left(\frac{x}{n}\right)^2 \end{array}\right. \]
The function behavior of oscillating mirror velocity has been taken from: "The geometry of Airborne Laser Scanning in a Kinematical Framework" by Andreas Roncat. See pages 54 to 56 for more information.
|
overridevirtual |
Implements AbstractBeamDeflector.
|
overridevirtual |
Reimplemented from AbstractBeamDeflector.
|
overridevirtual |
Reimplemented from AbstractBeamDeflector.
int OscillatingMirrorBeamDeflector::cached_aHalfThresholdPulse = -1 |
The starting point for first turning around stage on top peak.
int OscillatingMirrorBeamDeflector::cached_bHalfThresholdPulse = -1 |
The ending point for second turning around stage on top peak.
int OscillatingMirrorBeamDeflector::cached_halfThresholdPulse = -1 |
The starting point for second turning around stage on top peak.
double OscillatingMirrorBeamDeflector::cached_halfTurningPulses = -1.0 |
Half of the turning pulses, because they are required to compute turning velocity offset.
double OscillatingMirrorBeamDeflector::cached_offsetScaleFactor = -1.0 |
Offset scale factor used to speed-up turning velocity offset computations. cached_offsetScaleFactor = cached_halfTurningPulses * cached_angleBetweenPulses_rad.
int OscillatingMirrorBeamDeflector::cached_thresholdPulse = -1 |
At which pulse step the turning around must be computed. cached_threshold_pulse = cached_pulsesPerScanline - cfg_device_turningPulses.
int OscillatingMirrorBeamDeflector::cfg_device_turningPulses = 100 |
How many pulses are required for the turning around.
double OscillatingMirrorBeamDeflector::cfg_device_turningPulsesf = 100.0f |
Decimal encoding of cfg_device_turningPulses.