modbus调试不成功modscan32做主站可以收到数据但一直显示MODBUS MESSAGE TIME-OUT

helloMod 2017-06-09 09:47:34
刚接触485,我做的设备用modscan32调试连接不上
因为采用的是ttl串口,所以不考虑硬件连接问题,百分之百是可靠的

因为,在数据流中,可以看到黑色背景的数据,是从站发来的,完全无乱码

通信协议这样定制的

按道理来说,就这几个字节,而且顺序已经按照Modbus rtu格式排列好了,为甚么调试软件认为没数据收到呢?

解决不了了,感觉就剩一窗户纸了,求大神指条明路
...全文
15959 13 打赏 收藏 转发到动态 举报
写回复
用AI写文章
13 条回复
切换为时间正序
请发表友善的回复…
发表回复
calm0427 2021-07-31
  • 打赏
  • 举报
回复

减小 波特率

z414061998 2021-04-17
  • 打赏
  • 举报
回复
您好,请问怎么解决的。能我也连接不上Modscan
A15617215798 2019-10-29
  • 打赏
  • 举报
回复
我的程序不能和Modscan通讯,哪位大侠帮忙给我测试一下是哪里问题,悬赏200元
A15617215798 2019-10-29
  • 打赏
  • 举报
回复
我的程序不能和Modscan通讯
weixin_41950502 2019-10-09
  • 打赏
  • 举报
回复
可以加下我微信吗,我目前就遇到这样的问题,谢谢。
weixin_41718104 2019-09-18
  • 打赏
  • 举报
回复
兄弟我也遇到你这种问题了,是从站需要改通信协议吗?
ysj0815 2018-08-31
  • 打赏
  • 举报
回复
楼主能指导下吗,具体程序该怎么写,怎么改,还是要设置下调试工具
weixin_40763390 2017-10-24
  • 打赏
  • 举报
回复
怎么解决的,没看懂!能指点一下吗?
worldy 2017-10-24
  • 打赏
  • 举报
回复
设备地址是否正确(决定是否能被设备识别) 起始地址是否正确(设备地址其实是设备内部的存储单元,这个存储单元必须存在) CRC是否正确
helloMod 2017-06-09
  • 打赏
  • 举报
回复
引用 1 楼 bakw 的回复:
modbus保持寄存器每个寄存器都是双字节的,你返回的是单字节的,所以校验就通不过了 发送: [10] 从站地址 [03] 03功能码 [00][00] 起始地址 [00][02] 寄存器数量 [c7][4a] CRC校验 接收 [10] 从站地址 [03] 03功能码 [04] 返回的寄存器字节数,每个寄存器2字节,读两个寄存器,所以四个字节 [00][00] 寄存器1 [00][00] 寄存器2 [fb][32] CRC校验码
是的,根据你的指导,搞定了这个愚蠢的问题,请问如何给分结帖呢?
helloMod 2017-06-09
  • 打赏
  • 举报
回复 1
发现问题了,自己傻了,一个寄存器是两个字节 参考这个文档后发现的,哎,半路出家就是不行啊 ,没基础
笨狗先飞 2017-06-09
  • 打赏
  • 举报
回复
modsim32可以模拟modbus从站,调试有问题可以用这个软件模拟
笨狗先飞 2017-06-09
  • 打赏
  • 举报
回复
modbus保持寄存器每个寄存器都是双字节的,你返回的是单字节的,所以校验就通不过了 发送: [10] 从站地址 [03] 03功能码 [00][00] 起始地址 [00][02] 寄存器数量 [c7][4a] CRC校验 接收 [10] 从站地址 [03] 03功能码 [04] 返回的寄存器字节数,每个寄存器2字节,读两个寄存器,所以四个字节 [00][00] 寄存器1 [00][00] 寄存器2 [fb][32] CRC校验码
modscan32测试软件 1. ModScan Overview 1.1 Document/View Architecture 1.2 Modbus Data Definition 1.3 Display Formats 1.4 Connecting to a Modbus Network 1.4.1 Direct Serial Connections 1.4.2 Modem Connections 1.4.3 Network Connections 2. Menu Commands 2.1 File menu 2.2 Connection menu 2.3 Setup menu 2.4 View menu 2.5 Window menu 2.6 Help menu 3. Tool & Status Bars 3.1 Toolbar 3.2 Format Selections 3.3 Status Bar 4. Testing Features 4.1 Writing Data to the Modbus 4.2 Message Counters 4.3 Observing Serial Traffic 4.4 Capturing Data to Text File 4.5 User Defined Commands 4.6 Scripts 5. Using ModScan with a Database 6. Using OLE Automation 6.1 Overview 6.2 Automation Routines 7. Distribution/Registration 7.1 Pricing 7.2 Licensing 7.3 Support 7.4 Other Products 1. ModScan Overview The ModScan application operates as a MODBUS mastermodbus_protocol device in either RTU or ASCII transmission modes. ModScan may be used to access and modify data points contained in one or more MODBUS slave devices connected to the PC via a serial port, modem, or network. ModScan supports the standard MODBUS message types 01-06, 15 & 16, as well as providing the ability for you to exercise special features of a slave device by transmitting custom command strings and observing the response. ModScan is a useful test and diagnostic tool for verifying the proper slave response to MODBUS queries as well as being a low cost data collection tool for interfacing data into PC database and spreadsheet applications. 1.1 Document/View Architecture ModScan utilizes the standard Windows Multiple-Document-Interface, (MDI), architecture for displaying modbus data to the user. Each document represents a series, (array), of modbus data points identified by the following parameters: Slave Device Address Represents the physical device attached to the modbus network Data Type Internal data representation, (i.e. input, coil, register) Data Address Point address w

27,373

社区成员

发帖
与我相关
我的任务
社区描述
硬件/嵌入开发 单片机/工控
社区管理员
  • 单片机/工控社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧