Subscribe: mmini.me/Subscribe-4-Updates Other socials: Facebook: facebook.com/OnlinePLCSupport LinkedIn: www.linkedin.com/in/shane-welcher-sr/
@darthenx25853 жыл бұрын
Great information. Possibly expand a bit more on how to for example read a int or dint , create a simple calculation and then out put the value to another device like a server or another plc
@ShaneWelcher3 жыл бұрын
10-4, I will make a few more videos using Pylogix
@dustin94803 жыл бұрын
Nice video Shane! I appreciate you showing pylogix. I've always wanted to make videos but I feel weird listening to myself :)
@ShaneWelcher3 жыл бұрын
That is something I had to get used to as well, just give it a go & adjust as needed. You got this!
@johntgilmore1Ай бұрын
Dustin, on git hub you have helped me so, so, so freaking much may I share with you what I have done
@chuystark3 жыл бұрын
Hello, i've been trying to connect to a logix5561 but i get unknown error errno [111] connection refused, do you have any idea of what could be happening?
@ShaneWelcher3 жыл бұрын
What communication protocol are you using?
@dustin94803 жыл бұрын
That error comes from pythons socket module, not the PLC. So you are not connecting to the PLC. Make sure you can successfully ping the ethernet module in your ControlLogix rack first. If your L61 is not in slot 0, then make sure you specify which slot it is in.
@chuystark3 жыл бұрын
Yes, i could successfully ping it, the ip was in the same segment, the weird thing is that with pycomm3 i dindn’t have any problems but with pylogix i wasn’t able to read the tags
@ShaneWelcher3 жыл бұрын
@@chuystark Probably missing an updated version of pylogix. Or the import of the needed files.
@kavinyudhitia2 жыл бұрын
WOW! Very educative!!! thanks!! Subscribed!
@notme2218 күн бұрын
Thank you! Do you know if this can read tag values fast enough for motion axis? I’m looking for an easy way to sample a 10000 count encoder every 100 counts over 0.75 seconds and this seems to bypass having to learn/pay for the ODVA standards needed for IO Messaging.
@ShaneWelcher17 күн бұрын
Depends on the timing used
@vivekpatil79679 ай бұрын
How to set PLC slot if a PLC controller is fitted in Chassis?
@ShaneWelcher9 ай бұрын
Look on GitHub
@daviddemjan19162 жыл бұрын
Hi! I would like to ask for some help. I was able to gather the informatiom from PLC control tag (RSLOGIX 5000) but not able to work with it. So if I want to handle that information in forexample in an If statement I won't be able to work with it. import time from PIL import Image from pycomm3 import LogixDriver from tkinter import * with LogixDriver('here my IP adress I removed it') as plc: valami = plc.read('valami') print(valami) if valami: print("works") else: print("Doesn't work") It always says its true even if i toggle the bit to False. It will never go to else branch. Thanks for help.
@ShaneWelcher2 жыл бұрын
Sounds like you do not have an active tag or your update time is incorrect, not sure what you are using for python programming I use VS code which is a manual trigger the code that reads the tags so it requires me to trigger the python code to get refreshed data
@daviddemjan19162 жыл бұрын
@@ShaneWelcher I do have an active tag, could you please share your mail I'll send you the picture what I have on pycharm.
@ShaneWelcher2 жыл бұрын
I would recommend you reach out to the GitHub, I did not design Pycomm
@cmrncrick Жыл бұрын
Whenever you toggle the bit are you restarting the script? If not then I don't think your value will be automatically updated because the python script isn't looping in that code. I have written a class object that looks for the leading transition of a bit constantly so as to circumvent this issue and it works well.
@vigneshsankar88622 жыл бұрын
Hi, Shane in my application I need to monitor the tag of about 5000 of data length 4byte is that possible using those libraries
@ShaneWelcher2 жыл бұрын
Yes however, it may take a bit to collect all the data because of the way Python works. If you need a faster alternative then I would use JavaScript although it's a bit harder to implement
@DuneKraftwerk Жыл бұрын
@ShaneWelcher what is the node js alternative you refer to ?
@vishayinternet3 жыл бұрын
is it possible to change controller mode from Python e.g. Run mode to Programm mode?
@ShaneWelcher3 жыл бұрын
Not from my knowledge, that is a safety risk in my opinion
@kennythien2049 Жыл бұрын
Hi Shane, are you able to do a video on Modbus TCP/IP using python?
@ShaneWelcher Жыл бұрын
I do not have a modbus converter to use although yes you can read data from the IP address. Also depends on the modbus converter
@lekanraji98993 жыл бұрын
Which file do we need to download from github to do the same thing?
@ShaneWelcher3 жыл бұрын
If you have python & an internet connection then open your CMD then run the pip install as shown of the pycomm3 GitHub page
@Slap_it_in2 жыл бұрын
Why do my imported libraries never show up as purple?
@ShaneWelcher2 жыл бұрын
Probably your setup, I use the full version
@Slap_it_in2 жыл бұрын
@@ShaneWelcher It was the intellisense, also i believe there is a known issue with VS were it wasn't working. I moved to VSC and got familier with using that instead.
@ShaneWelcher2 жыл бұрын
@@Slap_it_in Thanks for the reply
@shraddhajadye80572 жыл бұрын
Can we transfer the reading value of plc into excel file?
@ShaneWelcher2 жыл бұрын
With extra code yes, I think you would have to add on the python script & make a small gui
@shraddhajadye80572 жыл бұрын
@@ShaneWelcher Thnank u....Above program is working for delta plc?
@ShaneWelcher2 жыл бұрын
@@shraddhajadye8057 Rockwell Automation
@abdulazizallahdan65463 жыл бұрын
is there a way to connect to studio 5000 emulate?
@ShaneWelcher3 жыл бұрын
I believe if you visit the GitHub, there is another source code for that. I haven't tried that one yet
@abdulazizallahdan65463 жыл бұрын
@@ShaneWelcher Will check it out! Thank you for reply!
@fox9starshow Жыл бұрын
thanks for your Idea.
@renanamorim752510 ай бұрын
Thanks for the video! Is the PLC working as a Scanner or Adapter here?
@ShaneWelcher10 ай бұрын
I just attached a plc processor to the computer then ran Pycomm3
@khachuytran35522 жыл бұрын
Thanks you a lot, sir!
@ShaneWelcher2 жыл бұрын
Glad to help
@DuneKraftwerk3 жыл бұрын
I guess it cannot be used with RSLogix Emulate 5000 because the emulator cannot be accessed via an IP address.
@ShaneWelcher3 жыл бұрын
You can use a Python script to read Emulator, however, it is a different code than this. Use the GitHub links in the video notes about how to do this.
@dustin94803 жыл бұрын
pylogix can read tags on emulate, I found out that emulate expects a specific connection size, because Rockwell. so if you add a line comm.ConnectionSize=504, it should connect to emulate as long as you are running your script on the same machine that emulate is running on. Edit: You would use your machines IP address to connect. edit2: I made a commit a while back that should automatically try the correct connection size for emulate if it doesn't connect the first time.
@rezamagham44952 жыл бұрын
Thank you very much indeed
@ShaneWelcher2 жыл бұрын
You are very welcome
@timkloehn98873 жыл бұрын
I do not know python. I know c++, c# , and visual basic. Is it similar? I always wanted to try ingear software to work with allen bradley software because I know these languages. I bought a book on python, but I always read my C books because I work with robotics. C# is my favorite by far. Garbage collection is automatic, no memory leak.
@ShaneWelcher2 жыл бұрын
Great to hear
@timkloehn98872 жыл бұрын
@@ShaneWelcher I don't know if you did a video on how to implement the encoder card on the powerflex 525. I have the board, just haven't used it yet.
@ShaneWelcher2 жыл бұрын
@@timkloehn9887 I have an encoder card in my PF525, I'll try to make a video in the future. Been busy with moving & taking care of my mother.
@timkloehn98872 жыл бұрын
@@ShaneWelcher You were right about rs5000 version 20 being buggy and a piece of crap software version. I stand corrected. thankyou.
@gbengaoyede28772 жыл бұрын
Does it work with all types of plc or it's for a particular plc brand
@ShaneWelcher2 жыл бұрын
The GitHub code I am using in this video is for Rockwell Automation. There are separate GitHub codes for other PLC brands
@gbengaoyede28772 жыл бұрын
@@ShaneWelcher isn't there any one that can be used generally? I am thinking of extracting real time csv data from plc since all plc(s) can do this, and reading it on python, i am actually making research on this and i could use your professionalism on this. Kindly share your me your email sir.
@ShaneWelcher2 жыл бұрын
@@gbengaoyede2877 Visit the GitHub site for the information, it gets updated from time to time
@MdMozammelHossain2 жыл бұрын
Hi, thanks for the video, I'm currently trying to use pycomm3 for real project, but what. Getting that very slow read cycle, it's taking around 0.9 sec to 1.3 sec just to for a read cycle. Which is very long in my application as hmi momentary switch only high for 0.5 sec, so it not catching singnal from hmi's push buttons. Is there any way to improve ? I have to read around 22 nos of integer register.
@ShaneWelcher2 жыл бұрын
Please refer to the GitHub page for Pycomm3 It most likely could be your computer
@MdMozammelHossain2 жыл бұрын
@@ShaneWelcher not sure if it's my computer, as I tried 3 computer, all of them have similar time, and also I tried ModbusTCP which has significantly less time, but because of some limitation of Modbus protocall, can't use it.
@ShaneWelcher2 жыл бұрын
@@MdMozammelHossain Reach out to the creator of Pycomm3
@DuneKraftwerk Жыл бұрын
Indeed, polling data blindly is not the way, need to detect changes in values instead. I did change detection in c# but it must be a way to implement it on python or node js
@Tescor_JC2 жыл бұрын
Is it possible to write PLC outputs?
@ShaneWelcher2 жыл бұрын
Yes, just follow the GitHub directions. You are able to read or write
@johntgilmore1Ай бұрын
I really enjoy your page, is there a ways I can share with you one I have created
@ShaneWelcherАй бұрын
Do not use my page to promote yourself
@DuneKraftwerk3 жыл бұрын
Interesting. No OPC or MQTT involved.
@ShaneWelcher3 жыл бұрын
Correct
@edinetgrunhed60003 жыл бұрын
Nice video,are you using visual studio for python?
@ShaneWelcher3 жыл бұрын
I do use Visual Studio but in this video I used a separate VM which was Linux. I prefer Visual Studio 2019
@edinetgrunhed60003 жыл бұрын
@@ShaneWelcher in Visual studio what i remember there is toolbox like textbox or button, means you can use this for python reading display?
@ShaneWelcher3 жыл бұрын
@@edinetgrunhed6000 yes, just import the tools needed to read data from the PLC . Pycomm is one tool then there is another tool I will show in the future. Using Visual Studio 2019 then install the needed things from GitHub & then when writing scripts, just import that tool first. If you did not have an internet connection for the install then there are ways to manually install as well but is a slight bit harder. The end result is the same. Using python to read data from a plc. Pycomm or Pylogix
@edinetgrunhed60003 жыл бұрын
@@ShaneWelcher ok,I prefer pylogix looks more stable
@ShaneWelcher3 жыл бұрын
@@edinetgrunhed6000 Yes, more options
@boodeepak2 жыл бұрын
Nice Video, How to store the data from an AB PLC into SQL server using Pycomm3
@ShaneWelcher2 жыл бұрын
Seems like a very detailed topic that most people won't watch because of how long the video is. Your comment is very detailed to explain