Wago eCockpit CoDeSys - Modbus TCP Client Issue

Hal9000

Member
Join Date
Jun 2010
Location
London
Posts
140
Hi folks,

I'm running eCockpit version 1.3.1.4

I have set up a Modbus client function using the standard library
module: FbMbMasterTcp.

My server device (slave) is responding to requests and I can see the responses in my server are all successes. However I'm not getting any data back. I was expecting to see data in array awData.

I have uiReadAddress as 0. In modbus terms I'm used to thinking this equates to 40001.

I have attached my logic example - maybe there is something I've missed?

Best regards,

Justin

Modbus TCP Client Capture.jpg
 
I know nothing about "Wago eCockpit CoDeSys" and I can't hardly see your function block.

But it looks like you have 33 in your function code, and to read a modbus address - function code should be 03.

But maybe I just can't see it correctly.
 
Have you actually tried to read address 40001 ? Most of the modbus that I have ever worked with use the +1 offset - So if you wanted to read 40001 you actually address 40002.

That's about all I have to offer, sorry I could not have been of more help.
 
Justin,

I haven't done Modbus using WAGO eCockpit and I can't tell if the values in the MBQuery are values that are the current process values or the input values. Either way they don't look correct.

the uiReadAddress should be a pointer to the address of the array where the values from the Modbus function are placed,. ie: adr(YourReadArray(0)) and the uiReadQuantity should be the number of words in the array.

The uiWriteAddress and uiWriteQuantity are the same but with the write array being used for the address

The first word in the read array YourReadArray(0) will be filled with the data from 40001 (depending on the connected system's mapping) with the remaining words being placed into the rest of the array 40002 -> YourReadArray(1), 40003 -> YourReadArray(2).......

Hope I've explained well and am of help

Ken
 
Last edited:

Similar Topics

Hello, I am in possession of a WAGO PFC 200 750-8216 which I was successfully able to set up as a Modbus RTU Master to a slave device using...
Replies
0
Views
72
I have a project to setup base programs across multiple PLC platforms that can be used for Modbus communications to various sensors that have...
Replies
0
Views
113
Hello, I m having a problem with wago 750-862 plc. The plc won't start automatically in run mode after a power reboot. I've also tried the...
Replies
4
Views
337
Hello everyone, I am trying to setup a Wago 750-8100 PLC to send a text message out via ethernet port, if I get a Digital input that is true. I...
Replies
0
Views
342
How do you set up a message block for a REMOTE IO unit? (using ethernet IP)?
Replies
1
Views
590
Back
Top Bottom