Benewake TFmini LiDAR
PX4 v1.7The Benewake TFmini-S and TFmini Plus are small, low-power time-of-flight LiDAR rangefinders with a range of 0.1–12 m (PX4 uses 0.4–12 m) and a 100 Hz default update rate. They connect to the flight controller using a serial port (UART).

Supported Models
| Model | 范围 | 接口定义 | SENS_TFMINI_HW value |
|---|---|---|---|
| TFmini-S | 0.1–12 m | UART | 1 (default) |
| TFmini Plus | 0.1–12 m | UART | 1 (default) |
PX4 reports distances from 0.4 m to 12 m for both models.
Specifications
- Technology: Time-of-flight, 850 nm infrared (VCSEL on the TFmini-S, LED on the TFmini Plus)
- Range: 0.1–12 m at 90% reflectivity; 0.1–7 m (TFmini-S) or 0.1–4 m (TFmini Plus) at 10% reflectivity (PX4 uses 0.4–12 m)
- Update rate: 100 Hz by default, adjustable 1–1000 Hz
- Field of view: 2° (TFmini-S), 3.6° (TFmini Plus)
- Accuracy: ±6 cm below 6 m and ±1% from 6–12 m (TFmini-S); ±5 cm below 5 m and ±1% from 5–12 m (TFmini Plus)
- Resolution: 1 cm
- Interface: UART at 115200 baud, 8N1, 3.3 V (LVTTL); the sensors also support I2C, which the PX4 driver does not use
- Input voltage: 5 V ±0.1 V (TFmini-S), 5 V ±0.5 V (TFmini Plus)
- Current draw: ≤140 mA average, 200 mA peak (TFmini-S); ≤110 mA average, 140 mA peak (TFmini Plus)
- Dimensions: 42 x 15 x 16 mm (TFmini-S), 35 x 18.5 x 21 mm (TFmini Plus)
- Weight: 5 g (TFmini-S), 12 g (TFmini Plus)
- Operating temperature: 0–60 °C (TFmini-S), -20 °C to 60 °C (TFmini Plus)
- Ingress protection: IP65 (TFmini Plus)
- Laser class: Class 1 (TFmini-S)
Where to Buy
Hardware Setup
Mounting
Mount the sensor facing down: PX4 assumes a downward-facing sensor, and the orientation cannot be configured.
Readings below 0.4 m are reported as out of range.
Pinouts
The TFmini-S and TFmini Plus have a cable ending in a JST 1.25 mm 4-pin connector (Molex 51021-0400). This is not the JST-GH connector used by flight controllers that follow the Pixhawk Connector Standard, so you will need an adapter cable to connect to those ports. The cable can be extended, but Benewake recommends keeping it shorter than 1 m.
The wire colours are the same on both models, but the pin numbering differs.
TFmini-S:
| 针脚 | Wire colour | 信号 |
|---|---|---|
| 1 | Black | GND |
| 2 | Red | +5 V |
| 3 | White | RX (UART receive, 3.3 V) |
| 4 | 绿色 | TX (UART transmit, 3.3 V) |
TFmini Plus:
| 针脚 | Wire colour | 信号 |
|---|---|---|
| 1 | Red | +5 V |
| 2 | White | RX (UART receive, 3.3 V) |
| 3 | 绿色 | TX (UART transmit, 3.3 V) |
| 4 | Black | GND |
Wiring
The TFmini can be connected to any unused serial port (UART), such as TELEM2, TELEM3 or GPS2.
| TFmini wire | Connect to |
|---|---|
| Green (TX) | Flight controller UART RX |
| White (RX) | Flight controller UART TX (optional) |
| Red (+5 V) | 5 V supply |
| Black (GND) | Flight controller GND |
The driver only reads from the sensor, so the sensor's RX wire does not need to be connected.
The TFmini-S needs 5 V ±0.1 V and up to 140 mA (200 mA peak); the TFmini Plus needs 5 V ±0.5 V and up to 110 mA (140 mA peak). Neither has over-voltage or reverse-polarity protection.
Firmware Support
The rangefinder is supported by the tfmini driver, which is built into firmware by either of the following board configuration keys:
CONFIG_COMMON_DISTANCE_SENSOR=y: the common set of rangefinder drivers, which includes this one.CONFIG_DRIVERS_DISTANCE_SENSOR_TFMINI=y: this driver on its own.
Most boards set CONFIG_COMMON_DISTANCE_SENSOR, so the driver is present in most firmware. To check your board, look for either key in its configuration file, boards/<vendor>/<board>/default.px4board, or check whether SENS_TFMINI_CFG is listed in QGroundControl (parameters are only shown for drivers that are in the firmware).
If the driver is missing, add either key to the board's default.px4board file, or enable it in boardconfig under Drivers > Distance sensors, and then build and upload the firmware.
The driver does not start until it is enabled using the parameters in PX4 Configuration.
PX4 Configuration
Configure the serial port on which the rangefinder will run using SENS_TFMINI_CFG, and then reboot. There is no need to set the baud rate for the port, as this is configured by the driver. If the port is already used by another function, see Deconflicting Ports in Serial Port Configuration.
If the parameter is not available in QGroundControl then the driver is not in the firmware: see Firmware Support.
The driver does not configure the sensor, so the sensor must be at its factory settings: UART interface, 115200 baud, and the Standard 9 bytes (cm) output format (not Pixhawk or Standard 9 bytes (mm)). If these have been changed, reset the sensor to its defaults as described in the Benewake user manual.
SENS_TFMINI_HW selects the model and sets the range limits PX4 reports. Leave it at its default 1 (TFMINI) for the TFmini-S and TFmini Plus.
The configuration that is common to all rangefinders, such as the sensor position offsets used by the estimator, is covered in Rangefinders > Configuration/Setup.
Testing
You can check that the driver is running, and see its error counters, using the QGroundControl MAVLink Console:
tfmini statusYou can observe the published measurements with:
listener distance_sensorThe sensor type is reported as laser, with minimum and maximum distances of 0.4 m and 12 m.
The measurements can also be viewed in the DISTANCE_SENSOR message in the QGroundControl MAVLink Inspector. For more information see Rangefinders > Testing.
Further Information
- Modules Reference: Distance Sensor (Driver): tfmini
- TFmini-S Datasheet and User Manual (Benewake)
- TFmini Plus Datasheet and User Manual (Benewake)