BabyLover
MrPLC Member-
Content count
5 -
Joined
-
Last visited
Posts posted by BabyLover
-
-
Hello Mr Walsh,
I played a little bit with data types. I created data type that consists array of boolean[64]. Then I created arrays of the data type[60] that I use in my FB. In the FB the data types are defined as IN OUT variables. I'm getting error about indexing of the arrays. Here are some pictures:
Can you see what am I doing wrong here?
-
Hello ,
Thank you for the answer. This sure works. The problem is that I want this to be a function block and in the FB I can't make input to be an array and give addresses. Is it possible somehow to convert the input word to array of boolean inside the FB ?
-
Hello,
I'm new to CX-Programming and I could really use your help.
I want to make function block that will check the bit status from a word input variable. I made input variable and internal variable array of bool(32) and I thought I can just use the code example:
array[1]:=word.1 etc... but it is not allowed in CX-programmer.
My goal is rearranging the bits status from the input word to the output word. I don't need just making the 0 to 1 or otherwise...
Thank you in advance.
Bit access in Words in CX-Programmer using structured text
in CX-Programmer
Posted
Thank you for the help. I guess I can make it with one big array of boolean(3840) and fill the D memory chronologically with 64 so I can get the bits in the array with the right order. And then I can reorder them as I wish.