I’ve started working on a driver and you can see the code so far here. The driver runs without crashing but it’s definitely not correct (yet) but I thought I’d get the skeleton out there in case anyone wants to pitch in on it’s development.
So the way it should work is roughly:
- connect the device to one of the serial port on the fligth controller
- set the appropriate SERIALx_PROTOCOL = 18 (for “optical flow”)
- set FLOW_ENABLE = 1
By the way, I see from @anbello’s code above that the packets are:
0: 0xFE (header)
2: x-high byte
3: x-low byte
4: y-high byte
5: y-low byte
8: 0xAA (footer)
You don’t happen to know what the other bytes hold? maybe a quality number?