ADNS3080 on the Pixhawk

Hey Guys,

I’ve been using the APM 2.6 controller on my quad for a while now and I’ll be upgrading to the Pixhawk soon. I was just wondering if the Pixhawk supports the ADNS 3080 Mouse Sensor for optical flow via the SPI port. There doesn’t seem to be any mention about the Pixhawk/PX4 on the sensor’s wiki page: … -adns3080/

If so, would it be usable through the OF_Loiter flight mode like in AC3.2.1?


  • Mohammed Nasir
  • Toronto, Canada

I have 3.3 on a PX4, and the option to enable it is in Mission Planner. In fact, it’s the only flow option availabe, no PX4FLOW. I ordered one, slow boat from China (less than $14 USD) so can’t answer if it does work yet - but would like to know!

For Copter-3.3, I’m afraid only the PX4Flow sensor is supported. The setup instructions are a bit complex but they’re all here. … -overview/

Oops… when I looked at Mission Planner, the checkbox to enable optical flow shows an image of the ADNS3080… which is different from previous versions. Oh well.

I managed to clone the px4flow driver to mouseflow, with the SPI basics from the MPU6000 driver. And got the APM_OpticalFlow library updated to recognize it. It compiles, but still no real ADNS3080 code in it. But with any luck, that’s the framework for it to work the same as a px4flow. Now I’ll look more at the 3.1.2 code, but still don’t have the hardware in hand to test.

Hopefully I’m not duplicating anyone else’s effort, but at least this was a way to learn the code base.

Got the hardware 2 days ago, and the SPI communication is working! It wasn’t easy due to the timing (delay) requirements of the chip. But I skipped the SPI class and went to the CDev class, even copied the ifdefs for CDev/VDev from the SPI class. Now it’s just figuring out how to report the values back, hopefully just emulating the PX4Flow. And then maybe some math so they are correct values :slight_smile:

How’d this work out Chuck? I’m also curious why support for the mouse sensor was dropped, if anybody knows?

Hi ChukRhodes and Nathan.

I too would like to see the cheap Mouse-based Optical Flow Sensor ADNS3080 or similar ($8.00 sensors) supported as an option, not everyone can afford the PX4Flow sensor, not to mention its size and weight. I know it is considerably better, but just look at how many cheap $30 - $80 selfie drones have been released in 2018 alone with ‘Optical Flow’ as standard…

Is it not worth adding a cheap optical flow sensor back into Ardupilot?