2019-07-31 11:46 AM
I need to use multiple V6180x SATEL sensors to get distance measurements, however I do not know how to make it work directly through the I2C connection, since once connected the sensor is not even found by the I2C.
Is it possible to use this sensor by connecting it directly to the SDA, SCL, 3,3V and ground pins and use it as a common i2c device or do I need to use specific libraries and specific configuration?
2019-08-01 04:28 PM
All the ST code ends at the I2C read/write routines. It is the job of the developer to write the interface between the VL6180X read/writes and the MCU's native read/write commands. You should be able to hook those 4 pins, but there is an SHUTDOWN pin that you have to pull high to get the chip to start.
Some people use the interrupt pin that triggers when the data is ready, although polling also works.
Download the file from:
It will give you want you need.
2019-08-07 03:26 PM
How can I perform the distance reading measured by the vl6180x sensor using only I2C functions and the internal sensor registers?
What I want to do is something like the function below, however I don't know the addresses of the sensor's internal registers.
HAL_I2C_Mem_Read_DMA (& hi2c1, device_address << 1, register_address, 1, buffer, 2);
For example the reading of a temperature sensor at address 0x50 where the output is in register 0x07
HAL_I2C_Mem_Read_DMA (& hi2c1, 0x50 << 1, 0x07, 1, buffer, 2);
Is it also possible that manipulation of more registers is necessary to measure a distance?