Research Careers Contact

GlossaryOptical flow sensor

Optical flow sensor

An optical flow sensor is a small downward-facing camera with onboard processing that measures how the ground texture moves across its image. On a drone, combined with a height measurement and the IMU, it gives horizontal velocity over the ground, which lets the drone hold position without GNSS.

How it works

The sensor captures low-resolution images at a high frame rate and compares consecutive frames to find how far the texture shifted, in pixels per frame. That apparent motion depends on two things: how fast the vehicle moves, and how far away the ground is. Rotation of the vehicle also moves the image, so the flight controller subtracts the rotation measured by the gyroscope.

To convert flow into velocity, the system needs height above ground, usually from a downward time-of-flight sensor or rangefinder mounted next to the flow sensor. The flight controller's estimator then fuses velocity with IMU and other data. PX4 and ArduPilot both support optical flow sensors for position hold and document their setup, mounting and calibration.

Optical flow sensor vs visual-inertial odometry

An optical flow sensor measures 2D motion of the ground below and outputs velocity. It is simple and low power, but it needs textured ground, a height measurement and limited altitude. Visual-inertial odometry tracks features in full camera images, in any direction, and estimates full 3D position and orientation. It works in more conditions but needs a capable processor and careful calibration.

Why it matters

Indoors, under bridges, near large structures and in GNSS-denied areas, a drone without another velocity source drifts. An optical flow sensor gives low-cost, low-weight position hold at low altitude, which matters for indoor inspection, warehouse work and precision landing. It also serves as a fallback when GNSS degrades.

How to get it right

  • Mount the sensor facing straight down with a clear view, away from prop wash debris and landing gear.
  • Pair it with a reliable height sensor that covers the operating altitude range.
  • Calibrate the scale and the alignment between the flow sensor and the IMU.
  • Test over the surfaces you will fly over: plain floors, grass, water and low light all challenge flow.
  • Configure the estimator to reject flow data when quality reports drop.

Optical flow sensors in robotics and drone hardware

Optical flow sensors are usually small boards combining an image sensor, a lens, a processor and often a time-of-flight rangefinder, connected to the flight controller over serial, I2C or CAN. Ground robots use similar sensors to measure motion over floors where wheels slip. Placement, vibration isolation and cable routing near motors all affect data quality.

Learn more