Class
List
Hierarchy
Modules
Common
Events
Math
Messages
Physics
Rendering
Sensors
Transport
Links
Gazebo Website
Wiki
Tutorials
Download
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
gazebo
sensors
RFIDSensor.hh
Go to the documentation of this file.
1
/* Copyright (C) 2012
2
* Jonas Mellin & Zakiruz Zaman
3
* Licensed under the Apache License, Version 2.0 (the "License");
4
* you may not use this file except in compliance with the License.
5
* You may obtain a copy of the License at
6
*
7
* http://www.apache.org/licenses/LICENSE-2.0
8
*
9
* Unless required by applicable law or agreed to in writing, software
10
* distributed under the License is distributed on an "AS IS" BASIS,
11
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12
* See the License for the specific language governing permissions and
13
* limitations under the License.
14
*/
15
/* Desc: Gazebo RFID Sensor
16
* Author: Jonas Mellin & Zakiruz Zaman
17
* Date: 6th December 2011
18
*/
19
20
#ifndef _RFIDSENSOR_HH_
21
#define _RFIDSENSOR_HH_
22
23
#include <vector>
24
#include <string>
25
26
#include "
gazebo/physics/PhysicsTypes.hh
"
27
28
#include "
gazebo/transport/TransportTypes.hh
"
29
30
#include "
gazebo/math/Pose.hh
"
31
32
#include "
gazebo/sensors/Sensor.hh
"
33
34
namespace
gazebo
35
{
38
namespace
sensors
39
{
40
class
RFIDTag;
41
44
47
class
RFIDSensor
:
public
Sensor
48
{
50
public
:
RFIDSensor
();
51
53
public
:
virtual
~RFIDSensor
();
54
55
// Documentation inherited
56
public
:
virtual
void
Load
(
const
std::string &_worldName,
57
sdf::ElementPtr
_sdf);
58
59
// Documentation inherited
60
public
:
virtual
void
Load
(
const
std::string &_worldName);
61
62
// Documentation inherited
63
public
:
virtual
void
Init
();
64
65
// Documentation inherited
66
public
:
void
AddTag
(
RFIDTag
*_tag);
67
68
protected
:
virtual
void
UpdateImpl
(
bool
_force);
69
70
// Documentation inherited
71
public
:
virtual
void
Fini
();
72
75
private
:
void
EvaluateTags();
76
80
private
:
bool
CheckTagRange(
const
math::Pose
&_pose);
81
85
// private: bool CheckRayIntersection(const math::Pose &_pose);
86
88
private
:
physics::EntityPtr
entity;
89
91
// private: physics::CollisionPtr laserCollision;
92
94
// private: physics::RayShapePtr laserShape;
95
97
private
:
transport::PublisherPtr
scanPub;
98
100
private
: std::vector<RFIDTag*> tags;
101
};
103
}
104
}
105
#endif