CODESYS - the IEC 61131-3 automation software

Welcome to the official CODESYS Forum
Deutsche Version English version russian version 
It is currently Thu Jul 19, 2018 3:18 am

All times are UTC+01:00




Post new topic  Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Thu Jun 14, 2018 6:04 pm 
Offline

Joined: Thu Jul 09, 2015 9:55 pm
Posts: 24
Hello

Going to set up some generic modbus registers in Wagos e!COCKPIT. The device I'm connecting to has a table that specifies data with "function code 4h" and a table with addresses from 500, 501, 502 and onwards.

In e!COCKPIT when I create a new generic modbus variable I can set function code "ReadInputRegisters (FC 4)", and also a number in "Register" and "Offset".
What do I put in Register and Offset in this case?

I dont have the equipment so I can't do any testing yet.


You do not have the required permissions to view the files attached to this post.


Top
   
PostPosted: Fri Jun 15, 2018 11:27 am 
Offline
Frequent User
Frequent User

Joined: Sun Apr 15, 2007 1:18 am
Posts: 147
Hello,

I have never worked with Wagos e!COCKPIT, but usually when we define a Modbus communication we define the address of the first variable (in your exemple 500) to read and the number of variables to read.

Generally, the address of the first variable can be:
- the number of the variable, for example for% MW100, the address will be 100. This is the case with some PLC.
- User-defined in slave configuration (example with Raspberry Pi).

Hoping this helps you

Best regard.


Top
   
PostPosted: Mon Jun 18, 2018 10:58 pm 
Offline

Joined: Thu Jul 09, 2015 9:55 pm
Posts: 24
Yeah, seems to work fine when I'm not using the offset field. Checking array-box enables me to define length after defined address.

But how do you do it when writing to control words with function code 16? I mean do you have to reset the bits manually?


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 3 posts ] 

All times are UTC+01:00


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited