cancel
Showing results for 
Search instead for 
Did you mean: 

Calculate x,y,z coordinates of each points of the VL53L5CX

CPoisson
Associate III

Hello,
I am trying to calculate the x,y,z coordinates of each points of the VL53L5CX sensor to determine the angle error between a surface and the plan of the sensor.

I have two problem with my system :
- the resulted error is not symmetrical with one rotation side or with the other,
- and the resulted error is very depending on the material I chose.
Here is a graphic of the mean angle error with 2 surfaces (wood and black metal) repeated with 3 differents VL53L5CX (I took 50 measures each 5° degrees).

ErreurMoyenne_Angle.png

So I am wondering if my calculation of the coordinates x,y,z of each points of the VL53L5CX is right, and if I didn't forget some details. I'm almost sure that the plan calculation is right.

So here is the way I calculated the coordinates:
The VL53LCX give us 16points, and the returned value of each distance is the adjacent side of the FoV as said in this page of the forum : https://community.st.com/t5/imaging-sensors/vl53l5cx-distances-don-t-match-theory-what-am-i-missing/td-p/82657.
Organisation_VL53L5CX.pngDistance_retournee_VL53L5CX.png


We know that HFoV = 45° and we assume that MATRIX_LENGTH = 4 (for the following calculation).
To ease the calculation we convert the 16 points in i,j columns and raws.

VL53L5CX_matrice(1).png

The calculs is detailed here:

Capture d’écran du 2024-05-02 10-59-38.png

Do you agree with this coordinates calculation, or did I miss something ?

Thank you !

Clément.

3 REPLIES 3
John E KVAM
ST Employee

I'm a bit rushed this morning, so I did not fully understand your data. Besides my French is awful, which is pretty funny considering where I work. But I have a guess I'd like to share with you.

If you point that sensor at a flat wall exactly perpendicular, you will get the same distance in all the zones. It's because we have done a radial to perpendicular calculation to the data.

Could that be throwing you off?

As to the materials...

If you use something with a matte finish, the light will reflect in all directions. If you use a specular (mirror) finish target, the light will bounce away and depending on the angle will not return. 

Please validate your targets by checking to see that the Number_of_Targets is at least 1. Then check the RangeStatus to verify that the target is valid. An invalid target can really throw off your results.

- 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.

Hi !
I guess you are right about the specular targets : when I ma using a wood surface I have almost all the number of targets at 1, but with a metalic bright surface I don't.

So just to confirm, I think that the coordinates calculation is good, but it's important to filter the points with 0 number of targets detected.

John E KVAM
ST Employee

Before you decide it's a valid target, check that the number of targets is at least 1 and also verify that the RangeStatus is 5 (perfect) 6 (first target after boot) or 9 (merged pulse, meaning two targets near each other in distance.)

You also might consider 12 as valid - it's a target at the same distance as a neighbor, but with a signal strength much lower. It' might be blur, but maybe you know something about your environment that can help you decide.

- 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.