70 std::uniform_real_distribution<>*
m_dis;
94 m_rd =
new std::random_device;
96 m_dis =
new std::uniform_real_distribution<>(0, 0.01);
120 bool close()
override;
127 void wall_the_robot(
double siz = 1.0,
double dist = 1.0);
128 void obst_the_robot(
double siz = 1.0,
double dist = 1.0);
129 void trap_the_robot(
double siz = 1.0);
130 void free_the_robot();
133 bool LiangBarsky_clip(
int edgeLeft,
int edgeRight,
int edgeTop,
int edgeBottom,
149 bool read(
yarp::os::ConnectionReader& connection) override;
define control board standard interfaces
contains the definition of a map type
contains the definition of a Vector type
This class is the parameters parser for class FakeLaser.
fakeLaser : fake sensor device driver for testing purposes and reference for IRangefinder2D devices.
FakeLaser(double period=0.02)
yarp::dev::PolyDriver * m_pLoc
yarp::dev::ReturnValue setScanRate(double rate) override
set the scan rate (scans per seconds)
void run() override
Loop function.
yarp::dev::Nav2D::MapGrid2D m_map
bool read(yarp::os::ConnectionReader &connection) override
Read this object from a network connection.
bool acquireDataFromHW() override final
This method should be implemented by the user, and contain the logic to grab data from the hardware.
yarp::dev::Nav2D::ILocalization2D * m_iLoc
yarp::dev::ReturnValue setScanLimits(double min, double max) override
set the scan angular range.
localization_mode_t m_loc_mode
bool threadInit() override
Initialization method.
yarp::dev::ReturnValue setDistanceRange(double min, double max) override
set the device detection range.
yarp::os::BufferedPort< yarp::os::Bottle > * m_loc_port
std::random_device * m_rd
bool open(yarp::os::Searchable &config) override
Open the DeviceDriver.
yarp::dev::ReturnValue setHorizontalResolution(double step) override
get the angular step between two measurements (if available)
std::uniform_real_distribution * m_dis
bool close() override
Close the DeviceDriver.
void threadRelease() override
Release method.
yarp::dev::Nav2D::MapGrid2D m_originally_loaded_map
Interface implemented by all device drivers.
The Lidar2DDeviceBase class.
ILocalization2D interface.
A container for a device driver.
A mini-server for performing network communication in the background.
An abstraction for a periodic thread.
PeriodicThread(double period, ShouldUseSystemClock useSystemClock=ShouldUseSystemClock::No, PeriodicThreadClock clockAccuracy=PeriodicThreadClock::Relative)
Constructor.
void step()
Call this to "step" the thread rather than starting it.
Interface implemented by all objects that can read themselves from the network, such as Bottle object...
A mini-server for network communication.
A base class for nested structures that can be searched.
The main, catch-all namespace for YARP.