improvment

This commit is contained in:
gitea 2024-09-25 22:17:14 +08:00
parent 1f4656f0b9
commit c88015ff78
6 changed files with 272 additions and 267 deletions

View File

@ -1,5 +1,17 @@
## 一、功能
### 1. Modbus 通信
### 2. 外部通信
### 3. HMI socket 通信
### 4. HMI xService 通信
## 三、相关文件以及路径
```
@ -30,8 +42,8 @@ sys_io_1.cfg
## 五、待办
- [ ] socket 断开后触发软急停,并恢复,目的是让所有运动的指令,停止运行防止意外发生
- [ ] 外部通信实现
-
## 九、目前存在问题
-

View File

@ -0,0 +1,8 @@
{
"id": "xxxxxxxxxxx",
"module": "fieldbus",
"command": "modbus.get_values",
"data": {
"mode": "all"
}
}

View File

@ -0,0 +1,12 @@
{
"id": "xxxxxxxxxxx",
"module": "fieldbus",
"command": "modbus.set_params",
"data": {
"enable_slave": true,
"ip": "192.168.0.160",
"port": 502,
"slave_id": 0,
"enable_master": false
}
}

View File

@ -2,9 +2,8 @@
"id": "xxxxxxxxxxx",
"module": "safety",
"command": "soft_limit.set_params",
"data":
{
"enable": true
"data": {
"enable": true,
"upper": [0,0,0,0,0,0,0],
"lower": [0,0,0,0,0,0,0],
"reduced_upper": [0,0,0,0,0,0,0],

View File

@ -75,7 +75,7 @@ def initialization():
# 打开外部通信
clibs.logger.info("配置并打开外部通信默认服务器8080端口后缀为 \"\\r\"...")
hr.set_socket_params(True, "", "name", "8080", "\r", 1, True, True, 0, 10)
hr.set_socket_params(True, "8080", "\r", 1)
# 关闭拖动
clibs.logger.info("关闭拖动模式...")

File diff suppressed because it is too large Load Diff