Code Monkey home page Code Monkey logo

Comments (17)

dmroeder avatar dmroeder commented on July 18, 2024 1

See this:
#221

from pylogix.

sagar-gulve avatar sagar-gulve commented on July 18, 2024 1

@dmroeder : Steps mentioned on issue#221 resolved it. Thanks..!!

from pylogix.

dmroeder avatar dmroeder commented on July 18, 2024

This will not work with Emulate since Emulate does not support Ethernet I/P communications. However SoftLogix does if you have access to it.

When you say that you are unable to discover devices, are you basing that on trying to discover Emulate? As I mentioned, it does not support Ethernet I/P. I have no problems discovering devices.

EDIT: Pylogix does work with emulate if you set ConnectionSize = 504

from pylogix.

raincls avatar raincls commented on July 18, 2024

I was indeed trying to discover Emulate.
Thank you very much for your careful explanation. I will try SoftLogix.

from pylogix.

dmroeder avatar dmroeder commented on July 18, 2024

Sure no problem. Keep in mind, with SoftLogix, you will have to specify the processor slot since RSLinx goes in slot 0 (for some dumb reason).

from pylogix.

TheFern2 avatar TheFern2 commented on July 18, 2024

Were you able to get it working with SoftLogix? I am able to discover the SoftLogix Ethernet module but returns 0.0.0.0 for the IP even though is set for 192.168.0.27
Anything special I should be looking for? I have slot 2 for the cpu.

from pylogix.

dmroeder avatar dmroeder commented on July 18, 2024

I would expect that you would use the IP address 192.168.0.27, then set .ProcessorSlot = 2 and it should work. We don't have a license for SoftLogix anymore so I cannot install and test this.

If it does not work and you can capture some wireshark packets of it, you can email them directly to me. I'd also like to see the packets when you discover and get the IP address 0.0.0.0. I suspect this is a problem with SoftLogix, but it would be nice to confirm.

from pylogix.

TheFern2 avatar TheFern2 commented on July 18, 2024

Strange, it works now. Don't know what exactly fixed it. I read on SoftLogix manual about disabling UDP packets in Rslinx, so I did that. Reboot and ran discover function, and it found SoftLogix this time with the correct IP. I ran getTagList and also pulled all tags. I went back and enable UDP again, reboot and tested again with no issues. Looks like I am good to go. Yeah definitely something got hung, either a service or a process.

from pylogix.

dmroeder avatar dmroeder commented on July 18, 2024

Classic Rockwell. Thanks for the update.

from pylogix.

dmroeder avatar dmroeder commented on July 18, 2024

While I know this is old, and not likely to reach anyone, I cannot let misinformation go. I found out recently that you can use pylogix with Emulate. A user confirmed that with 0.7.14, set ConnectionSize to 504 and the IP address will be your computer.

from pylogix.

TheFern2 avatar TheFern2 commented on July 18, 2024

@dmroeder I couldn't get a read with Studio 5000 Emulate V32, maybe it was successful with the old RS Emulate.
Do you have a version where it was known to work? I tried all local IPs, and also different slots, on the Emulator the CPU appears to be on slot 2.

= RESTART: C:\Users\Default.DESKTOP-GU2MB4F\Downloads\pylogix-master (2)\examples\01_read_simple.py
Traceback (most recent call last):
  File "C:\Users\Default.DESKTOP-GU2MB4F\Downloads\pylogix-master (2)\examples\01_read_simple.py", line 21, in <module>
    ret = comm.Read('BaseBOOL')
  File "C:\Users\Default.DESKTOP-GU2MB4F\AppData\Roaming\Python\Python39\site-packages\pylogix-0.7.15-py3.9.egg\pylogix\eip.py", line 107, in Read
    return self._readTag(tag, count, datatype)
  File "C:\Users\Default.DESKTOP-GU2MB4F\AppData\Roaming\Python\Python39\site-packages\pylogix-0.7.15-py3.9.egg\pylogix\eip.py", line 252, in _readTag
    resp = self._initial_read(tag, base_tag, data_type)
  File "C:\Users\Default.DESKTOP-GU2MB4F\AppData\Roaming\Python\Python39\site-packages\pylogix-0.7.15-py3.9.egg\pylogix\eip.py", line 1366, in _initial_read
    status, ret_data = self.conn.send(request)
  File "C:\Users\Default.DESKTOP-GU2MB4F\AppData\Roaming\Python\Python39\site-packages\pylogix-0.7.15-py3.9.egg\pylogix\lgx_comm.py", line 65, in send
    return self._getBytes(eip_header, connected)
  File "C:\Users\Default.DESKTOP-GU2MB4F\AppData\Roaming\Python\Python39\site-packages\pylogix-0.7.15-py3.9.egg\pylogix\lgx_comm.py", line 150, in _getBytes
    raise BufferError("ethernet/ip _getBytes output size exceeded: %d bytes" % len(data))
BufferError: ethernet/ip _getBytes output size exceeded: 64 bytes

from pylogix.

dmroeder avatar dmroeder commented on July 18, 2024

Hmm, I believe the version was 0.7.14, all they did was set ConnectionSize=504. Apparently using loopback address worked and "the address that shows up in RSLinx", which I assume was the computers address. The user called the software package "Emulate 5000" which leaves an opening to be ether the old or new.

I don't think that software is part of our toolkit, so I can't really test myself. Can you wireshark it?

from pylogix.

TheFern2 avatar TheFern2 commented on July 18, 2024

It works after locally changing connection to 504, I found the bug the ConnectionSize is now set to 50 in lgx_comm.py must have accidentally deleted the 4. Both loopback and computer ip worked. Nice!

image

image

from pylogix.

dmroeder avatar dmroeder commented on July 18, 2024

I am an idiot. looks like my 2nd commit, I accidentally changed the fall back connection size. I gotta be more careful than that. I was in a hurry, I usually check diff before committing.

from pylogix.

TheFern2 avatar TheFern2 commented on July 18, 2024

I am an idiot. looks like my 2nd commit, I accidentally changed the fall back connection size. I gotta be more careful than that. I was in a hurry, I usually check diff before committing.

no worries I am gettng fixed, and adding some notes to the docs as well. It only appears to work locally.

from pylogix.

dmroeder avatar dmroeder commented on July 18, 2024

I am an idiot. looks like my 2nd commit, I accidentally changed the fall back connection size. I gotta be more careful than that. I was in a hurry, I usually check diff before committing.

no worries I am gettng fixed, and adding some notes to the docs as well. It only appears to work locally.

Yeah I had heard that it only works on the machine that is actually running emulate.

from pylogix.

sagar-gulve avatar sagar-gulve commented on July 18, 2024

While trying this I am getting strange error Unknown error [WinError 10061] No connection could be made because the target machine actively refused it

Any suggestion on this?

from pylogix.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.