thiagoralves / OpenPLC_Editor

OpenPLC Editor - IDE capable of creating programs for the OpenPLC Runtime
GNU General Public License v2.0
385 stars 191 forks source link

ST creation problem #108

Open fehimiltek opened 3 months ago

fehimiltek commented 3 months ago

hello I just realised that when i connect my output to a parameter on st file its appears to top of program let me show

ladder st

I think "Q1MODE := CNC_Mode0.Mode_Num;" line should be at the end

regards

thiagoralves commented 3 months ago

It is hard to make sense of these screenshots. They are cropped, only small portions of the code and diagram are shown.

fehimiltek commented 3 months ago

let me explain with another clear example ladder st

i think it should be like

`PROGRAM program0 VAR adding0 : adding; LocalVar0 : BOOL; LocalVar1 : BOOL; END_VAR VAR LocalVar2 AT %MB1000 : BYTE; END_VAR

LocalVar1 := LocalVar0; adding0(EN := LocalVar1, LocalVar0 := 10, LocalVar1 := 10); IF adding0.ENO THEN LocalVar2 := adding0.LocalVar2; END_IF; END_PROGRAM`

regards