VL53L5CX not working with Raspberry Pi Pico

Hey,

I’m trying to use the VL53L5CX ( https://learn.sparkfun.com/tutorials/qw … okup-guide ) with a Raspberry Pi Pico. The VL53L5CX is connected to the boards 3.3V supply (power LED is on) and SDA and SCL are connected to GPIO 4 & 5. I am programming the Pico with the Arduino IDE with the official Arduino Mbed OS RP2040 board platform.

If I run the Example1_DistanceArray, the code gets stuck at myImager.begin(). If I run an i2c scan ( https://playground.arduino.cc/Main/I2cScanner/ ) it gets stuck at Wire.endTransmission(). If I disconnect the i2c wires, the programs don’t get stuck and instead report no device found.

With the same setup I am able to discover and connect to a VL53L4CX ( https://learn.adafruit.com/adafruit-vl5 … or/arduino ).

I also tried a community board platform (Arduino-Pico https://github.com/earlephilhower/arduino-pico ), with that no i2c device was found.

Does it behave differently with the regular Arduino IDE (non-web version)?

I initially tried it with the regular IDE. I now also tried the web IDE and the i2c scan also got stuck at the same line.

I found other arduino issues on the web where the wire library would get stuck at endTransmission(). In the reported cases, it was related to noise on the transmission or not matching pull-up resistors. Can this be the case here? My cables are 15 cm long, so I don’t think it’s noise.

I think I received a faulty unit. There is <1 Ohm between SDA and SCL. Probing SDA and SCL with an oscilloscope also shows weird signals. The idle voltage is pulled low and if only one connection is present, the same signal is also on the other (not connected) line (which made me discover the short between the lines).

Can please somebody confirm that there should not be a short between SDA and SCL?

I do not have a sensor like yours, but I do have a VL53L1X (SEN-14722) and your results look wrong to me. A cold measurement (between SCL and SDA) gives me 4.4K. This makes sense given the 2 pullup resistors of 2.2K to 3.3V. Check that your pull-up resistors are really 2.2K as well.

Yes the pull up is 2.2 kOhm

if you still (cold) measure <1 ohm between SDA and SCL… Either there is a bad solder connection causing a short circuit or the chip is broken.