LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how do i fetch particular digital input on off signal

Solved!
Go to solution

hi im new tl labview and can anyone help me to solve this below problem

a digital input will be continuously ON. at particular instance the digital input ON for 2 sec and 2 sec off. this will repeat 5 times. if the input on off time repeated 5 times (2sec on & 2sec off) i have to make a count 

 i did some vi but it is not working. when the condition stay true, it counting  continuosly

Download All
0 Kudos
Message 1 of 3
(2,153 Views)
Solution
Accepted by topic author ben00_007

Hi bramma,

 

at particular instance the digital input ON for 2 sec and 2 sec off. this will repeat 5 times. if the input on off time repeated 5 times (2sec on & 2sec off) i have to make a count 

So you need to implement:

1. check for "digital input is FALSE for ~2s, then TRUE for ~2s"

2a. when condition1 is met, then increment a counter

2b. when condition1 is not met, then reset the counter to zero

3. when counter reaches value 5, then your desired signal pattern is detected

4. reset your counter to zero, after signal pattern is detected

 

Btw. you should also remove those Rube-Goldbergs in your code:

- what's the point of comparing a boolean to FALSE?

- what's the result of "x NOR FALSE"? (It's just a NOT…)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 2 of 3
(2,142 Views)

thank u

 

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