Siemens SCL Program flow

qwemx

Member
Join Date
Jul 2017
Location
Earth
Posts
195
in the scl code written in screenshot
Line 1 condition is false
but still the program checking the line 2 condition and says it is true

i had this understanding that if the condition is not true then the program will skip line 2

Screenshot_8.png Screenshot_4.png
 
Last edited:
I presume the status values are from the previous cycle where the first if-condition was true and so the second was processed.

To indicate this, the status values are grey instead of black.
 
Also you can write:

If MyBool1 and NOT MyBool2 etc

Makes it easier to follow for boolean evaluation, you dont need the '=1'
 
I presume the status values are from the previous cycle where the first if-condition was true and so the second was processed.

To indicate this, the status values are grey instead of black.

Yes i think that is correct , if it was true in black then the montime will be updated to 25000 but it is not updated
but this is confusing the condition is not true at the moment then instead of showing true in grey should be showing false in black
 

Similar Topics

Hello, When you want compare values of an array to a range of numbers is it a right way to do that? FUNCTION ADD VAR_IN_OUT A:ARRAY[1..50]...
Replies
5
Views
2,067
Hi All, I need to try and convert some code from Siemens SCL (TIA16) over to Allen Bradley RS5000. I have attached an image of the SCL and what...
Replies
10
Views
4,051
I am new to PLC programming. Is there a standard way to incorporate alarms / warnings / events such as the exceptions in C++ or Java where you can...
Replies
5
Views
1,963
Hello All, I am new to programming with Tia Portal and I am having difficulty with something that we have found "easy" in other programming...
Replies
3
Views
2,376
Could someone help me to convert following from STL to SCL? AN #PV_EXT_S JC MEAS L #PV_EXT L 1.000000e+000...
Replies
9
Views
2,708
Back
Top Bottom