33#include <NDEVR/Device.h>
34#include <NDEVR/StationModel.h>
35#include <NDEVR/Deployment.h>
36#include <NDEVR/GPSPoint.h>
37#include <NDEVR/Matrix.h>
38#include <NDEVR/UUID.h>
107#if NDEVR_STATION_MODEL
111 virtual bool requestStation(
const StationModel& model);
114 [[nodiscard]]
virtual const StationModel& station()
const {
return m_station_model; }
117 [[nodiscard]]
virtual StationModel& station() {
return m_station_model; }
123 virtual bool requestDeployment(
const Deployment& deployment);
126 [[nodiscard]]
virtual const Deployment& deployment()
const {
return m_deployment; }
129 [[nodiscard]]
virtual Deployment& deployment() {
return m_deployment; }
146#if NDEVR_STATION_MODEL
147 StationModel m_station_model;
150 Deployment m_deployment;
uint04 index() const
Returns the primary row index of this object within the DesignObjectBase property table.
Device(const Model &model, LogPtr log, QObject *parent=nullptr)
Constructs a Device from a Model with the given log and optional Qt parent.
A distance encoder is a device that measures distance by generating pulses in response to an object's...
A core class that provides a dynamic effect to an object in a model hierarchy.
A light-weight wrapper that will be a no-op if there is not a valid log reference,...
A core class that represents a node on model hierarchy.
Forward declaration for design object lookup service.
void deploymentSegmentAddedSignal()
Emitted when a deployment segment has been added.
virtual bool requestUsingGPS(bool using_gps)
Requests enabling or disabling GPS-based positioning.
Vertex< 3, fltp08 > m_sensor_location
The physical location of the sensor on the hardware.
virtual void setVelocity(const Vector< 3, fltp08 > &velocity)
Sets the current velocity vector of the sensor.
Vector< 3, fltp08 > m_velocity
The current 3D velocity vector.
Vector< 3, fltp08 > m_acceleration
The current 3D acceleration vector.
virtual bool requestDistanceEncoder(DistanceEncoder *)
Requests attaching a distance encoder to this position sensor.
void update(Time time) override
Updates the position sensor state for the given time.
void deploymentChangedSignal(UUID deployment)
Emitted when the deployment configuration has changed.
virtual void addDeploymentSegment(fltp08 distance)
Adds a deployment segment at the given distance.
void setPosition(const Vertex< 3, fltp08 > &location)
Sets the current position of this sensor.
void setSensorLocation(const Vertex< 3, fltp08 > &location)
Sets the physical location of the sensor on the hardware.
Time m_last_position_time
The timestamp of the last position update.
Vertex< 3, fltp08 > m_position
The current 3D position of this sensor.
bool m_using_gps
Whether GPS-based positioning is currently enabled.
virtual Vector< 3, fltp08 > stdDev() const
Returns the standard deviation of position measurements.
PositionSensor(const Model &name, LogPtr log, QObject *parent=nullptr)
Constructs a PositionSensor with the given model, log, and optional parent.
virtual Vertex< 3, fltp08 > sensorLocation() const
Returns the physical location of the sensor on the hardware.
virtual GNSSQuality gpsQuality() const
Returns the current GNSS fix quality.
virtual Vertex< 3, fltp08 > lastPosition() const
Returns the last known 3D position of this sensor.
void stationChangedSignal(UUID station)
Emitted when the station model has changed.
virtual void setAcceleration(const Vector< 3, fltp08 > &acceleration)
Sets the current acceleration vector of the sensor.
virtual OrientationSensor * orientationSensor() const
Returns the orientation sensor associated with this position sensor, if any.
virtual void removeDeploymentSegment(uint04 index=Constant< uint04 >::Invalid)
Removes a deployment segment at the given index.
virtual bool stationUsedForOffset() const
Returns whether the station model is used for position offset computation.
virtual bool usingGPS() const
Returns whether GPS-based positioning is currently enabled.
virtual DistanceEncoder * distanceEncoder() const
Returns the distance encoder attached to this sensor, if any.
void deploymentSegmentRemovedSignal()
Emitted when a deployment segment has been removed.
Logic for reading or writing to a string or a user friendly, TranslatedString.
Represents a timestamp with utilities for manipulation and conversion.
A universally unique identifier (UUID) is a 128-bit number used to identify information in computer s...
A fixed-size array with N dimensions used as the basis for geometric and mathematical types.
A point in N-dimensional space, used primarily for spatial location information.
The primary namespace for the NDEVR SDK.
uint32_t uint04
-Defines an alias representing a 4 byte, unsigned integer -Can represent exact integer values 0 throu...
double fltp08
Defines an alias representing an 8 byte floating-point number.
GNSSQuality
Describes the quality level of a GNSS position fix.
@ e_invalid
No fix available or fix is invalid.
Defines for a given type (such as sint04, fltp08, UUID, etc) a maximum, minimum, and reserved 'invali...