I want to create an input field that is a binary number. We are typing in a binary number that goes to an 16 bit integer. Any suggestions beside ripping out the SLC500?
I feel that there may be a better way to accomplish the end result of what you are trying to do. What does this binary number control? Why do you have to enter it as a binary number?
If you are set on doing it this way then you can use a formatted text field with a reg ex pattern of [0,1]{0,16}
to limit the input to a maximum of 16 1's or 0's. Use that in conjunction with a derived tag that uses toBinary/fromBinary
in its read/write expressions that is pointed at the integer in the PLC that you want to interact with.
1 Like