InertialMeasurementUnit.h
Go to the documentation of this file.
1/*
2 * This file is part of ArmarX.
3 *
4 * Copyright (C) 2012-2016, High Performance Humanoid Technologies (H2T), Karlsruhe Institute of Technology (KIT), all rights reserved.
5 *
6 * ArmarX is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 *
10 * ArmarX is distributed in the hope that it will be useful, but
11 * WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 *
18 * @package RobotAPI::ArmarXObjects::InertialMeasurementUnit
19 * @author Markus Grotz ( markus-grotz at web dot de )
20 * @date 2015
21 * @copyright http://www.gnu.org/licenses/gpl-2.0.txt
22 * GNU General Public License
23 */
24
25#pragma once
26
27
29
30#include <RobotAPI/interface/units/InertialMeasurementUnit.h>
31
32#include "SensorActorUnit.h"
33
34namespace armarx
35{
36 /**
37 * \class InertialMeasurementUnitPropertyDefinitions
38 * \brief
39 */
41 {
42 public:
45 {
47 "IMUTopicName", "IMUValues", "Name of the IMU Topic.");
48 }
49 };
50
51 /**
52 * \class InertialMeasurementUnit
53 * \ingroup RobotAPI-SensorActorUnits
54 * \brief Base unit for %IMU sensors.
55 */
57 virtual public armarx::InertialMeasurementUnitInterface,
58 virtual public armarx::SensorActorUnit
59 {
60 public:
61 /**
62 * \see armarx::ManagedIceObject::getDefaultName()
63 */
64 std::string
65 getDefaultName() const override
66 {
67 return "InertialMeasurementUnit";
68 }
69
70
71 protected:
72 /**
73 * \see armarx::ManagedIceObject::onInitComponent()
74 */
75 void onInitComponent() override;
76
77 /**
78 * \see armarx::ManagedIceObject::onConnectComponent()
79 */
80 void onConnectComponent() override;
81
82 /**
83 * \see armarx::ManagedIceObject::onDisconnectComponent()
84 */
85 void onDisconnectComponent() override;
86
87 /**
88 * \see armarx::ManagedIceObject::onExitComponent()
89 */
90 void onExitComponent() override;
91
92
93 /**
94 * \see PropertyUser::createPropertyDefinitions()
95 */
97
98
99 virtual void onInitIMU() = 0;
100 virtual void onStartIMU() = 0;
101 virtual void onExitIMU() = 0;
102
103 InertialMeasurementUnitListenerPrx IMUTopicPrx;
104 };
105} // namespace armarx
ComponentPropertyDefinitions(std::string prefix, bool hasObjectNameParameter=true)
Definition Component.cpp:46
PropertyDefinitionsPtr createPropertyDefinitions() override
InertialMeasurementUnitListenerPrx IMUTopicPrx
std::string getDefaultName() const override
std::string prefix
Prefix of the properties such as namespace, domain, component name, etc.
PropertyDefinition< PropertyType > & defineOptionalProperty(const std::string &name, PropertyType defaultValue, const std::string &description="", PropertyDefinitionBase::PropertyConstness constness=PropertyDefinitionBase::eConstant)
Base Class for SensorActorUnits.
This file offers overloads of toIce() and fromIce() functions for STL container types.
IceUtil::Handle< class PropertyDefinitionContainer > PropertyDefinitionsPtr
PropertyDefinitions smart pointer type.