# PMW3901 speed

Hello,

I’ve looked at a few site and datasheets for the PMW3901 and found that the speed is listed as 7.4 rad/s. Why is rotational speed specified? I want to know the max X/Y speed for the PMW3901. Other optical flow sensors list the max IPS (inches per second). For example, the ADNS-3080 has max 40 IPS. Does anyone know the max IPS for the PMW3901?

because the sensor measures a flow rate, which is in rad/s. The maximum horizontal speed depends on the distance to the moving surface (e.g.: ground). So if you are at 1m, the maximum speed is 1x7.4 = 7.4m/s and if you are at 10m altitude, the maximum speed is 10x7.4 = 74m/s.

The ADNS-3080 is supposed to be in an optical mouse so it makes sense that they already converted the flow rate into IPS or m/s for some “typical” distance. Note that the value also depends on the optical lens used on the sensor.

I have a question about calculating the speed from the movement in a x or y direction.
How does one accomplish this?
I am retrieving a change in magnitude of the x and y value, but how do I convert the magnitude of change to a speed? And yes, I do calculate the distance to the surface that is being measured aswel.
I am using the PMW3901 module and have searched all over the internet to find a way to convert the values to a velocity. Any help or direction would be appericiated!

This is how you can compute the equivalent ground velocity: PX4-Autopilot/optflow_fusion.cpp at fb3adc3faa9154a42a0bef35577bff1e8a95fd72 · PX4/PX4-Autopilot · GitHub
and the compensated optical flow is computed like that: PX4-Autopilot/optical_flow_control.cpp at fe80e7aa468a50bec6b035d0e8e4e37e516c84ff · PX4/PX4-Autopilot · GitHub