Skip to content

Commit e1019b1

Browse files
committed
feat: 添加 Modbus RTU 支持,包括功能选择、地址和数量设置,自动生成 CRC16
1 parent 2999466 commit e1019b1

11 files changed

Lines changed: 711 additions & 1 deletion

CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,8 @@ add_executable(FluentSerialAssistant
6363
src/app/core/checksum_utils.h
6464
src/app/core/hex_utils.cpp
6565
src/app/core/hex_utils.h
66+
src/app/core/modbus_utils.cpp
67+
src/app/core/modbus_utils.h
6668
src/app/core/text_encoding.cpp
6769
src/app/core/text_encoding.h
6870
src/app/core/update_checker.cpp
@@ -82,6 +84,7 @@ add_executable(FluentSerialAssistant
8284
src/app/view/workbench/workbench_page_files.cpp
8385
src/app/view/workbench/workbench_page_internal.h
8486
src/app/view/workbench/workbench_page_layout.cpp
87+
src/app/view/workbench/workbench_page_modbus.cpp
8588
src/app/view/workbench/workbench_page_packets.cpp
8689
src/app/view/workbench/workbench_page_side_sections.cpp
8790
src/app/view/workbench/workbench_page_state.cpp

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ Fluent 串口助手是一个基于 C++17、Qt 6 Widgets 和 FluentQtWidgets 的
3434
- TX 着色:可选择发送记录显示颜色。
3535
- 数据发送:支持文本和 HEX 发送,支持 None、CR、LF、CRLF 行结束符。
3636
- 校验工具:支持 CRC16-Modbus、CRC16-CCITT、CRC32、LRC、XOR、SUM8 手动计算和发送时自动追加。
37+
- Modbus RTU:支持常用读写请求帧生成、CRC 自动追加、直接发送和响应摘要解析。
3738
- 发送历史:保留最近 20 条唯一发送记录。
3839
- 常用包:支持保存、载入、发送、删除和排序常用发送包。
3940
- 循环发送:支持毫秒级发送间隔。

docs/feature-roadmap.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,9 @@
8585

8686
### 4. Modbus RTU 辅助
8787

88-
增加常用 Modbus RTU 调试入口,降低手写帧成本。
88+
状态:已实现。
89+
90+
已经增加常用 Modbus RTU 调试入口,降低手写帧成本。
8991

9092
需求:
9193

0 commit comments

Comments
 (0)