|
LaserProxy Class Reference
[Proxies]
#include <playerclient.h>
Inherits ClientProxy.
List of all members.
Detailed Description
The LaserProxy class is used to control a laser device. The latest scan data is held in two arrays: ranges and intensity . The laser scan range, resolution and so on can be configured using the Configure() method.
Constructor & Destructor Documentation
LaserProxy::LaserProxy |
( |
PlayerClient * |
pc, |
|
|
unsigned short |
index, |
|
|
unsigned char |
access = 'c' |
|
) |
[inline] |
|
|
Constructor. Leave the access field empty to start unconnected. |
Member Function Documentation
int LaserProxy::SetLaserState |
( |
const unsigned char |
state |
) |
|
|
|
Enable/disable the laser. Set state to 1 to enable, 0 to disable. Note that when laser is disabled the client will still receive laser data, but the ranges will always be the last value read from the laser before it was disabled. Returns 0 on success, -1 if there is a problem. Note: The sicklms200 driver currently does not implement this feature. |
int LaserProxy::Configure |
( |
double |
min_angle, |
|
|
double |
max_angle, |
|
|
unsigned int |
scan_res, |
|
|
unsigned int |
range_res, |
|
|
bool |
intensity |
|
) |
|
|
int LaserProxy::GetConfigure |
( |
|
) |
|
|
|
Get the current laser configuration; it is read into the relevant class attributes. Returns the 0 on success, or -1 of there is a problem. |
int LaserProxy::RangeCount |
( |
|
) |
[inline] |
|
|
Get the number of range/intensity readings.
|
double LaserProxy::Ranges |
( |
int |
index |
) |
[inline] |
|
|
An alternate way to access the range data.
|
double LaserProxy::MinLeft |
( |
|
) |
[inline] |
|
double LaserProxy::MinRight |
( |
|
) |
[inline] |
|
double LaserProxy::operator[] |
( |
unsigned int |
index |
) |
[inline] |
|
|
Range access operator. This operator provides an alternate way of access the range data. For example, given an LaserProxy named lp , the following expressions are equivalent: lp.ranges [0], lp.Ranges(0) , and lp [0]. |
void LaserProxy::FillData |
( |
player_msghdr_t |
hdr, |
|
|
const char * |
buffer |
|
) |
[virtual] |
|
|
All proxies must provide this method. It is used internally to parse new data when it is received.
Reimplemented from ClientProxy. |
void LaserProxy::Print |
( |
|
) |
[virtual] |
|
|
Print out the current configuration and laser range/intensity data.
Reimplemented from ClientProxy. |
void LaserProxy::PrintConfig |
( |
|
) |
|
|
|
Print out the current configuration.
|
Member Data Documentation
|
Number of points in scan.
|
|
Angular resolution of scan (radians) |
|
Scan range for the latest set of data (radians) |
|
Scan range for the latest set of data (radians) |
|
Range resolution of scan (mm).
|
|
Whether or not reflectance (i.e., intensity) values are being returned.
|
|
Scan data (polar): range (m) and bearing (radians).
|
|
Scan data (Cartesian): x,y (m).
|
|
The reflected intensity values (arbitrary units in range 0-7).
|
The documentation for this class was generated from the following file:
Generated on Tue May 3 14:15:51 2005 for Player by 1.3.6
|