cancel
Showing results for 
Search instead for 
Did you mean: 

X,Y and Z coordinates for X-NUCELO-53L1A1 TOF sensor.

WYous.1
Associate III

Hello everyone,

so I am using the X-NUCLEO-53L1A1 TOF sensor and I want to detect the height ( Z) of objects that it detects but in the examples I found it only shows information about the objects' range ( distance Y) so my question is : Is there a way to obtain data about height, for instance the points coordinates ( X, Y and Z ) so that I can extract height from that data?

Thank you.

7 REPLIES 7
John E KVAM
ST Employee

The sensor shoots out a squirt of light and starts the timer, then it waits for the photons to come back, and when they are detected, the timer stops. Knowing the speed of light we can calculate the range.

But the target is assumed to be in front of the sensor.

If you want to know more, may I suggest the VL53L5CX. It has an 8x8 grid of ranges. From that you can detect a hand in the upper left corner or the lower right.

From this data you can work out the X,Y, Z locations of objects.

It's how I did this video.

https://st-videos.s3.amazonaws.com/CES22_DEMO_BeverageDispenser_FINAL.mp4


In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question. It helps the next guy.

Hello @John E KVAM​ 

thanks for your answer,

I am indeed working with the X-NUCLEO-53L5A1 for that matter, and, knowing that it has a wide 63 ° diagonal FoV, I can multiply tan(31.5) by the range of the detected object to obtain the height Z ( maximum height for that certain range ).

Is my method correct what do you think ?

John E KVAM
ST Employee

You are seeing the 8x8 grid of distances. I'd call it a 45x45 FoV. So each zone is about a 5x5 degree pyrimid. And you can work out the direction from that as well as the distance. I like to use polar coordanates. (Remember those from high school?) it gives a direction and a height.

  • john

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question. It helps the next guy.

Hello @John E KVAM​ ,

you will find attached the method I am talking about explained in details, so you can understand me better.

also this is where I found about the 63 degrees FoV : https://www.st.com/en/embedded-software/stsw-img024.html0693W00000WKX7wQAH.pngThanks.

Hello @John E KVAM​ again,

I think when I use the method I explained previously the issue is that the height is only affected by the range? so if we remove a portion of the detected object the calculated height would still be the same because there were no change in range.

However, if we go back to polar coordinates like you suggested I have two questions : the first is the value of FoV of sensor, like I sent you in the link it says 63 degrees.

The second question ( as you can find in the graph attached ) is we need to determine the height ( which is Y here ) but to do so we need the value R don't we ? but we have no information about that as far as I know am I correct ? here in the 8x8 grid below, those shown values are the X values ( X as in the below graph ) aren't they ? if not how do you suggest to determine the height using polar coordinates? Thank you.0693W00000WKXT4QAP.png 

John E KVAM
ST Employee

I think I understand what you are thinking. And the sensor does it for you.

if you put this sensor 1M from a wall, and perpendicular to it.

You will get 64 zones all saying very close to 1M/

We did the radial-to-perpenducular calculation for you.

You don't need to do any math.

Just run the experiment and prove it does what you want it to.

  • john

In order to give better visibility on the answered topics, please click on 'Accept as Solution' on the reply which solved your issue or answered your question. It helps the next guy.

Hello @John E KVAM​ and thanks for your answer,

actually I did something similar to that and I know it gives me great results but my ultimate goal is to calculate the height of the detected object and not it's distance from the sensor that's why I first thought of the method I explained to you at first which is this

0693W00000WKaiXQAT.pngthe issue with this is that it is range dependant and only gives max height for a given range

Hello @John E KVAM​ in the source code of the 53L5A1_SimpleRanging can't we have an information about the angle of the detection of objects ? if so, I think I can determine the height of that object with calculation