Lightwave 10 / b does not work!

Lightwave 10 / b does not work.

I couldn’t do both serial and I2C.

The parameters (SENS_EN_SF1XX, SENS_EN_SF0X, SENS_SF0X_CFG) exist.

Does anyone have similar problems?:roll_eyes:

@toyoda21 which exact sensor are you trying to use? What version of PX4 are you using? What Pixhawk? How did you find that it “does not work”? How did you check it?

@mcsauder do you know if this is supported?

Thank you. @JulianOes

I am trying to use LightWare SF10 / B.
The version of PX4 is PX4 Flight Stack Stabe Release v1.9.2.
I have two Pixhawks.
Pixhawk Radiolink / Pixhawk Cube

I thought it was not working because there was no DISTANCE_SENSOR message using the analyze function of QGC.

I can get distance data using the Lightware terminal.

Hi @toyoda21 and @julianoes. It should be supported. @toyoda21, you should only need to set one of the parameter values you have listed, SENS_EN_SF1XX should be set to 2. You can set the other parameters you have listed back to their default and you can double check your parameter values by using param show SENS_EN_SF1XX from the QGC mavlink console.

The SF10b should run on the sf1xx driver, although I do not have hardware to test it with. The sf0x driver is for a different series of sensors as far as I understand, and those sensors are no longer available and have not been available for what looks like a few years, so I can’t test that driver either. Also important, the sf1xx driver only supports I2C at this point, so you’ll need to ensure you are using your device in that configuration.

The default driver start attempts to start on all available busses, so as long as you have SEN_EN_SF1XX set to 2, the driver should start. Be sure to double check your SDA/SCL lines to ensure they are not swapped!

Let us know if this gets you any farther!

-Mark

I’m sorry. @mcsauder
There was no progress.

After setting all parameters to default, I set the SENS_EN_SF1XX parameter to 2.
This is my hardware configuration.


And I checked my parameters by using param show SENS_EN_SF1XX from QGC mavlink console.

Have you flashed fmu-v2 or fmu-v3 on this Pixhawk? The distance sensor drivers are not included in fmu-v2 due to not enough flash space.

If you have a Pixhawk with the silicon errata you can only use fmu-v2, otherwise you should be able to update the bootloader and then flash fmu-v3.

1 Like

Yes, I have flashed fmu-v2 on this Pixhawk. @JulianOes
I updated the Pixhawk bootloader.


This version is PX4 master version. ( GitHub - PX4/PX4-Autopilot: PX4 Autopilot Software )

And I flashed fmu-v3 on this Pixhawk.


However, neither serial communication nor i2c communication was possible.

Hi @toyoda21, apologies but I don’t have that sensor to test with. With the sensor wired for i2c and connected, can you provide the output from the mavlink console, (or better if you can read it from the serial console port rather than through QGC to capture output from boot), for the following:
sf1xx start -a,
sf1xx status

EDIT: You must be on fmu-v3 firmware, the sensor driver is not compiled into the fmu-v2 firmware binary.

I was able to receive the distance_sensor topic!
Here are the results I got using the mavlink shell.

nsh> sf1xx start -a
ERROR [sf1xx] already started
nsh> sf1xx status
state @ 0x1000c360
sf1xx_read: 2256 events, 751930us elapsed, 333.30us avg, min 311us max 608us 38.751us rms
sf1xx_com_err: 0 events
poll interval:  31250
report queue	2/112 (2/1 @ 0x1000cb90)

After flashing fmu-v3 to pixhawk, I changed the Lightware settings.
My Lightware sensor is old.
Therefore, it is necessary to change the baudrate and i2c address using Lightware Terminal software provided by Lightware Optelectronics.
→ Serial port baud rate : 9600
→ I2C bus address : 0x66

Now, I can read the DISTANCE_SENSOR.current_distance topic from the QGC console.

I would like to thank @JulianOes and @mcsauder

Thank you.

1 Like

Congratulations! Glad it’s working for you!

1 Like

hi @mcsauder and @JulianOes! Now, I’m can use sensor LightWare 20 to avoid obstacles on PX4 ?