TOF MINI Range Sensor
| SKU | Product |
|---|---|
| 35107 | TOF MINI Range Sensor |
Features
This laser distance measurement module is based on a D-TOF single-point laser sensor, has a built-in MCU, supports sunlight suppression and cover dirt resistance algorithms, and can measure the target distance. The optical cover is used for dust protection and stray light suppression, and the ambient light resistance is 20K Lux.
Disclaimer
The TOF MINI Range Sensor series is not authorized for use in critical applications where failure could impact personal safety (e.g., life support). In such applications, failure of the TOF MINI Range Sensor series could cause severe personal injury or death. Customers who use or sell the TOF MINI Range Sensor series in such safety-critical applications do so at their own risk and agree to fully indemnify Waveshare and its representatives against any damages arising from such use.
The TOF MINI Range Sensor series provided by Waveshare has obtained EU laser product certification. Before using or selling these products, verify whether these certifications apply in your region. Products incorporating the TOF MINI Range Sensor series must obtain approval from the relevant authorities in accordance with local laser product regulations before being sold in that region.
Applications
- Distance detection for smart devices
- Robot obstacle avoidance
- Drone altitude measurement
- Liquid level detection
- Industrial automation ranging
Working Principle
This product uses D-TOF (Direct Time of Flight) ranging technology, emits near-infrared light with a wavelength of 940 nm, and calculates the target distance by measuring the round-trip time of the light from emission to reception of the light reflected by the target. TOF is commonly used in scenarios such as personnel proximity detection, robot obstacle avoidance, and camera autofocus.
Specifications
| Parameter | Specification |
|---|---|
| Model | TOF MINI Range Sensor |
| Typical ranging range | 0.02 m - 4 m |
| Accuracy | ± (1% - 3%) |
| Field of view | 25° - 30° |
| Refresh rate | Default 30 Hz, maximum 90 Hz (supports bulk customization) |
| Ambient light immunity | 20K Lux |
| Operating temperature | -20℃ - +70℃ |
| Operating humidity | 35% - 80%RH |
| Laser safety class | LASER CLASS 1 (IEC 60825-1: 2014) |
| Wavelength | 940 nm (near-infrared) |
| Light source | VCSEL |
| Communication interface | UART |
| Baud rate | 115200 |
| Data bits | 8 |
| Stop bits | 1 |
| Parity | NONE |
| Supply voltage | 4 V - 5.6 V |
| Communication Level | LVTTL (3.3 V) |
| Power consumption | 100 mW - 140 mW |
| Average current / Peak current | 25 mA / 26 mA |
| Product weight | Less than 3 g |
| Housing material | PC |
| Storage temperature | -40℃ - +80℃ |
| Product dimensions | Length 17.35 mm, Width 13.00 mm, Height 6.6 mm |
- The sensor's IO level is 3.3 V. If using 5 V IO levels, a level shifter is required; otherwise, the sensor may be damaged.
Pinout
| Pin | Label | Description |
|---|---|---|
| 1 | VCC | 5 V power positive |
| 2 | RXD | UART input |
| 3 | TXD | UART output |
| 4 | GND | Power ground |
Protocol Analysis
Click to expand
UART Communication Process
The default serial configuration is: 8 data bits, 1 stop bit, no parity, no flow control, default baud rate 115200. This protocol outputs distance data in ASCII format via UART. The following describes how to parse the output. The protocol consists of a Header, Distance value, Separator, Status, and Tail. Header, Separator, and Tail are fixed values (see table below). Distance is the measured distance, and Status indicates the measurement state.
- The protocol contains the following parts: Header + Distance + Separator + Status + Tail.
- Protocol field overview:
| Field | Byte Length | Description |
|---|---|---|
| Head | 1 | Frame header |
| Distance | 1 - 5 | Distance value |
| Separator | 2 | Separator |
| Status | 1 - 3 | Status |
| Tail | 1 | Frame tail |
For example, raw data: 20 33 32 37 2C 20 00 0A
- Parsing table:
| Data Frame | Example (HEX) | ASCII Character |
|---|---|---|
| Head | 20 | Space |
| Distance | 33 32 37 | 327 |
| Separator | 2C 20 | Comma, Space |
| Status | 00 | 0 |
| Tail | 0A | \n |
| This measurement outputs a distance of 327 mm, with status 0 indicating a valid distance. The header, separator, and tail are fixed values. |
Quick Test
-
Use the test software Serial Debug Assistant together with the USB TO TTL (B) for quick viewing of serial output.
-
Test Preparation
- Windows computer
- USB TO TTL (B) 1 PCS
- TOF MINI Range Sensor 1 PCS
- Matching cables
-
Hardware Connection
-
Connect as shown in the figure below.

-
-
Start Testing
- Connect the USB TO TTL (B) to a USB port on the computer.
-
Open the serial port debugging assistant (SSCOM), select the corresponding port number, set the baud rate to 115200, data bits to 8, stop bits to 1, and parity to NONE.
-
After opening the serial port, you can view the distance data output by the sensor.

-
You can also turn off HEX display to see the raw data directly.

-
- Connect the USB TO TTL (B) to a USB port on the computer.
