How to call a Sub-Program in Crimson 3.2

Marco_W

Member
Join Date
Jan 2021
Location
Perth
Posts
4
I can't find any information in the Red Lion Crimson documentation about how to use Sub-Programs.

I have a number of ladder logic main programs in a DA70 controller, and I need one of them to call a Sub-Program only when a particular boolean tag is True.
(The Sub-Program logic controls a tag that is an On/Off control for one of the networked Modbus TCP devices, and there are times that I don't want my control logic executing any new states for that tag, so I thought that a SubProgram would be the ideal way to handle this scenario)

Thanks in advance.
 
Go to the Tag that you want to call the subroutine, then to the Triggers tab, select the trigger mode that you want to happen, then to the Action, leave it as General, then from the right side of the screen choose Programs and drag the program in to the field next to General.
 
Thanks for the reply, BryanG.
I probably should have given more info in my original post, and also mentioned that I have done plenty of PLC programming in the past but this is my first time working with a Red Lion.

It seems like the method you suggest is for general Data Tags and "Programs".
However I'm not using Programs, I'm trying to do it from within my ladder logic programs in the "Control" section.
The Project Variables in the Control section do not have those other tabs of attributes such as Triggers.

...
And actually I think I just found the answer.
After looking through the Crimson Function Blocks manual again and finding nothing, I then pasted a new function block into my logic and started scrolling through the list of blocks ... and among them is one with the same name as my Sub-Program.
 

Similar Topics

trying to locate the button object on screen that calls a Sub from VBA code. inherited a FT app to learn-several buttons using Click events in...
Replies
2
Views
1,930
I've gotten to the learning curve where I can program a call for pump to come on at set point but I'm not sure how to turn the same pump off when...
Replies
1
Views
105
Hi Siemens Experts, I am hoping someone can shed some light on my issue. I have uploaded the code from a S7-300 (317-2PN/DP) using Step 7...
Replies
9
Views
642
I created this FC and it compiles, but when I use it in my MAIN OB1, it appears to have two outputs. See pictures. What am I doing wrong here...
Replies
9
Views
1,453
Is there a way in CX-Programmer to call Ladder Instructions from a structured text program? I can see several functions in the autocomplete...
Replies
3
Views
1,896
Back
Top Bottom