Forum Home › Forums › Communicating with Devices › Communication error: receiving data from device
- This topic has 10 replies, 2 voices, and was last updated 1 year, 10 months ago by Mikhail.
-
AuthorPosts
-
May 25, 2022 at 9:45 am #10295ThovParticipant
Hi, it seems I’m having trouble with receiving data over MOD-bus as I get continually “Communication error!” in the line stats. I’ve used Simply Modbus Master to verify that the devices do communicate properly, so it seems the issue is within my Rapid Scada settings.
Line 1 stats:
https://imgur.com/gallery/PSCxjkASimply Modbus Master:
https://imgur.com/gallery/3OLPps2Serial port settings:ยจ
https://imgur.com/gallery/kLQBXMzSincerely
ThovMay 25, 2022 at 10:45 am #10296ThovParticipantI can also add that the device debugger prints request info when Rapid Scada requests data from it, as seen in the lines “RegCoilCB rd: 1, N …” :
https://imgur.com/gallery/YM63sYiMay 25, 2022 at 12:34 pm #10297MikhailModeratorHi,
Please send a screenshot of the device properties in Communicator.
Do you use Modbus RTU via COM-port or Modbus TCP?May 25, 2022 at 12:39 pm #10298ThovParticipantHi,
I hope these are the device properties you requested:
https://imgur.com/gallery/pxFga5tI use Modbus RTU via COM-port.
May 25, 2022 at 2:06 pm #10299MikhailModeratorThanks.
Set Call Number to empty in the device settings in Communicator and in the Device table of the configuration database.
Also set Period to zero.
Then upload the project to run.If doesn’t work, send new logs.
May 25, 2022 at 2:07 pm #10300MikhailModeratorKeep only 1 device active to make tests clear.
May 25, 2022 at 2:19 pm #10301ThovParticipantDone, but no change. The device still outputs that it receives the requests from Rapid Scada as before.
Line 1 parameters:
https://imgur.com/gallery/lpEA0kSDevices:
https://imgur.com/gallery/dBnIxdRLine 1 stats:
https://imgur.com/gallery/ilVwN3uMay 25, 2022 at 2:41 pm #10302MikhailModeratorNow it is better.
Copy the request as a text here (Ctrl+C).
Then compare requests in Communicator and in Simply Modbus Master by this tool.May 25, 2022 at 2:43 pm #10303MikhailModeratorYou should set Address in the Devices table.
May 25, 2022 at 8:29 pm #10304ThovParticipantAlright, it seems things have been solved:
I used your linked site and input the request first from Rapid Scada (00 01 00 01 00 10 6D D7) and got this:
00 Slave address 0x00 (0)
01 Function code 0x01 (1) – Read Coils
00 01 Starting address Physical: 0x0001 (1)
Logical: 0x0002 (2)
00 10 Quantity 0x0010 (16)
6D D7 CRC 0x6DD7 (28119)Then I did the same for a working coil request from Simply Modbus Master (01 01 00 00 00 10 3D C6) and got this:
01 Slave address 0x01 (1)
01 Function code 0x01 (1) – Read Coils
00 00 Starting address Physical: 0x0000 (0)
Logical: 0x0001 (1)
00 10 Quantity 0x0010 (16)
3D C6 CRC 0x3DC6 (15814)So the slave address was mismatching. I then went to Configurator Database -> Devices and set the address of the masterboard to 1:
https://imgur.com/gallery/p35RlR9I then reuploaded, and got successful data from masterboard (device nr. 1)!
https://imgur.com/gallery/IYeezmeThen I did the same as the previous step for the other two devices (device nr. 2 and 3), i.e. Configurator Database -> Devices and set their addresses to 1 as well. BUT: I left their Call numbers as 127.0.0.1. Remember that I set the Call number for device nr. 1 to blank as per your request at 2:06pm.
Then I set them to be active again in Instances -> Default -> Communicator -> Communication lines -> Line 1 parameters:
https://imgur.com/gallery/Rw9A1qPThen I reuploaded, and now I have all data coming from my devices, so we’re back in business ๐
For the record, I don’t yet know precisely what I did wrong the first time or why it did not work, but I see that the addresses need to match, obviously – you probably have a better idea about why.
May 26, 2022 at 10:12 am #10305MikhailModeratorThe preferable address is taken from the configuration database.
However, it’s more clear when the addresses matched. It’s possible to sync addresses by a tool after they changed manually. -
AuthorPosts
- You must be logged in to reply to this topic.