Skip to main content
Associate
July 24, 2024
Solved

vl53l0/1xv2 interface to 3rd-party MCU/MPU

  • July 24, 2024
  • 1 reply
  • 944 views

hi anyone can please help me for the integrating vl53l0 sensor with rx71m mcu,

because i am not getting specific document for communicating it with rx71m over i2c 

please support

Best answer by John E KVAM

The trick is in the platform.c file. 

This file contains the layer between the sensor and the MCU/CPU you are running. 

It translates the VL53L0_RdByte() andVL53L0_WrByte() functions in the API into the I2C functions your MCU uses. 

But it was written by a Linux programmer who absolutely loves abstraction layers. So it's a touch hard to follow.

But you can follow it through and re-write it to talk to your hardware. 

Also note that lots of people have done this and put their code onto GitHub. 

Before you go too far, search GitHub looking for either VL53L0 posts or VL53L0 and your type of MCU.

You can see what others have done.

As delivered the code talks to a PC and absolutely no one wants to do that. For one, it involves opening up your laptop and that's just dumb.

- john

 

1 reply

John E KVAM
John E KVAMBest answer
ST Employee
July 24, 2024

The trick is in the platform.c file. 

This file contains the layer between the sensor and the MCU/CPU you are running. 

It translates the VL53L0_RdByte() andVL53L0_WrByte() functions in the API into the I2C functions your MCU uses. 

But it was written by a Linux programmer who absolutely loves abstraction layers. So it's a touch hard to follow.

But you can follow it through and re-write it to talk to your hardware. 

Also note that lots of people have done this and put their code onto GitHub. 

Before you go too far, search GitHub looking for either VL53L0 posts or VL53L0 and your type of MCU.

You can see what others have done.

As delivered the code talks to a PC and absolutely no one wants to do that. For one, it involves opening up your laptop and that's just dumb.

- john