##

AltimeterSensor.hh
Go to the documentation of this file.
/*
* Copyright (C) 2015 Open Source Robotics Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
#ifndef _GAZEBO_SENSORS_ALTIMETERSENSOR_HH_
#define _GAZEBO_SENSORS_ALTIMETERSENSOR_HH_
#include <string>
#include <sdf/sdf.hh>
#include "gazebo/sensors/Sensor.hh"
#include "gazebo/physics/PhysicsTypes.hh"
#include "gazebo/sensors/SensorTypes.hh"
#include "gazebo/transport/TransportTypes.hh"
#include "gazebo/util/system.hh"
namespace gazebo
{
namespace sensors
{
// Forward declare private data class
class AltimeterSensorPrivate;
class GZ_SENSORS_VISIBLE AltimeterSensor: public Sensor
{
public: AltimeterSensor();
public: virtual ~AltimeterSensor();
// Documentation inherited
public: virtual void Load(const std::string &_worldName,
sdf::ElementPtr _sdf);
// Documentation inherited
public: virtual void Load(const std::string &_worldName);
// Documentation inherited
public: virtual void Init();
// Documentation inherited
public: virtual std::string GetTopic() const;
// Documentation inherited
protected: virtual bool UpdateImpl(const bool _force);
// Documentation inherited
public: virtual void Fini();
public: double Altitude() const;
public: double VerticalVelocity() const;
public: double ReferenceAltitude() const;
public: void SetReferenceAltitude(const double _refAlt);
private: std::unique_ptr<AltimeterSensorPrivate> dataPtr;
};
}
}
#endif
gazebo::sensors::AltimeterSensor::GetTopic
virtual std::string GetTopic() const
gazebo
Forward declarations for the common classes.
Definition: Animation.hh:26
sensors
sensors
Definition: SensorManager.hh:35
TransportTypes.hh
Forward declarations for transport.
gazebo::sensors::AltimeterSensor::Altitude
double Altitude() const
Accessor for current vertical position.
SensorTypes.hh
Forward declarations and typedefs for sensors.
system.hh
PhysicsTypes.hh
default namespace for gazebo
Sensor.hh
gazebo::sensors::AltimeterSensor::SetReferenceAltitude
void SetReferenceAltitude(const double _refAlt)
Accessor for current vertical velocity.
gazebo::sensors::AltimeterSensor::VerticalVelocity
double VerticalVelocity() const
Accessor for current vertical velocity.
gazebo::sensors::AltimeterSensor::ReferenceAltitude
double ReferenceAltitude() const
Accessor for the reference altitude.
gazebo::sensors::AltimeterSensor::AltimeterSensor
AltimeterSensor()
Constructor.
gazebo::sensors::AltimeterSensor::Init
virtual void Init()
Initialize the sensor.
gazebo::msgs::Init
GAZEBO_VISIBLE void Init(google::protobuf::Message &_message, const std::string &_id="")
Initialize a message.
gazebo::sensors::AltimeterSensor::Fini
virtual void Fini()
Finalize the sensor.
gazebo::sensors::AltimeterSensor::~AltimeterSensor
virtual ~AltimeterSensor()
Destructor.
gazebo::sensors::Sensor
Base class for sensors.
Definition: Sensor.hh:51
gazebo::sensors::AltimeterSensor::UpdateImpl
virtual bool UpdateImpl(const bool _force)
This gets overwritten by derived sensor types.
gazebo::sensors::AltimeterSensor::Load
virtual void Load(const std::string &_worldName, sdf::ElementPtr _sdf)
Load the sensor with SDF parameters.
gazebo::sensors::AltimeterSensor
AltimeterSensor to provide vertical position and velocity.
Definition: AltimeterSensor.hh:42