lidar_tfmini_i2c

The TF Mini LiDAR is an unidirectional range finder based on time-of-flight (ToF) via IR LED technology. It uses adaptive algorithms for indoor and outdoor application environment. The sensor can be used as a distance-measuring tool to detect the distance to surfaces, suitable for AGL hold and terrain following. The maximum detection distance is 12 meters. The device supports 100Hz sampling rate. To be able to use the I2C version of the TFmini ranger, enable this module in your airframe and set you wanted parameters.

Configures

Name

Value

Description

TFMINI_I2C_DEV

i2c2

I2C device port on flightcontroller to use for this device

TFMINI_I2C_ADDR

0x20

Other than default I2C Slave address 0x10 to use for the device

USE_TFMINI_I2C_AGL

0

Updates the AGL value in state,if not defined, defaults to FALSE

TFMINI_I2C_COMPENSATE_ROTATION

1

Compensate AGL measurements for body rotation. Disabled by default

Defines

Name

Value

Description

TFMINI_I2C_USE_FILTER

TRUE

If this is line is added one enables a median filter on the sensor output, not needed in normal use

AGL_LIDAR_TFMINI_I2C_ID

254

Set own ID if using both U, S and I version of sensor at the same time

TFMINI_I2C_OFFSET

0.56

Sensor offset in CM, as in where one wants zero to be, default is 0.0

TFMINI_I2C_MIN_RANGE

0.44

If defined, set limit to minimum value reported, default 0.3

TFMINI_I2C_MAX_RANGE

3.0

If defined, set limit to maximum value reported, default 6.0

TFMINI_I2C_MEDIAN_SIZE

9

If median filter is enabled then set this option to filter the output more(or less), default is 7

SENSOR_SYNC_SEND_SONAR

If defined, sends raw and scaled ranging values, useful for debugging sensor issues

Depends

  • i2c

Provides

  • sonar