I'm using myRio device's accelerometer. I get 3 acceleration values from the accelerometer x,y and z. How do I map the values of XYZ to a certain frequency? For example if x=1, y=0 and z=0 will equals to 500hz.
In the case provided in screen shot you can move Variables X,Y and Z outside the case loop
. Then check ifx=1, y=0 and z=0
use AND
logic operation to check if all X,Y and Z meets your requirements and plug the output from the AND comparison to case selector. Then in true case you can put value of 500 (inside case structure) and in false case use default values if unwired (right click on tunnel).
Other approach (especially when you would like to have different Hz values not only 500 Hz in this particular case) is to change case structure from boolean states (true/false) to several numbers. If X = 1 then input value will be 500 Hz. If X = 2 then input value will be 600 Hz and so on.