Vl53l8cx carrier board does not work with I2c on a STM32 NUCLEO L496ZG

Hello, @mikhako.

Is the 3.3V power coming from your Nucleo-H7S3L8 board, or is it from a separate source? Are the results with the VL53L8CX better if that is the only device you have connected to your I2C bus, and can you also post some pictures of your setup that show all of your connections? Also, if you have not already, please try testing the board with shorter wires to see if that helps.

- Patrick

It very surprising, but once I replaced to shorter wires, it started to work. Without any weirdness. What is also interesting, in the process of troubleshooting I was trying to get signals after the level shifter. I soldered a couple of wires to the board. The signal was what I was expecting: 1.8v on high. After a changed wires, signals became 3.3v internally. Trying to understand what is wrong. But it works. Also, disconnected another device. I was doing it before, but without any success. Now have to troubleshoot returning values.
External I2C (top two), after level shifter (bottom two)


Working setup

Thank you for help, PatrickM

I am glad to hear that you have a setup where it is working now! Thanks for updating us.

It may seem surprising, but as mentioned on the product page and in previous posts in this thread, the level shifter on this board is sensitive to external loads to the extent that the presence of other devices on the same I2C or SPI bus and even the length and routing of the wires can affect communication.

- Patrick

Made a mistake. Setup is not actually working. It was late at night, and I interpreted i2c coming through as sign of success, today I figured out that I mixed up ground and board wasn’t powered up. So, the same issue. Now I disconnected everything around. Added external power supply, it looks like level shifter stacks somewhere in the middle. I tried to adjust pull up resistors thinking that rising edge is not fast enough, no success. Time to time I see that VL53L8CX tries to get acknowledgement on address, but so far no much success.


But this is the most lucky setup. This is what I generally get (82k pull ups):

22k:

I’m not sure how sensitive the level shifter should be to show this behavior. What else can I try?

Most of your soldering looks okay (though it can be hard to tell from just one angle), but on closer inspection it seems like you have a few solder joints on your board that are not fully wetted to the pads, so that is probably the easiest issue to address first. After that the next thing to try using shorter wires with the communication wires routed away from any of the other wires. From your photo I would guess you are probably using 6 inch jumper wires most places. Ideally we recommend keeping the communication wires under 3 inches. If avoiding the use of a breadboard is an option for you (for example by using male-female jumper wires), that could also help.

Also, the long, thin, and uninsulated wires you are using to probe the system may not be giving you the cleanest signals.

- Patrick

A new update. First, x52 address is a little confusing indeed. x29 seems to be conventional address and LSB bit for read an write. Thanks for pointing out the soldering issues. Fixed. The level shifter showed some very bazar behavior. I connected another level shifter (a simple one) at 1.8v line, the vl53l8cx started to respond. After that I stacked them one after another, lowering voltage on the board to 2.5v, it worked. After that, a removed the additional level shifter, connecting everything as it should be. The board worked (!) just showing some weird notch on SDA SCL lines after initialization. And then, it stopped to work again. After lowering voltage to 2.2v, the board started to responds (ack etc). Navigating through firmware. Pretty often the board is getting stuck on pooling “1” during boot sequence, before loading firmware. Managed to load firmware and checked CRC. So, that code works ok.


Now, initializations are very inconsistent. Sometimes it fails on very initial step, some times, it goes through download and crc. Also, I notified, that when board receives few inital commands, it starts to produce this notch (on the image). Time to time, it disappears by itself. Sometimes I need to switch off power on the board.

We do not see anything else in your setup that definitely looks problematic. The most significant change you could probably still try is to use M-F jumper wires to connect directly to the VL53L8CX carrier and remove the breadboard entirely like I mentioned before.

We are testing this carrier with a different level shifter from TI instead of the Nexperia chip to see if it might be more reliable. If you are interested in trying some samples of those in your application, please contact us directly with your order information and a reference to this thread.

- Patrick