HalfManHalfBiscuit
Member
Somewhat new to Schneider (aka Modicon) PLC's and the Unity Pro XL programming software. I have a TSX P57 6634M PLC. I would like to take an existing solution created for a Rockwell StudioLogix application and translate it without having to do too much total rewrite.
I've hit a roadblock however and hoping to find a reasonable solution. I am using arrays that are using data type Structure which are made up of a mix of DINTs and other structures. What I would like to do is to be able to query the Length of the array similar to how the SIZE command in Rockwell returns a value for the array length. The SIZE command can handle arrays of UDT's as well as the elementary data types such as INT, DINT, etc. I found the LENGTH array instruction in the Unity Pro library but it looks like it is only capable of working on elementary data types. Does anyone know of a work-around or if there is a different approach to achieve the same result?
I've hit a roadblock however and hoping to find a reasonable solution. I am using arrays that are using data type Structure which are made up of a mix of DINTs and other structures. What I would like to do is to be able to query the Length of the array similar to how the SIZE command in Rockwell returns a value for the array length. The SIZE command can handle arrays of UDT's as well as the elementary data types such as INT, DINT, etc. I found the LENGTH array instruction in the Unity Pro library but it looks like it is only capable of working on elementary data types. Does anyone know of a work-around or if there is a different approach to achieve the same result?