5C distance frame and 5A command frame — H-series and VB modules
Transcribed from the manufacturer's own manuals · byte strings verified against the source PDF · no reverse-engineered guesses
The module streams a 5C frame with the distance in little-endian and a checksum computed as the inverse of the sum from byte 2 to the second-to-last byte; commands use a 5A header.
Frame layout
输出帧:(该手册未印出完整示例帧) = 5C 固定帧头 1 字节 + 距离(小端)+ 校验 1 字节;校验 = 自第 2 字节加到倒数第 2 字节后取反。命令帧:5A | 功能码 | 02 | 数据… | Checksum,校验函数 Check_Sum() 规则相同(第 2 字节至倒数第 2 字节求和取反)。另含 IIC 接口:IIC 从机默认地址 0x52;文本层可解析的寄存器 0x00、0x01、0x02、0x03、0x0C、0x0D;读写用单寄存器写 / 多寄存器读序列(原文 6.2),换行被断开的寄存器行未强行补全。
Command set
| Code | Function | Send | Reply | Notes / page |
|---|---|---|---|---|
0x0D | 读取序列号 Reading serial no. | 5A 0D 04 0D 0D 0D 0D BA | 5A 8D 04 10 01 00 00 5D | · p5 |
0x16 | 读取软件版本号 Read software version | 5A 16 02 16 16 BB | 5A 96 02 03 02 62 | · p5 |
0x06 | UART 波特率设置 Baud rate setting | 5A 06 02 80 04 73 | 5A 86 02 80 04 F3 | · p5 |
0x0B | 输出频率设置 Output frequency setting | 5A 0B 02 E7 03 08 | 5A 8B 02 E7 03 88 | · p5 |
0x1B | 读取输出频率 Read frequency | 5A 1B 02 1B 1B AC | 5A 9B 02 31 00 31 | · p5 |
0x1F | 切换至 IIC Switch to IIC | 5A 1F 02 1F 1F A0 | 5A 9F 02 1F 1F 20 | · p5 |
0x0A | 停止测距 Stop ranging | 5A 0A 02 00 00 F3 | 5A 8A 02 00 00 73 | · p5 |
0x0A | 启动测距 Start ranging | 5A 0A 02 02 00 F1 | 5A 8A 02 02 00 71 | · p5 |
0x00 | IIC 寄存器 0x00 Distance-Highbyte(Read-only) | IIC 寄存器 0x00(Read-only) | 2bytefordistance | 原文 6.3 Definitions of Registers · p7 |
0x01 | IIC 寄存器 0x01 Distance-Lowbyte(Read-only) | IIC 寄存器 0x01(Read-only) | 2bytefordistance | 原文 6.3 Definitions of Registers · p7 |
0x02 | IIC 寄存器 0x02 Lasercontrol(Write-only) | IIC 寄存器 0x02(Write-only) | 0:laseroff;1:laseron | 原文 6.3 Definitions of Registers · p7 |
0x03 | IIC 寄存器 0x03 LiDARID(Read-only) | IIC 寄存器 0x03(Read-only) | — | 原文 6.3 Definitions of Registers · p7 |
0x0C | IIC 寄存器 0x0C IICSlaveAddress(Read/write) | IIC 寄存器 0x0C(Read/write) | — | 原文 6.3 Definitions of Registers · p7 |
0x0D | IIC 寄存器 0x0D FactoryReset(Write-only) | IIC 寄存器 0x0D(Write-only) | Write0x01toperformfactoryreset | 原文 6.3 Definitions of Registers · p7 |
Timing and rates
p1 · MeasuringFrequency:200Hz p2 · 2 Frequency 200Hz(Alternative100/50/20/10/1Hz) p5 · =10Hz. p5 · 20/10/1Hz. p5 · 200Hz. p5 · 20/10/1Hz
Status codes and errors
p9 · - There is a risk of failure when using this product to measure high-reflective objects (such as 3M tapes)
What the source does not state
Where a manual prints an incomplete reply (for example only 55 for the
LD constant-on acknowledgement), this page reproduces that and stops — it does not pad the frame.
Anything not printed in the manual is absent here on purpose.
Models covered by this page
Source documents
- LRF100H · LRF100H.pdf (7 pages)
- LRF1500H · LRF1500H.pdf (6 pages)
- LRF200H · LRF200H.pdf (8 pages)
- LRF22VB · LRF22VB.pdf (9 pages)
- LRF300H · LRF300H.pdf (7 pages)
- LRF50H · LRF50H.pdf (7 pages)
- LRF50VB · LRF50VB.pdf (9 pages)
- LRF600H · LRF600H.pdf (6 pages)
Full transcription method: byte strings are asserted to exist in the extracted PDF text at build time, and re-checked against the page citation. If a string is not in the PDF, the page is not published.
Frequently asked questions
The same answers are published below as visible text and as FAQPage structured data, so the page and the markup cannot drift apart.
- What baud rate does the LRF100H family use?
- 115200 bps, 8 data bits, factory default; 9600 bps is selectable.
- How is the checksum computed?
- Command frames sum bytes 3–7; replies sum bytes 1–7, taking the low 8 bits. The manual states the two ranges separately.