Sign in to follow this  
Followers 0
ASForrest

Remote Dial In to Micrologix 1100

14 posts in this topic

Hi all, I have an application where I'm trying to dial in remotely to a micrologix 1100 PLC. I would imagine it can be done, but I'm just not sure how to go about it. I have a Micrologx 1100, a Red Lion HMI, and a 3G modem all connected to an unmanaged switch in the cabinet. The PLC's IP address is 10.10.10.12, and the 3G modem's IP address (on the LAN) is 10.10.10.10. Obviously the modem has an IP address on the 3G network as well which changes every so often, let's for the sake of argument call it 169.123.123.10. So if I'm sitting in my office, my laptop has a wifi adaptor, connected to the office router, which connects to the internet, where i can see the 169.123.123.10 address of the modem in the panel, which can see the PLC though it's 10.10.10.10 IP address. How do I go about directing RS Linx down that path? Also, are the gateway settings of the PLC or modem relevant in this application? I've got a basic understanding of what the gateway address is all about, but I've never had to look too in depth at it. Thanks!

Share this post


Link to post
Share on other sites
I have about 40 cell modems in operation in one of our systems and quite a few more than that company wide. Question: You said "Obviously the modem has an IP address on the 3G network as well which changes every so often" Why do you think the IP changes every so often? If it does then you've got a problem. None of mine change but we use a network APN and our SIM cards are assigned an IP address from AT&T (our carrier). My modems have 1 IP address not two. I'm not sure what 2 addresses would be used for Have you set up port forwarding in the modem? If your modem is on a .123.123 subnet and the PLC is on a 10.10 subnet how is anything going to know how to get from the .123 subnet to the 10. subnet without port forwarding in the modem? Is this a private network or are you leaving your hardware connected to the web with free access from anyone with rudimentary search skills? Edited by Michael Lloyd

Share this post


Link to post
Share on other sites
On the outside chance that someone in your IT dept has the modem set up right (I set up my modems myself) to connect: RsLinx Communications --> Configure Drivers--> Ethernet Device Put the IP address of the PLC in the first box. Save Open up RSWho and let it browse until it finds the ML1100 and displays it in the tree. Shut down Linx. Open Logix 500. Browse. Find. Connect If port forwarding isn't set up you will not connect. You might see it but it won't connect. I doubt if it will even see it. Logix port - 44818 Edited by Michael Lloyd

Share this post


Link to post
Share on other sites
Let me expand on Michael's directions for configuring the RSLinx Classic driver. You must use the "Ethernet Devices" driver, not the "EtherNet/IP" driver. The EtherNet/IP driver relies on broadcast browsing and cannot communicate over even one gateway or router or the Internet. Instead of browsing internally then switching to external browsing, I append ":EIP" to the end of the IP address I place into the Ethernet Devices address table. This instructs RSLinx Classic to use only the TCP Port 44818 version of the driver (often called the EtherNet/IP or the CIP Ethernet driver). If you do not place ":EIP" in front of the IP address in the Ethernet Devices driver address table, the driver will first attempt to connect using TCP Port 2222, using the old A-B proprietary Ethernet protocol for the PLC-5E controllers. This will work with PLC-5E and SLC-5/05, but not with MicroLogix 1100 or 1400 or any ControlLogix family controller. All of this presumes that you have port forwarding and filtering set up correctly. I like to use a freeware utility called TCPING (www.elifulkerson.com) to verify that I have TCP connectivity before I attempt to set up RSLinx in a complicated network like this.

Share this post


Link to post
Share on other sites
Does adding :EIP speed up the connection process? I hadn't heard that one

Share this post


Link to post
Share on other sites
Adding the :EIP suffix causes RSLinx Classic to skip the attempt to connect via TCP Port 2222 and the old CSPv4 protocol, which it needs to connect to old PLC-5 and SLC-5/05 controllers. MicroLogix and ControlLogix do not support that protocol, even for browsing. The timeout for that connection is 1 second, and RSLinx retries 3 times, so it does cut about 3 seconds off the browse time. More importantly, it removes the repeated connection attempts to an unsupported port when the target is a MicroLogix or ControlLogix. Some VPN and intrusion-detection software considers multiple attempts to connect using an unsupported port number to be an intrusion, and then blocks the connection. I've been very deep into this with Cisco PIX firewalls.

Share this post


Link to post
Share on other sites
The modem setup is somebody else's domain, so I'll have to speak to them. I'm not really familiar with how that side of things works, but if I tell them they need to set up port forwarding to port 44818, will that be enough information for them to do what needs to be done? When I say "The IP address changes from time to time", I mean it uses DHCP to connect to the provider's wireless network. So the address it uses to connect to the internet might be 169.123.123.10, and every time it drops off and reconnects to the internet due to a power cycle or something, it will be assigned a new IP address. Then the physical ethernet port on the modem has a static IP address: 10.10.10.10. I would assume (although again I'm not completely up to speed with this) that the modem is acting as the gateway from the internet to the local 10.10.10.xxx network. Anyway, assuming I get port forwarding set up. If I set up an ethernet driver in RS Linx, assign it to my wifi, and add set an IP address 10.10.10.12:EIP, how will RS Linx know where to find 10.10.10.12? I would have thought that somewhere I'd have to tell it to go looking at 169.123.123.10 (or whatever) as the gateway? The modem is always connected to the internet; I believe it needs a password to log in to it. If this will pose further complications to the setup we can disable the need for a password temporarily; it's not a complex or sensitive system, it's just that it's in the middle of nowhere and it's a pain to have to drive 8 hours to make a program change. Edited by ASForrest

Share this post


Link to post
Share on other sites
Thanks a bunch. That makes perfect sense

Share this post


Link to post
Share on other sites
side note: I just downloaded TCPING but when I runt he application it very briefly opens a command prompt window then closes it again. Am I missing something?

Share this post


Link to post
Share on other sites
You point RSLinx at the modem IP and then with port forwarding enabled the modem FORWARDS to the PLC IP. If the modem IP changes from time to time how are you going to know what to connect to? I don't see how you are going to have a reliable connection if you don't use a static IP address for the modem. My modems are all on a 10. subnet and come with a 10. Static IP address. An example of what that looks like to me might be APN- blank.blank.com This tells our network that the modem is a static node (I think that is the correct terminology) I have a pack of SIM cards. They have different EIN numbers. I give an EIN to a gal in the office for activation. She does whatever and sends back the Modem IP address, cell number, and something else that I never use and can't remember right now Lets say my Modem IP is: 10.10.200.88 The PLC is set up on 192.168.192.20 The modem is set up to serve out IP addresses DHCP in a range of 192.168.192.10 thru .19. I do that because I want my laptop to be on the same network as the PLC if I am connected locally. It's not absolutely necessary but it's handy. Now we port forward in the modem Number of PF Entries 5 Public Port 1 start 44818 Public Port 1 End 44818 Host I/F 1 4 (2-Serial PPP 4-Ethernet 5-USB NDIS 6-WiFi) Host IP 1 192.168.192.20 Private Port 1 44818 Note that Entries = 5. That's because we also port forward Port 80 and Port 502 for a Modbus device (port server) as well as 2101 and 2102 for the HMI (Nematron). I can remote into anything I need to. The registers above repeat 4 more times with only the port number and corresponding device IP address changing In RSLinx I point to 10.10,200.88 (modem IP) and the modem "routes" the connection to the PLC (or HMI, etc) Edited by Michael Lloyd

Share this post


Link to post
Share on other sites
Thanks, that's starting to make more sense. I'll have a chat to the IT guy and see if he understands it :) We don't need a constant connection. The application is a chemical dosing system. Every month, the chemical supply company dials in, checks tank leves, chemical usage etc, and send out a truck to resupply the customer when required. Occasionally we need to update the PLC program as well. So we're not needing to be online all the time and consistently, just from time to time long enough to read some values and maybe download a new version of the PLC program. We use a tracert command to find the IP address when we need to log in to the system. Up until recently, the customer has been using some horrible Eaton PLC to do the job, and tunnelling in via the HMI over a virtual serial port to do updates.

Share this post


Link to post
Share on other sites
Side note reply: TCPing is command-line only; if you run it by clicking on the program in Windows Explorer, you'll see the error message you get by not giving it any parameters flicker by in a CMD window. Open a CMD window, navigate to the folder where TCPing is located, and run it with the command line syntax described by Fulkerson. It's something to the effect of "TCPing 192.168.1.10 44818"

Share this post


Link to post
Share on other sites
ah, that makes sense. Thanks Ken. I've given that info to the IT guy and he seemed to follow. He's set up port forwarding so the modem forwards any traffic received on port 44818 to 10.10.10.12 (the PLC). However, running the TCPing on that port, I get "Socket is not connectd (10057)". I get a reply if I ping on port 80, but nothing on 44818. Any idea what that this could mean? Edit: I've tried TCPing'ing port 789, which is the port set up for remote access to the HMI, and I get a response from that port as well. Still nothing from 44818. The IT guy says he's set the ports up exactly the same way (changing the forwarding IP address and incoming port number, of course). Is port 44818 definitely the right port for a micrologix 1100? I found reference to it in the 1400 manual, but can't find anything about port numbers in the 1100 manual. Edited by ASForrest

Share this post


Link to post
Share on other sites
Winner. Someone had changed the gateway address setting the in PLC on site. Changed it back and everything is talking fine. Thanks a heap for the expertise, its been invaluable

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0