Lidar lite V3 and Pixhawk I2C

Hello all

I have been working with Pixhaw and Lidar Lite V3 . I’m able to get it working via the PWM mode too. I want the Lidar V3 sensor to work in the I2C mode but im not able to do that as of now.

Can any one direct me how to get the Lidar working with I2C with Pixhwak ?

I tried to get the I2C driver for Lidar up and working but no matter what I try the I2C driver is not starting . Please help me with this

Thanks in advance

Hi,

I am interested to do the same. Have you solved your problem?

Did you change the “ll40ls start” option from “pwm” to “i2c”?
If not, try to modify in “rcS” file. It worked for me.

One question, how did you connect with pwm? Could you share the pin connection information?
As I know lidar v3’s pinmap is different from lidar v2.
I’ve tried both v3’s manual instruction and v2’s original one but both not working for me.

All,

I have the v3 working, at least displaying sonar voltage and range in Mission Planner. However I am still having some problems with it. Follow the link.

https://app.box.com/s/8wt97s2hp0r8fnrcmchxxy7qst1j304v

How did you get lidar-lite-v3 working on PWM??
I just followed these two documents but it doesn’t work

https://pixhawk.org/peripherals/rangefinder?s[]=lidar
https://dev.px4.io/flow_lidar_setup.html

I gave power from RCIN pwm port
is there something I missed?

Actually, it does not work correctly. It give good readings up to 6 meters then become unresponsive, but the lidar pulsewidth is correct. I also do not see a difference in the voltage level of the waveform, when the Pixhawk is working or not. This appears to be a code issue. Also, when the Pixhawk does appear to see the pulse, the code does not enact avoidance if I move an obstacle under the vehicle when it is hovering.

If you want to try PWM just connect Lidar mode control to Pixhawk pin#55. Put a roughly 680 uf cap across the lidar power and gnd leads. Set up the configuration parameters as instructed for lidarlite v2.

Tomorrow, I’ll upgrade to APM v3.5, then, try the I2C connection with RNGFND_TYPE=3. I see claims that works in other forums…

Hi

Did you tried it with the 680µF electrolytic capacitor?
See instruction here:

pli-06-instruction.pdf (749.7 KB)

Hi all
I tried lidar lite v3 with i2c communication and i can see lidar initial in nsh
When i write “ll40ls test i2c” i can see right lidar range. But in qgroundcontrol i can’t see any distance value.
I think the distance won’t published by pixhawk.
And this is problem…
I use px4 1.6.0 rc1 and pixhawk v2 and lidar lite v3

Thanks in advance

1 Like

hi @morid_Aghili, can I ask if you how did you wire up your lidarlite? Do you have to change the rcS file? I tried “ll40ls test i2c”, also “start” and “info” but all failed. It keep asking if the driver is running.

Hi,
Sorry, false alarm. Turns out the issue was the power cable going into LidarLite. After fixing the cable, it works.
For others who got into the same problem. Double check your power cable. I also need to add LidarLite startup scripts to the rcS file.

Hi there,
please check your wiring, you must connect lidar lite GND to ground FCU and power source .
and check the ll40ls driver in the “Firmware/cmake/config” path, it must be uncomment.

can you add the script ???

Yes you can, according to this https://github.com/PX4/Firmware/pull/7113

Hi

I can’t read data via Qgroundcontrol. I’ve checked the cable connections and the sensor’s functioning by using arduino ( Lida-Lite v3 Library). @hmchung “I also need to add LidarLite startup scripts to the rcS file.” i have to do this. I couldn’t find enough information on the wiki page. Thanks for helps

Is there any idea? I can not see distance sensör topic

hello, you should try to start manually in mavlink console “ll40ls start i2c”. If it is still not available, try again !!. I think it is a bug on lidar lite driver

1 Like