mbed compatible API for the VL53L0X Time-of-Flight sensor

Dependents:   VL53L0X_SingleRanging_Example robot_sm VL53L0X_SingleRanging_HighAccuracy_HANSL ENGR6002_P001unk

Embed: (wiki syntax)

« Back to documentation index

VL53L0X SPAD Functions

Functions used for SPAD managements. More...

Functions

VL53L0X_API VL53L0X_Error VL53L0X_SetSpadAmbientDamperThreshold (VL53L0X_DEV Dev, uint16_t SpadAmbientDamperThreshold)
 Set the SPAD Ambient Damper Threshold value.
VL53L0X_API VL53L0X_Error VL53L0X_GetSpadAmbientDamperThreshold (VL53L0X_DEV Dev, uint16_t *pSpadAmbientDamperThreshold)
 Get the current SPAD Ambient Damper Threshold value.
VL53L0X_API VL53L0X_Error VL53L0X_SetSpadAmbientDamperFactor (VL53L0X_DEV Dev, uint16_t SpadAmbientDamperFactor)
 Set the SPAD Ambient Damper Factor value.
VL53L0X_API VL53L0X_Error VL53L0X_GetSpadAmbientDamperFactor (VL53L0X_DEV Dev, uint16_t *pSpadAmbientDamperFactor)
 Get the current SPAD Ambient Damper Factor value.
VL53L0X_API VL53L0X_Error VL53L0X_PerformRefSpadManagement (VL53L0X_DEV Dev, uint32_t *refSpadCount, uint8_t *isApertureSpads)
 Performs Reference Spad Management.
VL53L0X_API VL53L0X_Error VL53L0X_SetReferenceSpads (VL53L0X_DEV Dev, uint32_t refSpadCount, uint8_t isApertureSpads)
 Applies Reference SPAD configuration.
VL53L0X_API VL53L0X_Error VL53L0X_GetReferenceSpads (VL53L0X_DEV Dev, uint32_t *refSpadCount, uint8_t *isApertureSpads)
 Retrieves SPAD configuration.

Detailed Description

Functions used for SPAD managements.


Function Documentation

VL53L0X_API VL53L0X_Error VL53L0X_GetReferenceSpads ( VL53L0X_DEV  Dev,
uint32_t *  refSpadCount,
uint8_t *  isApertureSpads 
)

Retrieves SPAD configuration.

Function Description
This function retrieves the current number of applied reference spads and also their type : Aperture or Non-Aperture.
Note:
This function Access to the device
Parameters:
DevDevice Handle
refSpadCountNumber ref Spad Count
isApertureSpadsReports if spads are of type aperture or non-aperture. 1:=aperture, 0:=Non-Aperture
Returns:
VL53L0X_ERROR_NONE Success
VL53L0X_ERROR_REF_SPAD_INIT Error in the in the reference spad configuration.
"Other error code" See VL53L0X_Error

Definition at line 3002 of file vl53l0x_api.c.

VL53L0X_API VL53L0X_Error VL53L0X_GetSpadAmbientDamperFactor ( VL53L0X_DEV  Dev,
uint16_t *  pSpadAmbientDamperFactor 
)

Get the current SPAD Ambient Damper Factor value.

Function Description
This function get the SPAD Ambient Damper Factor value
Note:
This function Access to the device
Parameters:
DevDevice Handle
pSpadAmbientDamperFactorPointer to programmed SPAD Ambient Damper Factor value
Returns:
VL53L0X_ERROR_NONE Success
"Other error code" See VL53L0X_Error

Definition at line 2967 of file vl53l0x_api.c.

VL53L0X_API VL53L0X_Error VL53L0X_GetSpadAmbientDamperThreshold ( VL53L0X_DEV  Dev,
uint16_t *  pSpadAmbientDamperThreshold 
)

Get the current SPAD Ambient Damper Threshold value.

Function Description
This function get the SPAD Ambient Damper Threshold value
Note:
This function Access to the device
Parameters:
DevDevice Handle
pSpadAmbientDamperThresholdPointer to programmed SPAD Ambient Damper Threshold value
Returns:
VL53L0X_ERROR_NONE Success
"Other error code" See VL53L0X_Error

Definition at line 2936 of file vl53l0x_api.c.

VL53L0X_API VL53L0X_Error VL53L0X_PerformRefSpadManagement ( VL53L0X_DEV  Dev,
uint32_t *  refSpadCount,
uint8_t *  isApertureSpads 
)

Performs Reference Spad Management.

Function Description
The reference SPAD initialization procedure determines the minimum amount of reference spads to be enables to achieve a target reference signal rate and should be performed once during initialization.
Note:
This function Access to the device
This function change the device mode to VL53L0X_DEVICEMODE_SINGLE_RANGING
Parameters:
DevDevice Handle
refSpadCountReports ref Spad Count
isApertureSpadsReports if spads are of type aperture or non-aperture. 1:=aperture, 0:=Non-Aperture
Returns:
VL53L0X_ERROR_NONE Success
VL53L0X_ERROR_REF_SPAD_INIT Error in the Ref Spad procedure.
"Other error code" See VL53L0X_Error

Definition at line 3015 of file vl53l0x_api.c.

VL53L0X_API VL53L0X_Error VL53L0X_SetReferenceSpads ( VL53L0X_DEV  Dev,
uint32_t  refSpadCount,
uint8_t  isApertureSpads 
)

Applies Reference SPAD configuration.

Function Description
This function applies a given number of reference spads, identified as either Aperture or Non-Aperture. The requested spad count and type are stored within the device specific parameters data for access by the host.
Note:
This function Access to the device
Parameters:
DevDevice Handle
refSpadCountNumber of ref spads.
isApertureSpadsDefines if spads are of type aperture or non-aperture. 1:=aperture, 0:=Non-Aperture
Returns:
VL53L0X_ERROR_NONE Success
VL53L0X_ERROR_REF_SPAD_INIT Error in the in the reference spad configuration.
"Other error code" See VL53L0X_Error

Definition at line 2989 of file vl53l0x_api.c.

VL53L0X_API VL53L0X_Error VL53L0X_SetSpadAmbientDamperFactor ( VL53L0X_DEV  Dev,
uint16_t  SpadAmbientDamperFactor 
)

Set the SPAD Ambient Damper Factor value.

Function Description
This function set the SPAD Ambient Damper Factor value
Note:
This function Access to the device
Parameters:
DevDevice Handle
SpadAmbientDamperFactorSPAD Ambient Damper Factor value
Returns:
VL53L0X_ERROR_NONE Success
"Other error code" See VL53L0X_Error

Definition at line 2950 of file vl53l0x_api.c.

VL53L0X_API VL53L0X_Error VL53L0X_SetSpadAmbientDamperThreshold ( VL53L0X_DEV  Dev,
uint16_t  SpadAmbientDamperThreshold 
)

Set the SPAD Ambient Damper Threshold value.

Function Description
This function set the SPAD Ambient Damper Threshold value
Note:
This function Access to the device
Parameters:
DevDevice Handle
SpadAmbientDamperThresholdSPAD Ambient Damper Threshold value
Returns:
VL53L0X_ERROR_NONE Success
"Other error code" See VL53L0X_Error

Definition at line 2922 of file vl53l0x_api.c.