Adnan Muazzam

PLC5 Subroutine Access

3 posts in this topic

Goodday everyone, I am relatively new to PLC5 so need some help I know in Control logix we access subroutines using JSR instruction in main routine but I am not sure in case of PLC5 I have written some instructions in LAD13 of PLC5 but coils dont update based on XIC input. LAD13 is currently empty. My rung is quite simple like this -| |----------------------------( )-- I checked LAD2 but there is no such thing as JSR for any routines. Program in LAD14 are running and if I write same rung in LAD14 it works Can anyone help. Looks like a stupid mistake to me though :)

Share this post


Link to post
Share on other sites
I'm not sure that I understand exactly what you're asking but here is some basic information that might help ... MOST of the PLC-5 processors have an MCP tab (Main Control Program) in their Status File ... check that and see which of your Ladder Files are listed there ... usually only Ladder File number 2 is listed there by default and that is why Ladder File 2 gets executed ... then from Ladder File 2, we usually use a JSR instruction to jump to other Ladder Files to make the processor scan/execute them also ... but ... we could also add OTHER Ladder Files to the MCP list which would cause those files to be scanned/executed even without having JSR instructions to "jump" to them ... or ... the PLC-5 processors have an STI tab (Selectable Timed Interrupt) in their Status File ... check that and see if one of your Ladder Files is listed there ... if it is, that's another way that a file other than Ladder File number 2 could be executed ... I hope that this helps ... if not, consider posting your entire RSP program file ...

Share this post


Link to post
Share on other sites

Thanks Guess. I confirm MCP (Main Control Program) is the solution if there are no JSR commands. In order to get to MCP double click on S2 and then go in the MCP Tab. Most of the time it will be Ladder 2 selected and then JSR will be done in Ladder 2 to call the other subroutine but you can put all Ladder Subroutines number in MCP.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now