...
 
Commits (7)
This diff is collapsed.
......@@ -90,7 +90,8 @@ public:
{
Waiting = 0,
Received = 1,
Sent = 2
Sent = 2,
Error = 3
};
enum VL53L1DistanceMode
......@@ -124,6 +125,11 @@ public:
*/
void init();
/**
* @brief This method check if the init was successfully transfered.
*/
VL53L1Status checkInit();
/**
* @brief This method sets the sensor I2C address used in case multiple devices application, default address 0x52
* @param[in] newAddress Addresse to be used by the component
......@@ -178,6 +184,11 @@ public:
*/
void setDistanceMode(VL53L1DistanceMode distanceMode);
/**
* @brief This method check if the setDistanceMode was successfully transfered.
*/
VL53L1Status checkSetDistanceMode();
/**
* @brief This method returns the current distance mode (1=short, 2=long).
*
......@@ -233,6 +244,8 @@ private:
uint8_t _address {0x52};
I2C* _i2c {nullptr};
MsgStatus initStatus {MsgStatus::dataUsed};
uint8_t startRangingBuf[3] {0x00, 0x87, 0x40};
uint8_t stopRangingBuf[3] {0x00, 0x87, 0x00};
......@@ -264,6 +277,13 @@ private:
uint8_t dmLongWOISD0[4] {0x00, 0x78, 0x0F, 0x0D};
uint8_t dmLongPhaseSD0[4] {0x00, 0x7A, 0x0E, 0x0E};
MsgStatus dmPhaseStatus {MsgStatus::dataUsed};
MsgStatus dmRangePeriodAStatus {MsgStatus::dataUsed};
MsgStatus dmRangePeriodBStatus {MsgStatus::dataUsed};
MsgStatus dmRangePhaseStatus {MsgStatus::dataUsed};
MsgStatus dmShortWOISD0Status {MsgStatus::dataUsed};
MsgStatus dmShortPhaseSD0Status {MsgStatus::dataUsed};
uint16_t timingBudget {100};
};
......
......@@ -9,7 +9,6 @@
#define INC_TYPE_ETAPES_H_
#include "GenericHeader.h"
#include "arm_math.h"
#include "custom_type.h"
class Robot;
......