rdrast
Lifetime Supporting Member
/sigh.
The first question that should be asked, is, are you using a 'Classic' AB PLC (PLC-5, SLC-500, MicroLogix) or a Logix Platform PLC (Control/Compact/FlexLogix).
If you are using a classic processor, then you should create independent subroutines, each with a unique timer.
If you are using a Logix processor, you can pass a unique timer value as an input parameter to the subroutine call.
As with general computer programming, manipulating things beyond the scope of the DOCUMENTED underlying rules is a bad bad bad idea. A 'Kludge' that may work today on a particular firmware revision or CPU, may very well fail on another revision. Case in point: If software developers actually wrote software to Microsoft's published Window's NT (Or, in almost all cases, Windows 3.1) API, all of those programs would function perfectly in every later version, even Vista. Programs that fail under Win 2k, or Win XP, or Win 2k3, or Win Vista, fail because developers take undocumented shortcuts.
The first question that should be asked, is, are you using a 'Classic' AB PLC (PLC-5, SLC-500, MicroLogix) or a Logix Platform PLC (Control/Compact/FlexLogix).
If you are using a classic processor, then you should create independent subroutines, each with a unique timer.
If you are using a Logix processor, you can pass a unique timer value as an input parameter to the subroutine call.
As with general computer programming, manipulating things beyond the scope of the DOCUMENTED underlying rules is a bad bad bad idea. A 'Kludge' that may work today on a particular firmware revision or CPU, may very well fail on another revision. Case in point: If software developers actually wrote software to Microsoft's published Window's NT (Or, in almost all cases, Windows 3.1) API, all of those programs would function perfectly in every later version, even Vista. Programs that fail under Win 2k, or Win XP, or Win 2k3, or Win Vista, fail because developers take undocumented shortcuts.