01-16-2017 11:47 AM
Generate a random number and scale it by 100 and compare it with a specific number let’s say(i.e. 400) if greater turn on LED and if less turn OFF LED.
i'm new to ni software so please help me in this Thanks.
Solved! Go to Solution.
01-16-2017 11:57 AM
@ShayanAzeemi wrote:
Generate a random number and scale it by 100 and compare it with a specific number let’s say(i.e. 400) if greater turn on LED and if less turn OFF LED.
i'm new to ni software so please help me in this Thanks.
Show us what you have tried. Where are you stuck? This can be done with a Random Number, a Multiplication, and a Greeater function. One control for the threshold and another for the LED output.
01-16-2017 12:40 PM
BTW, 400 will be always larger since NI random number is up to 1, and you are multiplying it by a 100 only.
Just to reduce your testing time by not trying irrelevant values...
01-16-2017 01:00 PM
Hi Shayan,
i'm new to ni software so please help me in this
Then you should take the help offered by NI for free!
01-16-2017 01:26 PM