IoT::Devices

class GNSSSensorRemoteObject

File Information

Library: IoT/Devices
Package: Generated
Header: IoT/Devices/GNSSSensorRemoteObject.h

Description

The interface for GNSS/GPS receivers.

Implementations of this class should also support the following (optional) properties for configuration:

  • positionChangedPeriod (int): the minimum time interval in milliseconds between firings of the positionUpdate event.
  • positionChangedDelta (int): the minimum distance (in meters) the receiver must move before the positionUpdate event is fired again.
  • positionTimeout (int): Timeout in milliseconds after which the positionLost event is fired if no valid position has been received from the GNSS receiver.

Inheritance

Direct Base Classes: IGNSSSensor, Poco::RemotingNG::RemoteObject

All Base Classes: IDevice, IGNSSSensor, Poco::OSP::Service, Poco::RefCountedObject, Poco::RemotingNG::Identifiable, Poco::RemotingNG::RemoteObject

Member Summary

Member Functions: altitude, course, event__positionLost, event__positionUpdate, event__statusChanged, getFeature, getPropertyBool, getPropertyDouble, getPropertyInt, getPropertyInt16, getPropertyInt64, getPropertyString, getPropertyTimestamp, hasFeature, hasProperty, hdop, magneticVariation, position, positionAvailable, remoting__enableEvents, remoting__enableRemoteEvents, remoting__hasEvents, remoting__typeId, setFeature, setPropertyBool, setPropertyDouble, setPropertyInt, setPropertyInt16, setPropertyInt64, setPropertyString, setPropertyTimestamp, speed

Inherited Functions: altitude, course, duplicate, getFeature, getPropertyBool, getPropertyDouble, getPropertyInt, getPropertyInt16, getPropertyInt64, getPropertyString, getPropertyTimestamp, hasFeature, hasProperty, hdop, isA, magneticVariation, mutex, position, positionAvailable, referenceCount, release, remoting__enableEvents, remoting__enableRemoteEvents, remoting__getURI, remoting__hasEvents, remoting__objectId, remoting__setURI, remoting__typeId, setFeature, setPropertyBool, setPropertyDouble, setPropertyInt, setPropertyInt16, setPropertyInt64, setPropertyString, setPropertyTimestamp, speed, type

Types Aliases

Ptr

using Ptr = Poco::AutoPtr < GNSSSensorRemoteObject >;

Constructors

GNSSSensorRemoteObject

GNSSSensorRemoteObject(
    const Poco::RemotingNG::Identifiable::ObjectId & oid,
    Poco::SharedPtr < IoT::Devices::GNSSSensor > pServiceObject
);

Destructor

~GNSSSensorRemoteObject virtual

virtual ~GNSSSensorRemoteObject();

Destroys the GNSSSensorRemoteObject.

Member Functions

altitude virtual inline

virtual double altitude() const;

Returns the current altitude above sea level in meters. Returns -9999 if no altitude is available.

course virtual inline

virtual double course() const;

Returns the current course in degrees [0, 360).

getFeature virtual inline

virtual bool getFeature(
    const std::string & name
) const;

Returns true if the feature with the given name is enabled, or false otherwise.

getPropertyBool virtual inline

virtual bool getPropertyBool(
    const std::string & name
) const;

Returns the value of the device property with the given name.

Throws a Poco::NotFoundException if the property with the given name is unknown.

getPropertyDouble virtual inline

virtual double getPropertyDouble(
    const std::string & name
) const;

Returns the value of the device property with the given name.

Throws a Poco::NotFoundException if the property with the given name is unknown.

getPropertyInt virtual inline

virtual int getPropertyInt(
    const std::string & name
) const;

Returns the value of the device property with the given name.

Throws a Poco::NotFoundException if the property with the given name is unknown.

getPropertyInt16 virtual inline

virtual Poco::Int16 getPropertyInt16(
    const std::string & name
) const;

Returns the value of the device property with the given name.

Throws a Poco::NotFoundException if the property with the given name is unknown.

getPropertyInt64 virtual inline

virtual Poco::Int64 getPropertyInt64(
    const std::string & name
) const;

Returns the value of the device property with the given name.

Throws a Poco::NotFoundException if the property with the given name is unknown.

getPropertyString virtual inline

virtual std::string getPropertyString(
    const std::string & name
) const;

Returns the value of the device property with the given name.

Throws a Poco::NotFoundException if the property with the given name is unknown.

getPropertyTimestamp virtual inline

virtual Poco::Timestamp getPropertyTimestamp(
    const std::string & name
) const;

Returns the value of the device property with the given name.

Throws a Poco::NotFoundException if the property with the given name is unknown.

hasFeature virtual inline

virtual bool hasFeature(
    const std::string & name
) const;

Returns true if the feature with the given name is known, or false otherwise.

hasProperty virtual inline

virtual bool hasProperty(
    const std::string & name
) const;

Returns true if the property with the given name exists, or false otherwise.

hdop virtual inline

virtual double hdop() const;

Returns the Horizontal Dilution Of Precision (HDOP) in meters, or -9999 if no HDOP value is available.

magneticVariation virtual inline

virtual double magneticVariation() const;

Returns the current magnetic variation in degrees [0, 360). Returns -1 if no magnetic variation is available.

position virtual inline

IoT::Devices::LatLon position() const;

Returns the last obtained position.

If no position is available, latitude and longitude will both be 0. To disambiguate with a real position, also check positionAvailable().

positionAvailable virtual inline

virtual bool positionAvailable() const;

Returns true if a valid position is available.

remoting__enableEvents virtual

virtual std::string remoting__enableEvents(
    Poco::RemotingNG::Listener::Ptr pListener,
    bool enable = bool (true)
);

remoting__enableRemoteEvents virtual

virtual void remoting__enableRemoteEvents(
    const std::string & protocol
);

remoting__hasEvents virtual

virtual bool remoting__hasEvents() const;

remoting__typeId virtual inline

virtual const Poco::RemotingNG::Identifiable::TypeId & remoting__typeId() const;

setFeature virtual inline

virtual void setFeature(
    const std::string & name,
    bool enable
);

Enables or disables the feature with the given name.

Which features are supported is defined by the actual device implementation.

setPropertyBool virtual inline

virtual void setPropertyBool(
    const std::string & name,
    bool value
);

Sets a device property.

Which properties are supported is defined by the actual device implementation.

setPropertyDouble virtual inline

virtual void setPropertyDouble(
    const std::string & name,
    double value
);

Sets a device property.

Which properties are supported is defined by the actual device implementation.

setPropertyInt virtual inline

virtual void setPropertyInt(
    const std::string & name,
    int value
);

Sets a device property.

Which properties are supported is defined by the actual device implementation.

setPropertyInt16 virtual inline

virtual void setPropertyInt16(
    const std::string & name,
    Poco::Int16 value
);

Sets a device property.

Which properties are supported is defined by the actual device implementation.

setPropertyInt64 virtual inline

virtual void setPropertyInt64(
    const std::string & name,
    Poco::Int64 value
);

Sets a device property.

Which properties are supported is defined by the actual device implementation.

setPropertyString virtual inline

virtual void setPropertyString(
    const std::string & name,
    const std::string & value
);

Sets a device property.

Which properties are supported is defined by the actual device implementation.

setPropertyTimestamp virtual inline

virtual void setPropertyTimestamp(
    const std::string & name,
    Poco::Timestamp value
);

Sets a device property.

Which properties are supported is defined by the actual device implementation.

speed virtual inline

virtual double speed() const;

Returns the current speed in nautical knots. If no speed is available, returns -1.

event__positionLost protected

void event__positionLost();

event__positionUpdate protected

void event__positionUpdate(
    const IoT::Devices::PositionUpdate & data
);

event__statusChanged protected

void event__statusChanged(
    const IoT::Devices::DeviceStatusChange & data
);

Securely control IoT edge devices from anywhere   Connect a Device