FastArduino v1.10
C++ library to build fast but small Arduino/AVR projects
Loading...
Searching...
No Matches
devices::vl53l0x Namespace Reference

Defines API for VL53L0X Time-of-Flight ranging sensor chip usage. More...

Classes

class  DeviceStatus
 Status of device as retrieved by VL53L0X::get_range_status(). More...
 
class  FixPoint9_7
 Helper class to handle VL53L0X special fix-point 9.7 values. More...
 
class  GPIOSettings
 Settings for behavior of VL53L0X GPIO pin. More...
 
class  SequenceSteps
 Hold VL53L0X sequence steps to use for ranging. More...
 
class  SequenceStepsTimeout
 Hold VL53L0X sequence steps timeouts and other related settings used for ranging. More...
 
class  SPADInfo
 Hold SPAD information from VL53L0X device. More...
 
class  SPADReference
 Hold reference SPADs (Single Photon Avalanche Diode). More...
 
class  VL53L0X
 I2C device driver for the VL53L0X ToF ranging chip. More...
 

Enumerations

enum class  DeviceError : uint8_t {
  NONE = 0 ,
  VCSEL_CONTINUITY_TEST_FAILURE = 1 ,
  VCSEL_WATCHDOG_TEST_FAILURE = 2 ,
  NO_VHV_VALUE_FOUND = 3 ,
  MSRC_NO_TARGET = 4 ,
  SNR_CHECK = 5 ,
  RANGE_PHASE_CHECK = 6 ,
  SIGMA_THRESHOLD_CHECK = 7 ,
  TCC = 8 ,
  PHASE_CONSISTENCY = 9 ,
  MIN_CLIP = 10 ,
  RANGE_COMPLETE = 11 ,
  ALGO_UNDERFLOW = 12 ,
  ALGO_OVERFLOW = 13 ,
  RANGE_IGNORE_THRESHOLD = 14 ,
  UNKNOWN = 15
}
 Possible error codes returned by VL53L0X device. More...
 
enum class  PowerMode : uint8_t {
  STANDBY = 0 ,
  IDLE = 1
}
 Possible power modes of VL53L0X device as returned by VL53L0X::get_power_mode(). More...
 
enum class  GPIOFunction : uint8_t {
  DISABLED = 0x00 ,
  LEVEL_LOW = 0x01 ,
  LEVEL_HIGH = 0x02 ,
  OUT_OF_WINDOW = 0x03 ,
  SAMPLE_READY = 0x04
}
 Possible triggers for VL53L0X GPIO pin. More...
 
enum class  VcselPeriodType : uint8_t {
  PRE_RANGE = uint8_t(vl53l0x::Register::PRE_RANGE_CONFIG_VCSEL_PERIOD) ,
  FINAL_RANGE = uint8_t(vl53l0x::Register::FINAL_RANGE_CONFIG_VCSEL_PERIOD)
}
 Type of pulse period configured for VL53L0X device VCSEL (Vertical Cavity Surface Emitting Laser). More...
 
enum class  Profile : uint8_t {
  STANDARD = 0x00 ,
  LONG_RANGE = 0x01 ,
  STANDARD_ACCURATE = 0x02 ,
  LONG_RANGE_ACCURATE = 0x03 ,
  STANDARD_FAST = 0x04 ,
  LONG_RANGE_FAST = 0x05
}
 Possible profiles of ranging for VL53L0X top-level API VL53L0X::begin(). More...
 

Detailed Description

Defines API for VL53L0X Time-of-Flight ranging sensor chip usage.

Note
the API is partial, some functions of the original STM library have not been ported at all, partly because their documentation did not allow understanding what their purpose could be. This concerns calculations performed by the API itself (not the device), or special calibration procedures. Additional API may be added in the future if needed.

Enumeration Type Documentation

◆ DeviceError

enum class devices::vl53l0x::DeviceError : uint8_t
strong

Possible error codes returned by VL53L0X device.

See also
DeviceStatus
VL53L0X::get_range_status()
Enumerator
NONE 

No error.

RANGE_COMPLETE 

Range completed, range value is available for reading.

UNKNOWN 

Unknown error.

Definition at line 155 of file vl53l0x_types.h.

◆ PowerMode

enum class devices::vl53l0x::PowerMode : uint8_t
strong

Possible power modes of VL53L0X device as returned by VL53L0X::get_power_mode().

See also
VL53L0X::get_power_mode()

Definition at line 288 of file vl53l0x_types.h.

◆ GPIOFunction

enum class devices::vl53l0x::GPIOFunction : uint8_t
strong

Possible triggers for VL53L0X GPIO pin.

See also
GPIOSettings
VL53L0X::get_GPIO_settings()
VL53L0X::set_GPIO_settings()
Enumerator
DISABLED 

No interrupt triggered on GPIO pin.

LEVEL_LOW 

Interrupt triggered when range is under a low threshold.

LEVEL_HIGH 

Interrupt triggered when range is above a high threshold.

OUT_OF_WINDOW 

Interrupt triggered when range is outside a window between low and high thresholds.

SAMPLE_READY 

Interrupt triggered when a range is ready to read.

Definition at line 321 of file vl53l0x_types.h.

◆ VcselPeriodType

enum class devices::vl53l0x::VcselPeriodType : uint8_t
strong

Type of pulse period configured for VL53L0X device VCSEL (Vertical Cavity Surface Emitting Laser).

VCSEL pulse period can be configured for PRE-RANGE and FINAL-RANGE steps in ranging steps sequence. Changing pulse periods has an impact on range distance. Pulse period is expressed in PCLK, whatever that really means.

See also
VL53L0X::get_vcsel_pulse_period()
VL53L0X::set_vcsel_pulse_period()

Definition at line 557 of file vl53l0x_types.h.

◆ Profile

enum class devices::vl53l0x::Profile : uint8_t
strong

Possible profiles of ranging for VL53L0X top-level API VL53L0X::begin().

Each profile defines specific VL53L0X settings.

See also
VL53L0X::begin()
Enumerator
STANDARD 

Standard profile: 33ms ranging time, common accuracy, 1.2m range.

LONG_RANGE 

Long range profile: 33ms ranging time, common accuracy, 2.0m range.

STANDARD_ACCURATE 

Accurate standard profile: 200ms ranging time, high accuracy, 1.2m range.

LONG_RANGE_ACCURATE 

Accurate long range profile: 200ms ranging time, high accuracy, 2.0m range.

STANDARD_FAST 

Standard fast profile: 20ms ranging time, low accuracy, 1.2m range.

LONG_RANGE_FAST 

Standard long range profile: 20ms ranging time, low accuracy, 2.0m range.

Definition at line 975 of file vl53l0x_types.h.