2026-03-01 18:11:32 +08:00

53 lines
1.2 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 主控程序
主控程序作为主调度协调控制器ModbusTCP和机械臂Fairino完成自动化抓取放置流程。
## 功能特点
1. **ModbusTCP客户端** - 连接控制器默认192.168.0.88:502
2. **Fairino机械臂控制** - 连接机械臂默认192.168.58.2
3. **8步工作流程** - 自动化抓取放置循环
4. **流程可视化** - 实时显示工作状态
5. **配置管理** - 运行时修改参数
## 工作流程
1. 机械臂运行到准备位置(可配置)
2. 触发控制器检测写ModbusTCP寄存器
3. 等待检测完成(轮询状态)
4. 读取目标坐标XYZ RPY并显示
5. 机械臂移动到抓取位置
6. 执行抓取
7. 机械臂移动到放置位置(可配置)
8. 执行放置
9. 循环执行,直到停止或失败
## 编译
```bash
cd Tools/DemoControlApp
qmake DemoControlApp.pro
nmake release
```
## 配置
点击界面上的"配置"按钮可修改:
- 控制器IP和端口
- 机械臂IP
- 准备位置XYZ + RPY
- 放置位置XYZ + RPY
- 抓取Z轴偏移
## 依赖
- AppCommon
- UICommon
- ModbusTCPClient
- FairinoRobotWrapper
- VrUtils
## 协议参考
ModbusTCP协议参考`App/StatorPosition/Doc/定子线圈ModbusTCP协议.md`