From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

boolean pulse duration

I messed up and posted this in the DAQ forum and couldn't see a way to move it to the Labview forum.

How would you measure the duration of the zeroes and ones in a boolean array of data?? I want to know the length of the on/off values in each segment.
0 Kudos
Message 1 of 7
(3,008 Views)
Hi Unncle,

I owe so here is a quick hack to get you started.

I search for alternating T/F's noting the index of each.

The difference in the index values times your sample period should give you an answer.

Ben

PS Its a quickie so test thoroughly.

Message Edited by Ben on 05-20-2005 01:40 PM

Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
0 Kudos
Message 2 of 7
(2,998 Views)
Thanks Ben,

I'll take a look at it after I get done covering the maintenance people at shift startup. It looks like we need some new analysis vi's for the digital waveform and digital data types. The pulse measurements only work on analog data.
0 Kudos
Message 3 of 7
(2,967 Views)
Hi Ben,

Could you save that file as a 7.0 format?? Thanks..
0 Kudos
Message 4 of 7
(2,963 Views)
Same comments as before.

It just gets you started.

Ben
Retired Senior Automation Systems Architect with Data Science Automation LabVIEW Champion Knight of NI and Prepper LinkedIn Profile YouTube Channel
Message 5 of 7
(2,933 Views)
I modified some of the standard digital table vi's. It outputs a cluster with the signal level, duration of the pulse, and column for bit change. Right now the transitions are based on any of the 8 bits changing state. I'll have to modify the compression vi to search for bit changes in each of the eight data columns.
Message 6 of 7
(2,906 Views)

Hi Ben

 

this is an old post, but your example helped me a lot, thanks.

 

The extension of your example in analyze saved data rev4.llb ‏263 KB however does not produce correct results for me, but I couldn't see why so far.

 

Cheers

0 Kudos
Message 7 of 7
(2,381 Views)