cancel
Showing results for 
Search instead for 
Did you mean: 

We have recently developed a Hardware board having STM32L4KB and VL53L1X , we connected VL53L1X I2C3 port. we are running the STM32 VL53L1X API we get the I2C data as 255, -1. Request you please suggest a solution for the same

VDevalla
Associate

We checked the status of each step and the status for VL53L1_WaitDeviceBooted = -13

0693W00000FCDFhQAP.jpg

3 REPLIES 3
John E KVAM
ST Employee

1) remove the level shifter. The I/O on the sensor can handle to 3.6 max. Your 3.3 should be OK.

I've never encountered a level shifter that didn't make the problem worse. Unless you know the I/O voltage is too high for the sensor, best remove it.

2) If the power is good, and XShut is high, the sensor's only job is to wait for your command.

I'm pretty sure that 255 is a message from the I2C that you timed out. It's not from the sensor as some answer.

Good luck,

  • john

If this or any post solves your issue, please mark them as 'Accept as Solution' It really helps. And if you notice anything wrong do not hesitate to 'Report Inappropriate Content'. Someone will review it.

Hey John,

Thank you for the quick response.

Firstly, in point no. 1 I would like to confirm if you want us to only remove the 3.3V to 2.8V voltage regulator or should we remove the BSS138 level shifter too.

Also, we have implemented the same circuit previously and we didn't face this issue when using with an Arduino and with an STM32 Nucleo board.

Are there any steps that we missed when using a TOF sensor and microcontroller(STM32L432KB) directly from the factory.

With respect to the 2nd point, we have checked the voltage at all the IO pins. We can confirm that XSHUT is receiving 2.67V which should be enough. Is there any issue with our circuit and can we use that circuit to control XSHUT using a GPIO pin?

Thanks in advance

John E KVAM
ST Employee

It's been my experience that level shifters are bad. Read the section of the datasheet on max I/O voltage (it's 3.6) so if your MCU can stay within that, you don't need to level shift. The sensor can do 1.8 I2C as well.

I hook my STM32s to the the sensor without level shifters, and I don't have any problem. (But I'm a software guy.)

I agree that 2.67 is enough to pull up the XShut. So it's got to be that level shifter.


If this or any post solves your issue, please mark them as 'Accept as Solution' It really helps. And if you notice anything wrong do not hesitate to 'Report Inappropriate Content'. Someone will review it.