TOF MINI Range Sensor
| SKU | Product |
|---|---|
| 35107 | TOF MINI Range Sensor |
Features
This laser ranging module is based on a D-TOF single-point laser sensor, with a built-in MCU and housed in a compact enclosure. It supports sunlight rejection and dirt compensation algorithms to measure target distance. With optical collimation design, it can measure distances to various targets under ambient light up to 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
TOF is an absolute distance detection technology. The sensor emits modulated near-infrared light, which reflects off objects. The sensor calculates the time difference or phase difference between emission and reflection, converts it into target distance, and generates depth information. TOF is commonly used in people proximity detection, robot obstacle avoidance, camera autofocus, and similar scenarios.
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 | 30 Hz (Batch customization supported, maximum up to 90 Hz) |
| 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 |
| Communication interface | UART |
| Baud rate | 115200 |
| Data Bits | 8 |
| Stop Bits | 1 |
| Parity | NONE |
| Supply voltage | 4 V - 5.6 V |
| Power consumption | 100 mW - 140 mW |
| Average current / Peak current | 25 mA / 26 mA |
| Product weight | 3 g |
| Housing material | PC |
| Storage temperature | -40℃ - +80℃ |
| Product dimensions | 17.37 × 13.00 × 6.88 (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 the computer's USB port.
- Open the serial debug assistant (SSCOM), select the corresponding COM port, set baud rate to 115200, data bits to 8, stop bits to 1, and parity to NONE.
- Open the serial port to view the distance data output by the sensor.
- Connect the USB TO TTL (B) to the computer's USB port.
-
①Send query command
-
②Obtain real-time data

