News:

  • October 29, 2026, 02:02:43 AM

Login with username, password and session length

Author Topic: Using modbus tcp through a ecom100  (Read 27879 times)

Bobby

  • Sr. Member
  • ****
  • Posts: 60
Using modbus tcp through a ecom100
« on: March 28, 2015, 07:49:40 AM »
Hello all!

Fairly new to do-more and so far really enjoying it!

I need to do a little modbus tcp and am not sure if it is possible through an ecom100 card on the do-more. I am using the modbus write instruction and can successfully do it through the internal Ethernet port but cannot for the life of me find a way to do it with the ecom100 cards. I know the cards say they support modbus but I must be missing something!

BobO

  • Host Moderator
  • Hero Member
  • *****
  • Posts: 6179
  • Yes Pinky, Do-more will control the world!
Re: Using modbus tcp through a ecom100
« Reply #1 on: March 28, 2015, 10:23:18 AM »
You can. I don't remember the details though, I can get you an answer Monday. I wanna think it involves setting up the peer table in the ECOM100 through NetEdit, and then using DLRX and DLWX to the node configured for Modbus/TCP.
"It has recently come to our attention that users spend 95% of their time using 5% of the available features. That might be relevant." -BobO

Bobby

  • Sr. Member
  • ****
  • Posts: 60
Re: Using modbus tcp through a ecom100
« Reply #2 on: March 28, 2015, 07:44:50 PM »
Okay, thanks a bunch!

Greg

  • HostTech
  • Host Moderator
  • Hero Member
  • *****
  • Posts: 702
  • Hmmm...
    • Host Engineering, Inc.
Re: Using modbus tcp through a ecom100
« Reply #3 on: March 30, 2015, 02:59:24 PM »
Bobby, here's what you need to do:
1. Configure Peer-to-peer Configuration table in NetEdit3 for the ECOM100. That involves starting NetEdit3, right-clicking on your ECOM100, selecting Peer-to-peer Configuration. Choose <Add> button, select Modbus TCP and choose the IP address of the slave, port # and Unit ID (which is usually 255 or don't care). At the very top select an RX/WX Device Number.
2. In Do-more Designer you would use a DLWX and choose the Slave ID parameter to match the RX/WX Device Number you chose above.
3. Now here is where it gets "fun" because you must now choose the proper To DL parameter for your DLWX. Choosing this will determine what Modbus Function Code and Modbus address the ECOM100 generates a packet for. Use the attached PDF file on the "ECOM100 AS MODBUS TCP CLIENT in Do-more" page to figure this out.

As an example choosing To DL: V0 will cause the ECOM100 to send out a Function Code 16 "Preset Multiple Registers" at Holding Register 1. A To DL: Y0 would cause it to send out a FC15 "Force Mltiple Coils" to Modbus Coil 2049.

It's not pretty but that's because we want you to use the onboard Ethernet port of the Do-more and the ECOM100 was designed for use with DL-PLCs, not Do-more.
« Last Edit: September 29, 2016, 04:14:25 PM by Greg »
There are two types of people in the world; those that can extrapolate from incomplete data sets.

Bobby

  • Sr. Member
  • ****
  • Posts: 60
Re: Using modbus tcp through a ecom100
« Reply #4 on: June 23, 2016, 10:08:45 AM »
This is old I know but I am about to do another project and need to look at this again. Maybe though there is a better way now that I have more experience with do-more. I will add a little explanation as to what I am trying to do.

So I have about 15 conveyor drives that use modbus to set the speeds. They all operate on Ethernet. The problem I have is I also need to communicate out via tcp/ip using the do-more Ethernet port. I would prefer all the drives be ran on a separate network so that I do not need to have all of them on the main company network. Would using the ecom100 be my only option?

BobO

  • Host Moderator
  • Hero Member
  • *****
  • Posts: 6179
  • Yes Pinky, Do-more will control the world!
Re: Using modbus tcp through a ecom100
« Reply #5 on: June 23, 2016, 10:13:26 AM »
Mostly depends on what you need Ethernet for in the CPU. If it is just programming, use the ECOM100 for programming and in the onboard port for controlling the drives. If you need the onboard port for other stuff, then yeah, the ECOM100 is the best bet for the drives. Harder, but it will work.
"It has recently come to our attention that users spend 95% of their time using 5% of the available features. That might be relevant." -BobO

Bobby

  • Sr. Member
  • ****
  • Posts: 60
Re: Using modbus tcp through a ecom100
« Reply #6 on: June 23, 2016, 10:23:30 AM »
Yes I will need the on-board port to stream in/out tcp messages to the clients server. So I will have to dig into how to do this with an ecom100 now. I am sure I will have some questions along the way though ???

I think my first big question is how to get it to write out the message to multiple IP Addresses.

BobO

  • Host Moderator
  • Hero Member
  • *****
  • Posts: 6179
  • Yes Pinky, Do-more will control the world!
Re: Using modbus tcp through a ecom100
« Reply #7 on: June 23, 2016, 10:27:10 AM »
I think my first big question is how to get it to write out the message to multiple IP Addresses.

TCP is point to point, so you really can't do multiple addresses without multiple connections.
"It has recently come to our attention that users spend 95% of their time using 5% of the available features. That might be relevant." -BobO

Bobby

  • Sr. Member
  • ****
  • Posts: 60
Re: Using modbus tcp through a ecom100
« Reply #8 on: September 29, 2016, 01:30:30 PM »
Okay so I am finally back on this project. Having issues using the ECOM100 card. How do I get netedit3 to see it without IPX protocol? No more windows xp around for me to use it  ???

Greg

  • HostTech
  • Host Moderator
  • Hero Member
  • *****
  • Posts: 702
  • Hmmm...
    • Host Engineering, Inc.
Re: Using modbus tcp through a ecom100
« Reply #9 on: September 29, 2016, 01:47:34 PM »
You probably have more than on NIC on your PC. So, first try, in NetEdit3 on the menu, select Network, Adapter, and pick something besides Default.

If that doesn't work, then you'll probably have to manually disable the NIC(s) you are not using. Windows is just picking the NIC for you and sometimes it picks the "wrong" one.

These are the most common problems.

Let us know if this is not it.
There are two types of people in the world; those that can extrapolate from incomplete data sets.

Bobby

  • Sr. Member
  • ****
  • Posts: 60
Re: Using modbus tcp through a ecom100
« Reply #10 on: September 29, 2016, 02:30:08 PM »
I double checked and still nothing, I can see the 3 PLC's on the network but not the ECOM100 card. I see that it is installed via do-more though.

Bobby

  • Sr. Member
  • ****
  • Posts: 60
Re: Using modbus tcp through a ecom100
« Reply #11 on: September 29, 2016, 02:52:22 PM »
Nevermind...I mean really you gotta plug the network cable in.... ::) ::) ::) ::) Is it Friday yet!

Greg

  • HostTech
  • Host Moderator
  • Hero Member
  • *****
  • Posts: 702
  • Hmmm...
    • Host Engineering, Inc.
Re: Using modbus tcp through a ecom100
« Reply #12 on: September 29, 2016, 02:55:40 PM »
LOL... Yeah, it helps if you get the cable closer to the connector.  ;D
There are two types of people in the world; those that can extrapolate from incomplete data sets.

Bobby

  • Sr. Member
  • ****
  • Posts: 60
Re: Using modbus tcp through a ecom100
« Reply #13 on: September 29, 2016, 03:27:52 PM »
Bobby, here's what you need to do:
1. Configure Peer-to-peer Configuration table in NetEdit3 for the ECOM100. That involves starting NetEdit3, right-clicking on your ECOM100, selecting Peer-to-peer Configuration. Choose <Add> button, select Modbus TCP and choose the IP address of the slave, port # and Unit ID (which is usually 255 or don't care). At the very top select an RX/WX Device Number.
2. In Do-more Designer you would use a DLWX and choose the Slave ID parameter to match the RX/WX Device Number you chose above.
3. Now here is where it gets "fun" because you must now choose the proper To DL parameter for your DLWX. Choosing this will determine what Modbus Function Code and Modbus address the ECOM100 generates a packet for. Use the attached PDF file on the "ECOM100 AS MODBUS TCP CLIENT in Do-more" page to figure this out.

As an example choosing To DL: V0 will cause the ECOM100 to send out a Function Code 16 "Preset Multiple Registers" at Holding Register 1. A To DL: Y0 would cause it to send out a FC15 "Force Mltiple Coils" to Modbus Coil 2049.

It's not pretty but that's because we want you to use the onboard Ethernet port of the Do-more and the ECOM100 was designed for use with DL-PLCs, not Do-more.

Greg,
   I am a little confused on how to correctly address the "DL" portion of the "DLWX" instruction. I need to write to multiple registers starting at 1600. Writing 8 registers total. I tried using V1600 but that doesn't appear to work?

Greg

  • HostTech
  • Host Moderator
  • Hero Member
  • *****
  • Posts: 702
  • Hmmm...
    • Host Engineering, Inc.
Re: Using modbus tcp through a ecom100
« Reply #14 on: September 29, 2016, 04:08:38 PM »
Believe me, I totally understand the confusion. That's why I said in Step 3, "...here's where it gets 'fun'...".

Using the PDF file I attached to the above post, looking on page 2, you will see in the PLC Instruction column, you pick DLWX. Now since you are wanting to write to Holding Registers 1600 to 1607 (8 registers, i.e. 16 bytes) then you have to do the math. The To DL parameter expects a DL memory address, which are all octally addressed and you are writing to decimal addresses as well as picking a Modbus function code. Yes, this is a horrible hack of a hack. But it was necessary in DL world. Of course, I'm gonna say right here if you had a Do-more with an Ethernet port this is a piece of cake, you just use the MWX - Modbus Write instruction pick your function code and pick your Holding Register address. Easy. But, back to the hack...

The table shows that Holding Register 1 would be addressed using V0. Thus Holding Register 1600 would be addressed using V3077. That's because 1600 decimal is 3100 octal, but I subtract 1, so 3100 octal minus 1 is 3077. Thus, you would enter V3077 and 16 bytes.

If that doesn't work, then try V3100, or V3076, or something very close to that.

Let me know.
There are two types of people in the world; those that can extrapolate from incomplete data sets.