I was looking at the possibility of creating nested data types in CoDeSys 2.3 (as in Simatic). Is this possible? Something like the below:
TYPE Test :
STRUCT
Real1: REAL; Real2: REAL; RealSet: STRUCT Real3; REAL; Real4: REAL; END_STRUCT;
END_STRUCT
END_TYPE
Hi,
you can do this, but first you have to declare the "inner" type separately.
TYPE TRealSet: STRUCT Real3; REAL; Real4: REAL; END_STRUCT END_TYPE
This you can use now as follows:
TYPE Test : STRUCT Real1: REAL; Real2: REAL; RealSet: TRealSet; END_STRUCT END_TYPE
Log in to post a comment.
I was looking at the possibility of creating nested data types in CoDeSys 2.3 (as in Simatic). Is this possible? Something like the below:
TYPE Test :
STRUCT
END_STRUCT
END_TYPE
Hi,
you can do this, but first you have to declare the "inner" type separately.
This you can use now as follows: