Skip to content

基于electron开发的modbus客户端,后端有Go和Python两个版本,前端使用vue3开发

License

Notifications You must be signed in to change notification settings

600888/modbus-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Modbus客户端

介绍

前端使用Vue,后端使用Python,客户端使用Electron开发的一款Modbus测试工具

前端:TypeScript + vue3 + Element Plus

后端:

Python版本:Python + Flask + SqlAlchemy + Sqlite + PyModbus

Go版本:Go + GoOrm + GoZero + Sqlite + goburrow/modbus

客户端:Electron egg框架 项目地址:https://www.kaka996.com/

界面展示

  1. 新建连接

  2. 新建从机

  3. 设置每台从机每种寄存器的地址范围

  4. 读取寄存器,可选择自动读取或手动读取,自动读取可以选择读取时间间隔

  5. 选中表格行可以让寄存器按照不同类型解析,目前支持short、long、float格式,可以显示对应的10进制和16进制数

    • 按照short解析

    • 按照long解析

    • 按照float解析

  6. 写入寄存器

    • 写入线圈寄存器

      支持05功能码单点循环写入和15功能码连续写入

      举例说明:假如要写入1-10号线圈

      单点循环写入:发送10条05功能码写入命令,写入10次

      连续写入:发送1条15功能码写入命令,一次性写入10个线圈

    • 写入保持寄存器

      写入方式和上面线圈寄存器类似,支持写入不同类型不同字节序,可以在类型下拉框勾选

  7. 查看实时报文

    读取和写入命令的报文细节都可以在这里查看到

打包方法

前端打包

  1. 构建

    npm run build-frontend

后端打包

使用Python作为后端

  1. 进入python文件夹目录,建立虚拟环境,安装依赖

    pip install -r requirements
  2. 回到根目录执行打包命令

    npm run build-python

使用Go作为后端

  1. 单独打包命令

    npm run build-go-w 

Electron打包

  1. 构建python

    npm run build

制作安装包

  1. windows

    npm run build-w
    
  2. linux

    npm run build-l
  3. mac

    npm run build-m
    

About

基于electron开发的modbus客户端,后端有Go和Python两个版本,前端使用vue3开发

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published