![]() |
Laelaps
2.3.5
RoadNarrows Robotics Small Outdoor Mobile Robot Project
|
VL6180 Time of Flight Array Class. More...
#include <laeVL6180.h>
Public Types | |
typedef std::vector< sensor::vl6180::LaeVL6180Mux * > | VecToFSensors |
time-of-flight sensor vector type | |
Public Member Functions | |
LaeVL6180MuxArray (laelaps::LaeI2C &i2cBus) | |
Initialization constructor. More... | |
virtual | ~LaeVL6180MuxArray () |
Destructor. | |
virtual int | getInterfaceVersion (uint_t &uVerMajor, uint_t &uVerMinor, uint_t &uFwVer) |
Get interface version. More... | |
virtual void | clearSensedData () |
Clear sensed data. | |
virtual int | configure (const laelaps::LaeDesc &desc) |
Configure sensor array from product description. More... | |
virtual int | configure (const laelaps::LaeTunes &tunes) |
Configure sensor array from tuning parameters. More... | |
virtual int | reload (const laelaps::LaeTunes &tunes) |
Reload configuration tuning parameters. More... | |
virtual void | exec () |
Execute task in one cycle to take measurements. More... | |
virtual int | getRange (const std::string &strKey, double &fRange) |
Get the shadowed range measurement. More... | |
virtual int | getRange (std::vector< std::string > &vecNames, std::vector< double > &vecRanges) |
Get all shadowed sensor range measurements. More... | |
virtual int | getAmbientLight (const std::string &strKey, double &fAmbient) |
Get the shadowed ambient light illuminance measurement. More... | |
virtual int | getAmbientLight (std::vector< std::string > &vecNames, std::vector< double > &vecAmbient) |
Get all shadowed sensor ambient light illuminance measurements. More... | |
virtual int | getSensorProps (const std::string &strKey, std::string &strRadiationType, double &fFoV, double &fBeamDir, double &fMin, double &fMax) |
Get range sensor properties. More... | |
virtual int | readSensorIdentity (const std::string &strKey, VL6180xIdentification &ident) |
Read sensor's identification. More... | |
virtual int | readSensorTunes (const std::string &strKey, uint_t &uRangeOffset, uint_t &uRangeCrossTalk, double &fAlsGain, uint_t &uAlsIntPeriod) |
Read sensor's current tuning parameters. More... | |
![]() | |
LaeRangeInterface (laelaps::LaeI2C &i2cBus) | |
Initialization constructor. More... | |
virtual | ~LaeRangeInterface () |
Destructor. | |
Static Public Attributes | |
static const int | AlsFreq = 4 |
take an ambient measurement cycle rate | |
Protected Member Functions | |
int | keyIndex (const std::string &strKey) |
Protected Attributes | |
laelaps::LaeI2CMux | m_mux |
I2C multiplexor. | |
VecToFSensors | m_vecToF |
time of flight sensors | |
int | m_nAlsIndex |
ambient light sensor index | |
int | m_nAlsCounter |
when zero, make measurement | |
![]() | |
laelaps::LaeI2C & | m_i2cBus |
bound I2C bus instance | |
VL6180 Time of Flight Array Class.
This class holds an set of LaeVL6180 objects to manage a VL6180 sensor array.
Used in 2.0 hardware.
Definition at line 1005 of file laeVL6180.h.
LaeVL6180MuxArray::LaeVL6180MuxArray | ( | laelaps::LaeI2C & | i2cBus | ) |
Initialization constructor.
i2cbus | Bound open I2C bus instance. |
Definition at line 1274 of file laeVL6180.cxx.
References AlsFreq, m_nAlsCounter, and m_nAlsIndex.
|
virtual |
Configure sensor array from product description.
desc | Product description. |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1311 of file laeVL6180.cxx.
References laelaps::LaeDesc::m_mapDescRangeSensor, m_mux, and m_vecToF.
Referenced by reload().
|
virtual |
Configure sensor array from tuning parameters.
tunes | Tuning parameters. |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1369 of file laeVL6180.cxx.
References laelaps::LaeTunes::getVL6180Params(), and m_vecToF.
|
virtual |
Execute task in one cycle to take measurements.
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1412 of file laeVL6180.cxx.
References AlsFreq, m_nAlsCounter, m_nAlsIndex, and m_vecToF.
|
virtual |
Get the shadowed ambient light illuminance measurement.
The exec() call pulls the measured sensed from the actual sensors.
strKey | Sensor's unique name (key). | |
[out] | fAmbient | Sensed ambient light (lux). |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1482 of file laeVL6180.cxx.
References m_vecToF.
|
virtual |
Get all shadowed sensor ambient light illuminance measurements.
The exec() call pulls the measured sensed from the actual sensors.
strKey | Sensor's unique name (key). | |
[out] | vecAmbient | Vector of associated sensor measured ambients (lux). |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1499 of file laeVL6180.cxx.
References m_vecToF.
|
virtual |
Get interface version.
[out] | uVerMajor | Interface version major number. |
[out] | uVerMinor | Interface version minor number. |
[out] | uFwVer | Firmware version. |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1291 of file laeVL6180.cxx.
References laelaps::LAE_OK, LAE_VER_MAJOR, and LAE_VER_MINOR.
|
virtual |
Get the shadowed range measurement.
The exec() call pulls the measured sensed from the actual sensors.
strKey | Sensor's unique name (key). | |
[out] | fRange | Sensed object range (meters). |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1445 of file laeVL6180.cxx.
References m_vecToF.
|
virtual |
Get all shadowed sensor range measurements.
The exec() call pulls the measured sensed from the actual sensors.
[out] | vecNames | Vector of sensor unique names. |
[out] | vecRanges | Vector of associated sensor measured ranges (meters). |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1462 of file laeVL6180.cxx.
References m_vecToF.
|
virtual |
Get range sensor properties.
strKey | Sensor's unique name id (key). | |
[out] | strRadiationType | Radiation type. |
[out] | fFoV | Field of View (radians). |
[out] | fBeamdir | Center of beam direction (radians). |
[out] | fMin | Minimum range (meters). |
[out] | fMax | Maximum range (meters). |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1519 of file laeVL6180.cxx.
References m_vecToF.
|
virtual |
Read sensor's identification.
strKey | Sensor's unique name id (key). | |
[out] | ident | Identification structure. |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1543 of file laeVL6180.cxx.
References m_vecToF.
|
virtual |
Read sensor's current tuning parameters.
strKey | Sensor's unique name id (key). | |
[out] | uRangeOffset | ToF sensor part-to-part offset. |
[out] | uRangeCrossTalk | ToF sensor cross-talk compensation. |
[out] | fAlsGain | Ambient light sensor analog gain. |
[out] | uAlsIntPeriod | Ambient light sensor integration period (msec). |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1559 of file laeVL6180.cxx.
References sensor::vl6180::LaeVL6180Mux::gainEnumToAnalog(), and m_vecToF.
|
virtual |
Reload configuration tuning parameters.
tunes | Tuning parameters. |
Reimplemented from sensor::vl6180::LaeRangeInterface.
Definition at line 1405 of file laeVL6180.cxx.
References configure().