📊
KerloudUAV
  • Kerloud UAV Main Page
  • 📗Kerloud UAV User Guide
    • Introduction
    • System Overview
    • Hardware Options
      • Kerloud 300
      • Kerloud 600
    • Gallery
    • Quick Start
    • Application Programming Interface (API)
    • Tutorials
      • Powering and Programming Interface
      • Offboard Control with Mavros (C++)
      • Offboard Control with Mavros (Python)
      • Indoor Positioning with Optical Flow
      • Flight Data Analysis
      • Virtual Simulation
      • Camera Pod Operation
      • Real Time Visual Recognition
      • Deep Learning in ROS
      • Enabling Autonomous Indoor Flight with a Tracking Camera
      • Hardware-in-the-loop Simulation in Airsim Environment
      • Visual Inertial System (VINS) with Stereo Vision and GPU Acceleration
      • DASA Swarm Simulation Toolbox
    • Video Instructions
  • 📘Kerloud UAV使用说明
    • 介绍
    • 系统组成
    • 硬件选项
      • Kerloud 300
      • Kerloud 600
    • 展示区
    • 快速启动
    • 应用程序接口 (API)
    • 使用教程
      • 供电和编程界面
      • Mavros在线控制 (C++)
      • Mavros在线控制 (Python)
      • 室内光流定位
      • 飞行数据分析
      • 虚拟仿真空间
      • 吊舱操作
      • 实时视觉识别
      • ROS深度学习集成
      • 基于跟踪相机的室内自主飞行实现
      • Airsim环境下的硬件在环仿真
      • 基于立体视觉和GPU加速的视觉里程系统(VINS)
      • DASA集群仿真工具箱
    • 视频指导
Powered by GitBook
On this page
  • How to Setup
  • Environment Requirements
  • Firmware Setup
  • PX4FLOW Focus Setup
  • Demo Video
  • References

Was this helpful?

  1. Kerloud UAV User Guide
  2. Tutorials

Indoor Positioning with Optical Flow

PreviousOffboard Control with Mavros (Python)NextFlight Data Analysis

Last updated 3 years ago

Was this helpful?

Note: This tutorial is applicable for Kerloud UAV with optical flow configuration.

The Kerloud UAV with optical flow configuration provides a convenient option for users to realize indoor positioning with minimum setup. The platform is equipped with a PX4FLOW optical sensor and a lidar distance sensor. The is a smart camera-based sensor in the PX4 community that can provide demonstrated performance in horizontal velocity estimation. The lidar distance sensor can offer accurate height measurement with centimeter accuracy. The configuration can achieve 0.1m and 0.05m accuracy for horizontal and vertical positioning respectively in indoor environment with textured ground. Moreover, it also supports GPS-less flight in outdoor environment.

How to Setup

Environment Requirements

The indoor ground is required to be with rich textures for the optical flow sensor, hence we recommend users to cover the ground with chess board paper or other patterns. The chess board images can be downloaded from the . Besides, the light condition should be sufficient enough for PX4FLOW cameras.

Firmware Setup

The onboard autopilot for Kerloud UAV with optical flow is configured properlly in factory. The parameters can be configured below for indoor case in the QGroundcontrol interface:

    SENS_EN_TF   2
    SENS_EN_PX4FLOW: 1
    EKF2_HGT_MODE: 2
    EKF2_AID_MASK: 2
    EKF2_MAG_TYPE: 0
    EKF2_OF_POS_Y: -0.07

These parameters are clarified as:

  • SENS_EN_TF: enable the distance sensor driver for Benewake TF sensors.

  • SENS_EN_PX4FLOW: enable the PX4FLOW driver.

  • EKF2_HGT_MODE: set the lidar distance sensor as the primary height source.

  • EKF2_AID_MASK: enable the setting for optical flow in EKF estimator.

  • EKF2_MAG_TYPE: set the automatic mode for magnetometer heading measurement.

  • EKF2_OF_POS_Y: set the relative position the in body Y axis for the optical flow sensor.

PX4FLOW Focus Setup

For brevity, users can connect the PX4FLOW sensor with a PC running QGC by the provided micro-usb cable, and then select px4flow under the setting menu in QGC. The image from the PX4FLOW camera can be viewed shortly from the QGC interface. Users can simply a place a textbook on ground and lift the camera to a height you want to fly (typically 1~3 meters). Focus the lens by unscrewing the set screw and loosening and tightening the lens to find where it is in focus. The tuning can be deemed acceptable when the edges of the textbook can be clearly seen in image, as depicted below:

Demo Video

The video demonstrates a semi-autonomous indoor flight following the quick start guide procedures.

References

The camera lens for the PX4FLOW sensor is tuned well in factory. The official tuning guide can be referred in .

Dominik Honegger, Lorenz Meier, Petri Tanskanen and Marc Pollefeys. .

📗
PX4FLOW sensor
link
https://docs.px4.io/master/en/sensor/px4flow.html
video link
An Open Source and Open Hardware Embedded Metric Optical Flow CMOS Camera for Indoor and Outdoor Applications