Originally created by: AndreQ77
Hello everybody. I'm converting a Codesys V3 project in structured text to another project in V2.3 (due hardware old not compatible with V3).
Usually, in the declaration of the variables, I initialize the desidered value:
VAR_GLOBAL CONSTANT baseTick : BYTE := 20;
cmdDelay : UINT := 700 / baseTick; shortCmdDelay : UINT := 100 / baseTick; alrOnDelay : UINT := 2 * (1000 / basetick); alrOffDelay : UINT := 500 / baseTick; END_VAR
In Codesys V3... no problem, it works! In Codesys V2.3 I can't use a mathematical operation!
Works only: cmdDelay : UINT := 35; or cmdDelay : UINT := baseTick;
I tryed : cmdDelay : UINT := 700 / baseTick; cmdDelay : UINT := (700 / baseTick); but always with build errors.
Have you some ideas?
Thank you! Andrea
Log in to post a comment.
Originally created by: AndreQ77
Hello everybody.
I'm converting a Codesys V3 project in structured text to another project in V2.3 (due hardware old not compatible with V3).
Usually, in the declaration of the variables, I initialize the desidered value:
VAR_GLOBAL CONSTANT
baseTick : BYTE := 20;
cmdDelay : UINT := 700 / baseTick;
shortCmdDelay : UINT := 100 / baseTick;
alrOnDelay : UINT := 2 * (1000 / basetick);
alrOffDelay : UINT := 500 / baseTick;
END_VAR
In Codesys V3... no problem, it works!
In Codesys V2.3 I can't use a mathematical operation!
Works only:
cmdDelay : UINT := 35;
or
cmdDelay : UINT := baseTick;
I tryed :
cmdDelay : UINT := 700 / baseTick;
cmdDelay : UINT := (700 / baseTick);
but always with build errors.
Have you some ideas?
Thank you!
Andrea