ok, I have been reading all day and watching videos on automation directs site on the basics of PLC's and how to program them. The basics. I have been reading, rereading, and rereading Cbyrdtopper forums post
https://www.machsupport.com/forum/index.php?topic=34228.30 helping another member get his turret setup. While it has helped me a lot, his turret is a little more simple than what mine seems to be. Hopefully not.
I have the ESS and the Switch PLC both connected. I followed Cbyrdtopper instructions on setting up modbus and the required inputs, outputs, and registers in mach4. All that is done.
Im still stuck on this ladder logic. It seems so simple yet I am struggling with it. I have everything wired on the bench so I can test as I go. If someone could post a pic of their PLC turret program even remotely similar. Just for me to compare to would be helpful. The starting point and determining that its changing to the correct tool is my first issue.
I have DS1 setup as a register, mach will send the tool number over for the plc to change to tool 1 thru 8 by comparing DS1 = 1 thru 8. Do I assign my tool info to a DS1 variable? The only way to know the position of the turret is by the BIT signals.
So inputs 1-3 on the PLC are bit signals from the turret, So tool one would be on-off-off or 1-0-0. The PLC will see those 3 signals followed by a Strobe signal which needs to trigger a solenoid. Im confused as to how to write this all out in ladder logic or any other code for that matter. From what I've read I can write the repetitive stuff out in a subprogram and call it after the tool is assigned.