ni.com is currently undergoing scheduled maintenance.

Some services may be unavailable at this time. Please contact us for help or try again later.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

In range and coerce binary operation

How do I implment the "in range and coerce" function with binary operation?  I want to do that to make my fpga code more efficient.

------------------------------------------------------------------

Kudos and Accepted as Solution are welcome!
0 Kudos
Message 1 of 4
(2,828 Views)

Please explain what you mean by "binary operation", that could mean many different things.

Message 2 of 4
(2,823 Views)

What exactly do you mean by "binary operation"?  I am assuming you are dealing with integers here to make life simple.

 

The In Range portion is just a simple Less Than and a More Than with an AND ( x < UL && x > LL).  The Coerce portion would likely be best done with Select nodes based on the Less Than and the More Than comparisons.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 3 of 4
(2,811 Views)

Bit and logic operations.  For example, if I want to change a subvi that is checking is the input greater or equal to 8, I would convert the input into a binary array, and do a logical AND to all bits higher than the 4th bit.  I am wondering is there a similar method for in range and coerce.  I think I can make the method that I mention above works for this case as well, but want to know is there a better way.

------------------------------------------------------------------

Kudos and Accepted as Solution are welcome!
0 Kudos
Message 4 of 4
(2,784 Views)