lightranger8
2.0.0.0
|
LightRanger 8 Click is a compact add-on board that contains a ranging sensor with multi-target detection. This board features the VL53L3CX, the latest Time-of-Flight (ToF) product that embeds third-generation FlightSense patented technology from STMicroelectronics.
We provide a library for the LightRanger8 Click as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Package can be downloaded/installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on mikroE github account.
This library contains API for LightRanger8 Click driver.
lightranger8_cfg_setup
Config Object Initialization function. lightranger8_init
Initialization function. lightranger8_default_cfg
Click Default Configuration function. lightranger8_set_measurement_timing_budget
This function sets the timing budget of the VL53Lx ranging sensor. lightranger8_start_measurement
This function enables the range measuring with the adjusted intermeasurement period. lightranger8_get_distance
This function returns the corrected measured distance from the VL53Lx ranging sensor described in milimeters. This demo application shows an example of distance measurement via VL53L3 ranging sensor.
The demo application is composed of two sections :
Initialization of I2C module, log UART and additional pins.
After driver init, the app powers the device and performs default settings of the ranging sensor including distance mode and timing budget. The optional calibration helps improvement of the accuracy on the targeted distance. This process takes 10 second ( which can by modifed by simply lowering the Delay_ms ( ) value ) so the user can place an object on the exact location. When calibration is finished, device starts the measurement with intermeasurement period set by the user.
A new data ready is checked as soon as possible which signals
the time required for the ranging sensor to perform the measurement. An acqured distance is shown on the LOG with the 2 seconds delay so the terminal is possible to read.
The full application code, and ready to use projects can be installed directly from NECTO Studio Package Manager(recommended way), downloaded from our LibStock™ or found on mikroE github account.
Other mikroE Libraries used in the example:
Additional notes and informations
Depending on the development board you are using, you may need USB UART click, USB UART 2 Click or RS232 Click to connect to your PC, for development systems with no UART to USB interface available on the board. UART terminal is available in all Mikroelektronika compilers.