Hello Can anyone see any problems with constant assignment as in the following statement: Coils[0] := Coils[0] OR (Buttons[0] AND Sensors[0] > 6); Rather than using the more verbose and vertically-larger: IF NOT Coils[0] AND Buttons[0] AND (Sensors[0] > 6) THEN Coils[0] := TRUE; END_IF Also, is the test expression short-circuited in the latter case? In other words, will the runtime move on after it sees Coils[0] = FALSE AND? Thanks
Hello, I'd like to write some parameters to axes from inside a function block where I passed axis by reference, using ETC_CO_SdoWrite. Is it possible to get the device address from inside the function block? Please see example below. Thank you!
Wow! Thanks mr Strucc. Changed to service to run as local acc, and now log works! The service (run from local acc) is using this config: C:\Users\SRV\AppData\Roaming\CODESYS\CODESYSControlWinV3\C4DBB537\CODESYSControl.cfg The path you first mentioned (c:\Windows\System32\config\systemprofile\AppData\Roaming) has no CODESYS folder in it (Windows 11 24H2 b26100.3194). Thanks for your help :)
Use a VAR_INPUT for properties. The reason for the error is that you can't get a reference to a property. Using a VAR_INPUT will copy the property to an input variable.
This came up again today, so I'll post the fix for future reference. Happens with Schneider Machine Expert 2.2 and M262 controllers. Add this bit of code to a program called from the visu task //disable "VisuFbFrameBase.SetInputPositionData" log messages, which fill up the logs IF VisuElems.Private_Visu_Globals.g_ValueChangedListenerManager.GetListenerCount() > 0 THEN VisuElems.Private_Visu_Globals.g_ValueChangedListenerManager.RemoveValueChangedListener(VisuElems.Private_Visu_Globals.g_ValueChangedListenerManager.listenerForOnValueChanged);...