Cheerson CX-OF low cost optical flow sensor testing

That would be very cool!!

Once I get my head around this module I might try to write a driver so that I can use it.

FYI, Here is a draft C version driver for PX4 by Tonser from SJTU.

Official decode demo.

Fusion demo

Thank you this was very kind of you!

image

Not sure what the green box on the right it for.

I should be able to copy the AP_OpticalFlow_CXOF class and but change the point in the buffer where the correct data is?

Im not sure where “CXOF_PIXEL_SCALING” is coming from?

Congratulations, you made the GUI tool work.
BTW, you can use ‘i’ key to init the device, ‘c’ key to reset SUM.

Tonser told me this is an experience number, just like an OPTICAL_FLOW_P.
Maybe there is a way to calculate it. But also this won’t hold you back.


I think the scale can also adjust like this.

1 Like


There is lots of Optical Flow Module in china, if has a driver can be configuration to support them all is best, since they are very similar.

Well at this point my concern is we wont get the upflow driver let alone any other driver… Might want to remove it from the wiki if we are not going to get support for it.

Wow! This one is compatible with CX-OF.

1 Like

@bys_1123, great news! Is there a link to a store where it can be purchased. I should update the wiki to tell users which will/won’t work.

It’s only in Taobao china now, I keep follow this, if it show up on other online shop, I’ll share the link here.


I tested it, works really well.

Thanks for your work, makes lots of fun.

Should be the same

Interesting, it seems they have applied a lens in front of the P3901 sensor.

Yes, This one avoid dust into the sensor.

Just received the JJRC H62 RC Quadcopter Spare Parts Optical Current Board H62-03

So it is using same Data Format as UPIXELS UP-Flow

01 0xFE
02 0x0A
03 flow_x_integral low byte
04 flow_x_integral high byte
05 flow_y_integral low byte
06 flow_y_integral high byte
07 integration_timespan low byte
08 integration_timespan high byte
09 ground_distance low byte current not work, 0x03E7 in default.
10 ground_distance high byte current not work, 0x03E7 in default.
11 valid 0x00 or 0xF5
12 version
13 Xor Byte3~Byte12
14 0x55

Here is the result

My first impression is not that great, as this sensor has no qual (surface quality), requires more light , it is noisier and there is a scaling issue between axes

This compatible module will available on Seeed Studio at June.

https://www.seeedstudio.com/ThoneFlow_3901U_UART_Serial_Version_PMW3901_Optical_Flow_Sensor-p-4040.html

3 Likes