2022-04-01 05:57 AM
Hi,
I am using the VL53L1X sensor interface on my MCU platform. I am able to get the data while there is an object. But the distance is not matching as per my object.
Less than 20cm it is able to detect, but after that it is not giving any stable values. Instead of a 50 cm object, it is showing 120cm.
I got this sensor breakout board from the online 3rd party distributor.
Could suggest where the issue is to get the constant values.
Regards,
Kumar
2022-04-04 08:12 AM
There are lots of 3rd party distributors of this sensor. Sparkfun, Pololu, AdaFruit and many others. I (as ST support) encourage and support them all. They provide a great service as they might have the form-factor or the MCU support that ST does not. It's good for all of us.
Your problem is interesting. Most of the time the range is too short - due to the coverglass.
But too long is completely different.
So I'm going to suggest something, and you can tell me if my guess is correct.
The target area gets larger with distance. So at 1meter, the target is roughly 0.5M in diameter.
And as you move back, you need an ever larger target to cover the entire FoV.
The other thing to note is that ALL the photons returned are averaged together.
So say you are looking up and the ceiling is 1.5Meters away. And you place your 15 cm target at 20cm. You get 20cm, but the same target at 50cm will not cover the entire FoV. So you average in the 1.5M with the 50cm, and apparently get 120. Could that be it??
I take a piece of paper and fold it diagonally twice. This gives a triangle 22.5 degrees, which is close enough to the 27 degrees. Then place the point of the triangle at the sensor to get a visual idea of what the sensor 'sees'. People are always thinking of a 'dot' laser and discounting the 'overspray'.
If you have a target you want to see and cannot make it larger, you can make it brighter. Use aluminum foil or some reflective tape. The 'overspray' photons will still be averaged in, but there will be so many more from your reflective surface, it won't matter much.
2022-04-04 11:05 PM
Hi John,
Thanks for your response.
The below observations I found as per my testing. The supply is given to TOF sensor from Coin cell CR2477 battery.
I kept my Object (Brown Carton Box) 20cm distance from the sensor and the sensor showed 30cm, 29cm, 26cm, etc the values are not the similar pattern.
When I keep my object (Brown Carton Box) at 10cm distance from the sensor and the sensor shows 15cm, 15cm, 14cm, 15cm etc the values are similar pattern.
My object distance changed to more than 10 cm the values are giving irregular form.
I enabled the below Short distance registers for my initial testing. Are there any settings or missing to get the fine-tune values?
// SHORT RANGE
// timing config
VL53L0X_writeReg_16(0x29, 0x0060, 0x07);//RANGE_CONFIG__VCSEL_PERIOD_A
VL53L0X_writeReg_16(0x29, 0x0063, 0x05);//RANGE_CONFIG__VCSEL_PERIOD_B
VL53L0X_writeReg_16(0x29, 0x0069, 0x38);//RANGE_CONFIG__VALID_PHASE_HIGH
// dynamic config
VL53L0X_writeReg_16(0x29, 0x0078, 0x07);//SD_CONFIG__WOI_SD0
VL53L0X_writeReg_16(0x29, 0x0079, 0x05);//SD_CONFIG__WOI_SD1
VL53L0X_writeReg_16(0x29, 0x007A, 6); // SD_CONFIG__INITIAL_PHASE_SD0
VL53L0X_writeReg_16(0x29, 0x007B, 6); // SD_CONFIG__INITIAL_PHASE_SD1
Note: I integrated this sensor into BLE product. Is there any RF related impact for this TOF sensor?
Regards,
Kumar
2022-06-16 05:37 AM
I am using VL53L1X , code works fine when there is obstacle in the range of 0 to 4 meter ,if no obstacle above 4 meter sensor is giving random values , how we can fix this issue?
2022-06-16 07:47 AM
This is a separate question - and an important one. I'm going to move it to a new query. Search for "no object".