dmroeder
Lifetime Supporting Member
I posted up some Python code on Github that will allow you to exchange data with CompactLogix and ControlLogix PLC's. It should run on anything that Python runs on.
Some time ago, forum member here Burt (NevisGroup) had written some code in Python for someone to pull/display some information from a Logix based PLC. He offered to share it with the forum and I took him up on the offer. At the time it worked really well but was very specific to the task that it was being used for. Over the last year or so I've been tinkering with it when I had spare time to add functionality to it. To deal with complex tag names, arrays, all the base data types, etc.
Without Burt's code to begin with, I probably would have never even made the attempt to mess with this stuff. Archie helped me quite a bit too so thanks to him for putting up with me. Having AdvancedHMI available was a huge help when things weren't working, I could see what was going on in WireShark to debug. I'm by no means an expert in any of this, just tinkering for fun. There's probably some stuff that professional coders would cringe at so keep my amateur-ness in mind. But it has been working well for me so I thought I'd share, maybe someone will find it useful.
It's still a work in progress, I'll still be hacking away at it as time allows.
https://github.com/dmroeder/pylogix
Some time ago, forum member here Burt (NevisGroup) had written some code in Python for someone to pull/display some information from a Logix based PLC. He offered to share it with the forum and I took him up on the offer. At the time it worked really well but was very specific to the task that it was being used for. Over the last year or so I've been tinkering with it when I had spare time to add functionality to it. To deal with complex tag names, arrays, all the base data types, etc.
Without Burt's code to begin with, I probably would have never even made the attempt to mess with this stuff. Archie helped me quite a bit too so thanks to him for putting up with me. Having AdvancedHMI available was a huge help when things weren't working, I could see what was going on in WireShark to debug. I'm by no means an expert in any of this, just tinkering for fun. There's probably some stuff that professional coders would cringe at so keep my amateur-ness in mind. But it has been working well for me so I thought I'd share, maybe someone will find it useful.
It's still a work in progress, I'll still be hacking away at it as time allows.
https://github.com/dmroeder/pylogix