Help
  • Explore Community
  • Get Started
  • Ask the Community
  • How-To & Best Practices
  • Contact Support
Notifications
Login / Register
Community
Community
Notifications
close
  • Forums
  • Knowledge Center
  • Events & Webinars
  • Ideas
  • Blogs
Help
Help
  • Explore Community
  • Get Started
  • Ask the Community
  • How-To & Best Practices
  • Contact Support
Login / Register
Sustainability
Sustainability

Join our "Ask Me About" community webinar on May 20th at 9 AM CET and 5 PM CET to explore cybersecurity and monitoring for Data Center and edge IT. Learn about market trends, cutting-edge technologies, and best practices from industry experts.
Register and secure your Critical IT infrastructure

WRITE_REG from Quantum to M580

Modicon PAC Forum

A forum for topics related to the scope of Modicon PAC offers and ecosystem along the whole lifecycle: Modicon M580 and 340, EcoStruxure Control Expert, EcoStruxure Process Expert (Unity Pro) and more.

cancel
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Home
  • Schneider Electric Community
  • Industrial Automation
  • Modicon PAC Forum
  • WRITE_REG from Quantum to M580
Options
  • Subscribe to RSS Feed
  • Mark Topic as New
  • Mark Topic as Read
  • Float this Topic for Current User
  • Bookmark
  • Subscribe
  • Mute
  • Printer Friendly Page
Invite a Co-worker
Send a co-worker an invite to the portal.Just enter their email address and we'll connect them to register. After joining, they will belong to the same company.
You have entered an invalid email address. Please re-enter the email address.
This co-worker has already been invited to the Exchange portal. Please invite another co-worker.
Please enter email address
Send Invite Cancel
Invitation Sent
Your invitation was sent.Thanks for sharing Exchange with your co-worker.
Send New Invite Close
Top Experts
User Count
MatthewM
Lt. Commander MatthewM
8
RoozeeR
Lt. Commander RoozeeR Lt. Commander
7
Trinxs1
Lt. Commander Trinxs1 Lt. Commander
6
ciupol
Lieutenant ciupol
6
View All
Related Products
product field
Schneider Electric
Modicon M580
product field
Schneider Electric
Modicon Quantum

Invite a Colleague

Found this content useful? Share it with a Colleague!

Invite a Colleague Invite
Back to Modicon PAC Forum
DanielCoria
Crewman DanielCoria
Crewman

Posted: ‎2021-05-04 08:25 AM . Last Modified: ‎2021-05-05 06:01 AM

1 Like
12
5166
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-05-04 08:25 AM . Last Modified: ‎2021-05-05 06:01 AM

WRITE_REG from Quantum to M580

I´m doing upgrade from Quantum base to M580, but there´s a Modbus RTU network with VFDs on it, and the FB Write_Red is used to write them. Now, I need to do the same in the M580 programm but I dont´t know witch FB must I use. Also I need replace READ_REG. I´m using Unirt Pro XL v12

 

Capture.JPG

 

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

  • All forum topics
  • Previous Topic
  • Next Topic
Replies 12
AlastairF
AlastairF Schneider Alumni (Retired)
Schneider Alumni (Retired)

Posted: ‎2021-05-05 02:12 PM

0 Likes
11
5146
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-05-05 02:12 PM

The commands available for the M580 are READ_VAR and WRITE_VAR.

These also use a different addressing structure (ADDM) so you will have to change that as well. If you are indexing the Unit ID addresses when communicating with drives via an Ethernet gateway then you can manipulate the UnitID Field in the Output parameter structure.

Also if you are cascading the commands, ensure that you complete the first command before initiating the second command. Your overall response time will be depended on the response time of the individual drives.

 

One other option to investigate is the use of ModBus DTM if the drives each have a unique IP address.

This would allow for a combined Read/ Write in one transaction (ModBus FC23) that is a bit more efficient.

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

DanielCoria
Crewman DanielCoria
Crewman

Posted: ‎2021-05-17 08:30 AM

In response to AlastairF
0 Likes
1
5111
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-05-17 08:30 AM

The gateway IP is 192.168.3.86 and there is 12 IDs:

 

Mobbus ID.jpeg

 

Can you help me with the configuration of ADR ?

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

AlastairF
AlastairF Schneider Alumni (Retired)
Schneider Alumni (Retired)

Posted: ‎2021-05-17 04:00 PM

In response to DanielCoria
0 Likes
0
5104
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-05-17 04:00 PM

(*ADDM example in ST
This is using your IP address and a default 255 for the Unit ID
communicating via the M580 CPU Ethernet port
*)

ADDM_struct := ADDM ('0.0.3{192.168.3.86}255');

(* you then manipulate the contents of ADDM_struct[3] to set the Unit ID to what you want for your field device.
This is described in the ADDM Help. Note the Fields are described in Bytes, the ADDM structure is INT
You need to keep the value of the lower Byte of ADDM_struct[3] as this is manipulated by the instruction.
You then change the upper Byte to your target Unit ID using variable 'Unit_ID'.
*)

WORD_AS_BYTE (IN := INT_TO_WORD(ADDM_struct[3]),
LOW => lowB,
HIGH => highB);
ADDM_struct[3]:= WORD_TO_INT(BYTE_AS_WORD(lowB,INT_TO_BYTE(Unit_ID)));

(*the variable 'ADDM_struct' may now be used as the address input to the READ_VAR block
*)

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

btekkiam
Lieutenant JG btekkiam Lieutenant JG
Lieutenant JG

Posted: ‎2021-05-19 10:08 AM

In response to AlastairF
0 Likes
8
5097
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-05-19 10:08 AM

Read_Var and Write_Var would indeed be the best drop-in replacements for the modernization.

 

You could also use the Data_Exch block, which allows you to configure any Modbus FC including FC23 of course.

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

AlastairF
AlastairF Schneider Alumni (Retired)
Schneider Alumni (Retired)

Posted: ‎2021-05-19 07:32 PM

In response to btekkiam
0 Likes
7
5092
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-05-19 07:32 PM

DATA_EXCH is probably the most powerful communication block in the ECE library.

You can use it for EIP, ModBusTCP and serial communications.

 

The only problem is that it is the worst documented block in the Help file - bar none.

There is no list of supported functions for the relevant communications types or protocols.

 

You could take the example of M340 communications from the Help and start to modify it for FC23 but you would be guessing as to location for received data and write data

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

btekkiam
Lieutenant JG btekkiam Lieutenant JG
Lieutenant JG

Posted: ‎2021-05-20 02:34 AM

In response to AlastairF
0 Likes
6
5087
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-05-20 02:34 AM

Here is a section with a sample DFB to use Data_Exch with FC23.

The query registers sequence actually follows the Modbus protocol reference manual, so not quite hard to program.

Between 2 M580s, I found I had to set both Read and Write byte swap flags to true.

Attachments
DATA_EXCH_FC23_TEST.zip
  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

DanielCoria
Crewman DanielCoria
Crewman

Posted: ‎2021-06-01 07:47 AM

In response to btekkiam
0 Likes
4
5025
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-06-01 07:47 AM

Fc23.JPGrack.JPG

 

 

 

Address is Ok? Because I can´t read anythig on RD_DATA array.

 

var.JPG

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

btekkiam
Lieutenant JG btekkiam Lieutenant JG
Lieutenant JG

Posted: ‎2021-06-01 07:58 AM

In response to DanielCoria
0 Likes
3
5022
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-06-01 07:58 AM

The address looks a bit off. When polling from an M580 CPU, the channel has to be set to 3. So change it to '0.0.3{192.168.3.86}81'

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

DanielCoria
Crewman DanielCoria
Crewman

Posted: ‎2021-06-01 08:02 AM

In response to btekkiam
0 Likes
2
5020
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-06-01 08:02 AM

Already tryed it. I´m using service port by the way (1).

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

btekkiam
Lieutenant JG btekkiam Lieutenant JG
Lieutenant JG

Posted: ‎2021-06-01 08:19 AM

In response to DanielCoria
0 Likes
1
5017
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-06-01 08:19 AM

First, be aware that the Trigger variable needs a positive transition. So you could do this manually or connect %S6 to the trigger pin.

If you have done this, you could do some basic troubleshooting for the Modbus comms- 

 

  1. Can you connect your laptop instead of the CPU and use Modscan to poll the VFD through the gateway? This will confirm that this communication path is ok.
  2. Can you post the screenshot of the CPU's and the gateway's IP address configuration?
  3. Lastly in your original post, you used 1 as the write register and 4 as the read register. I believe these are 4x addresses and you should use 0 and 3 respectively for Data_Exch. Can you change these and check?

 

 

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

DanielCoria
Crewman DanielCoria
Crewman

Posted: ‎2021-06-01 08:42 AM

In response to btekkiam
0 Likes
0
5014
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-06-01 08:42 AM

1: yes, I can read/write

 

MBM.JPG

 

2:

cpu ip.JPGcpu ip 2.JPGcpu ip 3.JPG

 

3:  Tested both config, same result

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

DanielCoria
Crewman DanielCoria
Crewman

Posted: ‎2021-06-01 09:19 AM

In response to btekkiam
1 Like
0
5009
  • Mark as New
  • Bookmark
  • Subscribe
  • Mute
  • Subscribe to RSS Feed
  • Permalink
  • Print
  • Email to a Friend
  • Report Inappropriate Content

Link copied. Please paste this link to share this article on your social media post.

Posted: ‎2021-06-01 09:19 AM

I didn´t notice registers was upside down, for the gateway EGX100 must be excatly read/write reg number to allow comms, otherwise you can´t read it even if the read parameters is OK.

 

Thank you all, for the support.

 

egx100 ok.JPGPAC ok.JPG

  • Tags:
  • english
Reply

Link copied. Please paste this link to share this article on your social media post.

To The Top!

Forums

  • APC UPS Data Center Backup Solutions
  • EcoStruxure IT
  • EcoStruxure Geo SCADA Expert
  • Metering & Power Quality
  • Schneider Electric Wiser

Knowledge Center

Events & webinars

Ideas

Blogs

Get Started

  • Ask the Community
  • Community Guidelines
  • Community User Guide
  • How-To & Best Practice
  • Experts Leaderboard
  • Contact Support
Brand-Logo
Subscribing is a smart move!
You can subscribe to this board after you log in or create your free account.
Forum-Icon

Create your free account or log in to subscribe to the board - and gain access to more than 10,000+ support articles along with insights from experts and peers.

Register today for FREE

Register Now

Already have an account? Login

Terms & Conditions Privacy Notice Change your Cookie Settings © 2025 Schneider Electric

This is a heading

With achievable small steps, users progress and continually feel satisfaction in task accomplishment.

Usetiful Onboarding Checklist remembers the progress of every user, allowing them to take bite-sized journeys and continue where they left.

of