Main MRPT website > C++ reference for MRPT 1.4.0
CImpinjRFID.h
Go to the documentation of this file.
1 /* +---------------------------------------------------------------------------+
2  | Mobile Robot Programming Toolkit (MRPT) |
3  | http://www.mrpt.org/ |
4  | |
5  | Copyright (c) 2005-2016, Individual contributors, see AUTHORS file |
6  | See: http://www.mrpt.org/Authors - All rights reserved. |
7  | Released under BSD License. See details in http://www.mrpt.org/License |
8  +---------------------------------------------------------------------------+ */
9 #ifndef CImpinjRFID_H
10 #define CImpinjRFID_H
11 
15 
18 
19 namespace mrpt
20 {
21  namespace hwdrivers
22  {
23  /** This class implements an interface to an Impinj RFID reader. This object connects to a program that does the actual communication with the receiver. This is done because the manufacturer only provides libraries for C# and Java. The program that runs the device must be started after this object
24  */
26  {
28 
29  private:
30 
31  /** Poses (Antenna 1)
32  */
33  float pose_x_1, pose_y_1, pose_z_1, pose_yaw_1, pose_pitch_1, pose_roll_1;
34 
35  /** Poses (Antenna 2)
36  */
37  float pose_x_2, pose_y_2, pose_z_2, pose_yaw_2, pose_pitch_2, pose_roll_2;
38 
39  /** Server port
40  */
41  int port;
42 
43  /** IP of the module (usually 127.0.0.1)
44  */
45  std::string IPm;
46 
47  /** Reader name
48  */
49  std::string reader_name;
50 
51  /** Server socket (listens for the incoming connection)
52  */
54 
55  /** Client socket (handles the connection to the client)
56  */
58 
59  /** Driver executable path
60  */
61  std::string driver_path;
62 
63  /** Connection status
64  */
65  bool connected;
66 
67  /** start the external driver
68  */
69  void startDriver();
70 
71  static void dummy_startDriver(CImpinjRFID *o);
72 
73 
74  public:
75  /** Default constructor.
76  */
78  virtual ~CImpinjRFID();
79 
80  /** Connect to the reader.
81  */
82  void connect();
83 
84  void doProcess();
85 
86  void initialize();
87 
88 
90  const mrpt::utils::CConfigFileBase &configSource,
91  const std::string &section);
92 
93  /** Gets the information of the tags as a timestamped observation
94  * NOTE: Deprecated, use getObservations instead. See CGenericSensor documentation. This function is kept for internal use of the module
95  * \return Returns true if the observation was correct, and false otherwise
96  * \sa mrpt::hwdrivers::CGenericSensor
97  */
99 
100 
101  /** Close the connection to the reader.
102  */
103  void closeReader();
104  }; // End of class def.
105 
106  } // End of namespace
107 } // End of namespace
108 #endif
CClientTCPSocket.h
mrpt::utils::CServerTCPSocket
A TCP socket that can be wait for client connections to enter.
Definition: CServerTCPSocket.h:28
mrpt::hwdrivers::CImpinjRFID::loadConfig_sensorSpecific
void loadConfig_sensorSpecific(const mrpt::utils::CConfigFileBase &configSource, const std::string &section)
Loads specific configuration for the device from a given source of configuration parameters,...
mrpt::hwdrivers::CImpinjRFID::IPm
std::string IPm
IP of the module (usually 127.0.0.1)
Definition: CImpinjRFID.h:45
mrpt::hwdrivers::CImpinjRFID::dummy_startDriver
static void dummy_startDriver(CImpinjRFID *o)
mrpt::hwdrivers::CImpinjRFID::getObservation
bool getObservation(mrpt::obs::CObservationRFID &obs)
Gets the information of the tags as a timestamped observation NOTE: Deprecated, use getObservations i...
mrpt::hwdrivers::CImpinjRFID::doProcess
void doProcess()
This method will be invoked at a minimum rate of "process_rate" (Hz)
CServerTCPSocket.h
mrpt::utils::CClientTCPSocket
A TCP socket that can be connected to a TCP server, implementing MRPT's CStream interface for passing...
Definition: CClientTCPSocket.h:35
mrpt
This is the global namespace for all Mobile Robot Programming Toolkit (MRPT) libraries.
Definition: CParticleFilter.h:17
mrpt::hwdrivers::CImpinjRFID::~CImpinjRFID
virtual ~CImpinjRFID()
DEFINE_GENERIC_SENSOR
#define DEFINE_GENERIC_SENSOR(class_name)
This declaration must be inserted in all CGenericSensor classes definition, within the class declarat...
Definition: CGenericSensor.h:251
mrpt::hwdrivers::CImpinjRFID::pose_z_2
float pose_z_2
Definition: CImpinjRFID.h:37
mrpt::hwdrivers::CImpinjRFID::connect
void connect()
Connect to the reader.
mrpt::hwdrivers::CImpinjRFID::pose_z_1
float pose_z_1
Definition: CImpinjRFID.h:33
mrpt::hwdrivers::CImpinjRFID::server
mrpt::utils::CServerTCPSocket * server
Server socket (listens for the incoming connection)
Definition: CImpinjRFID.h:53
mrpt::hwdrivers::CImpinjRFID::port
int port
Server port.
Definition: CImpinjRFID.h:41
mrpt::utils::CConfigFileBase
This class allows loading and storing values and vectors of different types from a configuration text...
Definition: CConfigFileBase.h:31
CGenericSensor.h
mrpt::hwdrivers::CImpinjRFID::startDriver
void startDriver()
start the external driver
mrpt::hwdrivers::CImpinjRFID::connected
bool connected
Connection status.
Definition: CImpinjRFID.h:65
mrpt::hwdrivers::CGenericSensor
A generic interface for a wide-variety of sensors designed to be used in the application RawLogGrabbe...
Definition: CGenericSensor.h:64
mrpt::hwdrivers::CImpinjRFID::initialize
void initialize()
This method can or cannot be implemented in the derived class, depending on the need for it.
CConfigFileBase.h
mrpt::hwdrivers::CImpinjRFID
This class implements an interface to an Impinj RFID reader.
Definition: CImpinjRFID.h:26
mrpt::hwdrivers::CImpinjRFID::CImpinjRFID
CImpinjRFID()
Default constructor.
mrpt::obs::CObservationRFID
This represents one or more RFID tags observed by a receiver.
Definition: obs/CObservationRFID.h:29
mrpt::hwdrivers::CImpinjRFID::closeReader
void closeReader()
Close the connection to the reader.
mrpt::hwdrivers::CImpinjRFID::client
mrpt::utils::CClientTCPSocket * client
Client socket (handles the connection to the client)
Definition: CImpinjRFID.h:57
HWDRIVERS_IMPEXP
#define HWDRIVERS_IMPEXP
Definition: hwdrivers_impexp.h:82
CObservationRFID.h
mrpt::hwdrivers::CImpinjRFID::driver_path
std::string driver_path
Driver executable path.
Definition: CImpinjRFID.h:61
mrpt::hwdrivers::CImpinjRFID::reader_name
std::string reader_name
Reader name.
Definition: CImpinjRFID.h:49



Page generated by Doxygen 1.8.20 for MRPT 1.4.0 SVN: at Thu Aug 27 02:40:23 UTC 2020