Class CIbeoLuxETH
Defined in File CIbeoLuxETH.h
Inheritance Relationships
Base Type
public mrpt::hwdrivers::CGenericSensor(Class CGenericSensor)
Class Documentation
-
class CIbeoLuxETH : public mrpt::hwdrivers::CGenericSensor
This “software driver” implements the communication protocol for interfacing a Ibeo Lux laser scanners through an ethernet controller. This class does not need to be bind, i.e. you do not need to call C2DRangeFinderAbstract::bindIO. Connection is established when user call the turnOn() method. You can pass to the class’s constructor the Lux’s ip address and port. Device will NOT be configured. Configuration has to be done separately.
To get a laser scan you must proceed like that :
CIbeoLuxETH laser(string("192.168.0.10"), 1234); laser.turnOn(); bool isOutObs, hardwareError; CObservation2DRangeScan outObs; laser.doProcessSimple(isOutObs, outObs, hardwareError);
Note
This class was contributed by Adrien Barral - Robopec (France)
Note
And modified by Jan Girlich - University of Hamburg
Public Functions
-
CIbeoLuxETH(std::string _ip = std::string("10.152.36.93"), unsigned int _port = 12002)
Constructor. Note that there is default arguments, here you can customize IP Adress and TCP Port of your device.
-
~CIbeoLuxETH() override
Destructor. Close communcation with the device, and free memory.
-
virtual void doProcess() override
This function acquire a laser scan from the device. If an error occurred, hardwareError will be set to true. The new laser scan will be stored in the outObservation argument.
- Throws:
This – method throw exception if the frame received from the LMS 100 contain the following bad parameters :
Status is not OK
Data in the scan aren’t DIST1 (may be RSSIx or DIST2).
-
virtual void initialize() override
This method can or cannot be implemented in the derived class, depending on the need for it.
- Throws:
This – method must throw an exception with a descriptive message if some critical error is found.
-
void makeCommandHeader(unsigned char *buffer)
-
void makeStartCommand(unsigned char *buffer)
-
void makeStopCommand(unsigned char *buffer)
-
void makeTypeCommand(unsigned char *buffer)
Protected Functions
-
virtual void loadConfig_sensorSpecific(const mrpt::config::CConfigFileBase &configSource, const std::string &iniSection) override
Load sensor pose on the robot, or keep the default sensor pose.
-
CIbeoLuxETH(std::string _ip = std::string("10.152.36.93"), unsigned int _port = 12002)