LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

change representation of OR gate inputs

Solved!
Go to solution

Hello,

 

I have a pair of U16 enums in my code which I want to pass into an OR gate. Is it possible to change the input representation of the OR gate to U16 so that I dont need to use a conversion function or have coercion to I32?

 

Dave

0 Kudos
Message 1 of 3
(2,074 Views)
Solution
Accepted by topic author djroseman

I don't know why it converts to I32, but if you explicitly convert the enums to U16, then there's no coercion and the output is U16. The value shouldn't be changed, since the enums are already U16.


___________________
Try to take over the world!
0 Kudos
Message 2 of 3
(2,063 Views)

After a bit more investigation, I discovered that the coercion was because the OR gate changed the type from enum to numeric (U16). A type cast back to enum then made my cases correct again (its being used to control state machine transitions)

 

Thanks for your help

0 Kudos
Message 3 of 3
(2,060 Views)