Laser Distance Sensor and ADC DelSig

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

Hello,

   

I'm new to the psoc and I'm trying to get decent values from this laser distance sensor: https://www.pololu.com/product/2476

   

I'm trying to get the ADC to operate within the proper voltage range listed on the site (3.6 V at 10 cm to 0.6 V at 150 cm) but can't figure it out. I've tried using the -Input +/- Vref function to get that exact voltage range but something is wrong. If I use the Single Ended option and play around with the "Input Options" and "Reference" sections of the ADC I can get a little closer but at this point I'm just changing around parameters that I don't understand and hoping that I get what I need.

   

I need some direction, any help is much appreciated.

   

Thanks!

0 Likes
1 Solution
Anonymous
Not applicable

Thanks for your help,

   

I figured it out. I turns out I should have kept it simple with Vssa to Vdda. Also linearized it with the proper function.

   

For anyone else that stumbles across this thread, the best linearization function is:  

   

linearizedDistance = (pow(ADC_Read16(), -1.51));

   

Thanks again!

View solution in original post

0 Likes
3 Replies
rola_264706
Level 8
Level 8
50 likes received 25 likes received 10 likes received
        Post your project so we can check it.   
0 Likes
lock attach
Attachments are accessible only for community members.
rola_264706
Level 8
Level 8
50 likes received 25 likes received 10 likes received

Here is a sample program that my help.

0 Likes
Anonymous
Not applicable

Thanks for your help,

   

I figured it out. I turns out I should have kept it simple with Vssa to Vdda. Also linearized it with the proper function.

   

For anyone else that stumbles across this thread, the best linearization function is:  

   

linearizedDistance = (pow(ADC_Read16(), -1.51));

   

Thanks again!

0 Likes