Digital waveform to boolean value

Hi, I have a digital waveform and I want to be able to light up an LED on the front panel every time the waveform is high...
What is the best way to do this?
I know there is a vi that converts a digital waveform to a 2D boolean array, but I just want a single boolean value.
Thanks!
Sunny

Hi
In reference to my previous post, you can just leave the inner for-loop, but you have to extract the 4 channels.
Just have a look at the picture.
Hope this helps.
Thomas
Using LV8.0
Don't be afraid to rate a good answer...
Attachments:
DigitalWaveform.png ‏6 KB

Similar Messages

  • Hiow to build digital waveform with transition values bigger U32?

    Greetings!
    Is that possible to build digital data with transitions values represented bigger than U32 values? (It seems to me that Labview 8.0 cannot accept U64. See attachment.)
    What do you recommend? I cannot change dt, so scaling does not work. This is because, the record length could be very long...and the waveform should be connected to a digital waveform graph.
    Thanks in advance!
    Attachments:
    ReplaceTransitionValues.jpg ‏21 KB

    Hello Dawid,
    Thank you for the answer.
    Yes, I'd like to build a big array, which although would not be so big... I have not so many samples (just a few thousands) but the samples could be very far from each other. That's why I need U64.
    I'm using compressed digital waveform to transport and display the samples, where the transition value functions as an offset (counted in dt) from the first sample.
    For example, to store a 1Hz signal  with sampling rate 100MHz the transitions will accumulate by 50M. If the record has 1000 samples then the last transition value will reach 50G which is much bigger than a U32 can store.
    You might ask why so high the sampling rate for a 1Hz signal... The signal is stochastic, could be faster, and I would like to keep tha fast pulses also.
    I dig into the "Append digital samples.vi" (see attachment) and I found the transition array is build by U32... I hope I did not misunderstand you, but I think it does not help. I suspect even the Digital Waveform Graph itself is not able to accept values over the U32 range, however, I should try that.
    Best Regards,
    Lamaze
    Attachments:
    AppendSamples.jpg ‏155 KB

  • Converting digital waveform into bit sequence

    Dear friends,
    I am stuck with the task of converting a digital waveform (16 bit values) into
    the following waveform:
    each sample of the original waveform should be represented by a sequence of
    bits (or H and L analog values) in the second waveform,
    the duration of the bit sequence should be half (in general arbitrary fraction)
    of the sample clock period of the original waveform,
    the bit sequence should be padded by zeros so that the total duration of the
    bit sequence and the pad equals to the sample clock period of the first
    waveform.
    I tried to represent these two waveforms in the picture attached.
    It would be really great if someone could give me hints/suggestions to this
    problem!
    Thanks in advance!
    Attachments:
    waveforms.JPG ‏21 KB

    Hi SamboNI,
    Thanks for your reply!
    I have couple of notes:
    I tried to implement your instructions but the LabView gives error message
    (please see the screenshot attached).
    I guess there should be "Boolean to (1,0)" VI between "Number to
    Boolean Array" and "Build Array" VIs (?)
    The problem I have is a bit more complex:
    I have a digital waveform (16 bit integers). I need to transform the waveform
    in the easiest and fastest way into the following form:
    Each sample of the original waveform (16 bit integer number, i.e. 5) should be
    represented by a sequence of 0s and 1s corresponding to the bit sequence of that number (0000000000000101 for 5) padded
    by a sequence of zeros (i.e. 00000) in the final waveform. I will use the
    final waveform to drive single line of the 6534 board instead of 16 lines of
    this bopard in the case of the original waveform.
    More generally:
    I need to realize communication protocol with the AD5541
    Digital-to Analog converter from Analog Devices (
    http://www.analog.com/en/prod/0%2C2877%2CAD5541%2C00.html ) using 6534 NI
    board. Therefore I need also build SCLK and CS waveforms and synchronize
    them with the DATA waveform I was talking above. Is there a way to do this?
    By the way - do LabView have standard means to communicate
    with devices like AD5541? Does it require a special software module and/or
    hardware board?
    Thanks in advance!
    Attachments:
    NumToBoolErr.JPG ‏16 KB

  • Coverting a boolean array to a digital waveform

    Hello,
       I have a 20 bit Boolean array that I need to convert into a digital waveform. Is there a easy way to do that?
    Regards,
    Kaspar
    Regards,
    Kaspar

    Hi xdaf,
    The reason why this VI takes in a 2D array is because this is often used to create digital waveforms with multiple channels and therefore, every row would correspond to data for each channel. To go around this problem, you may simply increase the dimension of your 1D array to a 2D array by feeding it in a Build Array function. Note that although you are increasing it's dimension, you are not adding any new data.
    I hope this answers your question.
    Message Edited by S_Hong on 12-03-2008 02:03 PM
    S_Hong
    National Instruments
    Applications Engineer
    Attachments:
    Digital Waveform.png ‏2 KB

  • Digital waveform to DAQ

    Hi,
    I have generate some digital waveform by reading a text file. the graph that is connected to the waveform is what i wanted. But I need to output this waveform through one line digital output of USB6501. How do i go about doing it?
    Any help is appreciated. Thanks.
    Attachments:
    data.txt ‏1 KB
    test.vi ‏64 KB

    When one looks at the specifications for the USB6501, one notes that it cannot do hardware-timed output.  Therefore, you can't use a waveform datatype to generate output with this card.
    So, you will have to use software timing and a loop.  Since you specify a pretty slow transfer rate (0.5sec), it should work fine.
    Look at one of the examples that ships with LabVIEW to get you started.  Click "Find Examples...Hardware Input and Output...DAQmx...Digital Generation...Write Dig Chan".
    Of course, you only want one line.  So when you specify your physical channel, only specify one line.  Change the function inside the loop to "Single Channel...Single Sample...Boolean (1 line)".  Now the function will accept a single boolean value.
    You do a lot of screwing around with getting your data into the right format.  That can be simplified a lot.  See the attached picture.  This is not complete code -- you will need to look at the example I mentioned -- but this picture and the example, combined, should tell you what you need to know.
    Hope this helps get you started.

  • 1D Array of Digital Waveform

    I have a 1D array of digital waveform and I need to work with the data from it. I can't seem to get the "numbers" from it to work with any array function or any other type of function for that matter.
    I need to be able to convert these so I can find a particular value in the array.
    Thanks.

    Have you tried separating the array into individual waveforms using Index Array VI?  You should be able to use the Get Waveform Components (Digital Waveform) VI on each wavefrom once you separate the array into its component waveforms.  Then you can convert the digital waveform into a Boolean Array using the Digital to Boolean Array VI.  You can then use boolean logic to determine when both waveforms output 1s.

  • How do I output three digital waveforms at once?

    I posted this in Digital I/O, but now I think it's actually more appropriate here because it's not a hardware question. I need to output three digital waveforms at a relatively low frequency, 71.9 Hz. I have a PCI DAQ card, the 6024E and am using the NI-DAQmx functions to try to do this. My program basically generates the square wave that I want, and converts it into a digital wave. I do this 3 times for the three separate waves, and then I combine them into an array and send them to my DAQ functions, which are in a while loop so I can get continuous output. My problem is that the waveform that the DAQ is actually outputting is not what I want. It's outputting a wave that has the same duty cycle (approximately) but the frequency is over 2 kilohertz. It's not like this all the time; after it outputs about 7 cycles of this wave, it goes to logic low for a long time, and then repeats itself. When I probe the digital waveform right before it goes into the DAQ functions, it's running correctly at 71.9 Hertz. Am I doing anything wrong with the DAQ functions or the sampling information? Thanks in advance.
    -- Josh Matloff

    Hello Josh,
    I'm pretty sure that the reason that your digital waveforms are not being produced at the correct frequency is because your digital output is not associated with any sort of timing. Unfortunately, with an E series board you can only do software timed digital operations. This means that the frequency at which the values on your digital lines will be updated depends on how fast/often your computer executes the DAQmx Write that is inside of your while loop. If you have an M series board, you can actually correlate the DIO operations with another subsytems clock (AI/AO sample clock, etc.) which means that you can acheive hardware-timed DIO. In the event that you do not have access to an M series board, I think that AnalogKid2DigitalMan was spot on that you would want to use counters to generate pulse trains (that is if your digital waveforms have a constant duty cycle and period). Depending on what the DAQ board is outputting to, you might also want to consider using the Analog Output channels to generate your digital waveform. As long as you continue to use the digital lines on the 6024E, there is not really a way to guarantee the timing of when the digital lines will be updated. You might be able to get close, but you will probably see some "hiccups", especially if your computer needs to service interrupts or give processing time to another application. And lastly, heed geckoee's advice and don't forget to properly close out your tasks! Putting in some error handling may also help in the debugging process.
    Take care,
    E.Lee
    Eric
    DE For Life!

  • How do I sample a digital waveform?

    I have a digital waveform that represents a 1-bit data stream.  The bit rate is 1Mbit/s (i.e. For a value of '1' the line is high for 1us, for '0' the line is low for 1us). 
    I want to create a numeric array representation of the line by taking a sample of it every 1us and appending it into an array.
    How do I set it up in LabVIEW to sample the line at 1MHz and create a 1-D numeric array of the bits?

    Hi Raine,
    It sounds like you're trying to keep data from previous samples in memory through the next iteration of the sampling loop, then append the new sample to the array.
    Using shift registers is the most reasonable option. To create a shift register, wire your sample data to the edge of your sampling loop then right click and select Replace with Shift Register. You can then use a Build Array function to connect the shift register data with the current sampling data.
    Cheers.
    | Michael K | Project Manager | LabVIEW R&D | National Instruments |

  • Bug in Digital Waveform Graph X-Axis

    Hello,
    I am making separate queried to a database to retrieve analog and digital data over the same time period.  The data were logged at 2 second intervals.  I have verified that both result sets return the same number of values with the same t0 and dt.  I then plot the analog values on an XY Graph and the digital values on a Digital Waveform Graph.  I then use property nodes to sync the two graphs (left and right plot bounds, XScale.Range, and Cursor Position.X).  After doing this, I can see that the datasets do not line up between the two graphs.  The data on the Digital Waveform graph ends several seconds sooner than the analog data.  The x scales of the graphs appear to match but the plots don't align in time.
    Has anyone else observed this behavior?  Is there any work-around?
    Thank you,
    Peter

    There is a much simpler way to synchronize these charts. Just use a stacked chart.
    If you use a bundle function you can take two signals (almost data type) and wire them into a Waveform Chart together.
    Then on the front panel right click on the chart and select Stack Plots
    Since you only have 1 X axis now they are instrincly synched and will always write valules at the same time and update the UI together. You can skip all of the scale synching....
    Since the data you are working with has lincked time stamps, the data will need to be matched, (make sure the samples are anyched and each itteration both would have the same number of samples.
    The last allternative would be to strip the time stamp off of your data then build a new data structure, with the digital data, analog data and 1 set of matched time stamps. You can then plot this on an XY chart using the time stamp for the X axis for both of your other plots.  Let me know if you have other questions.

  • Add plots to digital waveform graph programmatically

    Hi Guys,
                This might be an easy one but I can't seem to find the right property. I'm adding "Plot Name" values for a each Plot in a Digital Waveform Graph. I select each plot with "Active Plot" property and name it. However if there are already e.g. 7 plots and I try to set eight plot active (i.e. 7 = Active Plot) I get an error cause this eight plot doesn't exist on the graph, and so can't be named.
        How can I add (or indeed remove) plots using property nodes?
        Thanks

    Hello,
    One thing to consider is the actual data the graph is receiving.  Choosing plot 8 in this case is perhaps attempting to choose a plot which doesn't exist in the data, which could be why you're seeing the error.
    Off the cuff, one thought might be to have the following "steps" take place when you want to add plots:
    on the appropriate action to create a plot, create a default data set representing that plot
    package that with your overall graph data so that the new plot exists in the data
    write that data to the graph, perhaps using the Value Signaling property (via a property node linked to the Graph)
    trap the graph's Value Change event using an event structure (possibly in a parallel loop) and update the plot name there (much like you are today - using a property node to first set the active plot to <previous value + 1> since you just added a plot, and then set your new plot name)
    Not sure what the rest of your application looks like, but hope this helps!
    Best,
    JLS
    Sixclear

  • Digital Waveform Graph refuses to edit Bus names

    I am trying to display digital waveforms on graph whose lines are grouped. It looks like the functionality exists to group the lines into "Buses". There appears to be a way to rename each Bus from its default "Bus 0, Bus 1, etc." since there is an Express VI called "Group Digital Signals" that does it. It looks like the express VI is editing the attributes on the waveforms in order to rename the Buses. The attributes are NI_ChannelName for the Bus and NI_LineNames for the lines that make up the bus.
    When I code it, the Line Names are renamed according to what I want, but the Bus names remain default Bus 0, Bus 1, etc. Is there something I must do to rename the Buses?
    (see attached VI)
    Thanks,
    Dan
    Solved!
    Go to Solution.
    Attachments:
    Digital Graph.vi ‏26 KB

    So Young Daniel, do you mean like this?
    All I did was select where is said Bus 0,1 or 2 and typed in a new value.
    Mike...
    Certified Professional Instructor
    Certified LabVIEW Architect
    LabVIEW Champion
    "... after all, He's not a tame lion..."
    Be thinking ahead and mark your dance card for NI Week 2015 now: TS 6139 - Object Oriented First Steps

  • Counting number of 1's present in digital waveform obtained by converting the pulse signals.

    Hello,
    I am using Analogtodigital.Vi for converting the pulse sequences into digital.signals.I am able to get the digital waveform representaion of the pulses.
    But how to count the number of 1's present in the converted digital waveform.I want to count the number of 1's present in the converted digital waveform.
    Thanks in Advance.
    Solved!
    Go to Solution.

    Did you try opening the block diagram of Analog to Digital.vi? 
    It creates an uncompressed 2D array of 1s and 0s which represents the 16-bit binary A/D conversion of each element in the Y array of the input waveform. You can use the DWDT Digital to Boolean Array.vi to convert to a 2D array of booleans. Then convert the booleans to 1,0 and sum the array of integers. The sum should be the count of 1s in the digital waveform.
    Lynn
    Note: The attached VI is saved back to version 8.6. When I saved it for Previous Version a warning was generated about possible differences in versions. Let me know if it does not work, and what version of LV you are using.
    Attachments:
    Count bits.vi ‏25 KB

  • Export digital waveform+labview

    Hi to everyone...I'm a newbie with labview, and I want some help for the beggining...Well I'm working on a project and for start I must use an arbitrary signal and an oscilloscope so as I can see the the graph of it(for simplicity I used a sinus in the beggining...)and then I must use an A/D converter and the digitalized output must be saved in a .txt file so that I can read it...So I wired the sinus with the A/D converter but then I cannot make the output of it compatible so that I can save it...I used the component "export waveforms to spreadsheet file.vi" but it says error diffent type of data you cannot wire a "Digital waveform" with the input of the file "1-D array of waveform(DBL)"????I used and some other components for saving in a file but it didn't go better...What did I do wrong???Please if anyone can help me...I would appreciated!!!
    Solved!
    Go to Solution.

    Hi again...I want some help...Last time I sent you "my_main.vi" file and told you that had a problem about making time to be correct in the .txt file...I haven't solved it yet, although I tried a lot to find how I can change this the txt. Anyway for now what concerns me most is that although the gragh(with the formula i use) i see in the front panel is correct when i take the data from the .txt file and paste it to a .xls file and making a graph it seems that there are pulses of the same amplitude before the visible signal i see in my front panel...I couldn't understand why this was happening but after a while i put the same formula in a grahp calculator that i have and saw that the previous pulses are not of the same amplitude, they just appear to be so because the amplitude that is set to the component isn't enough to show their whole amplitude...so they are been cut off and seem to be the same...So i tried to change the values at the x-axis but I didn't make it.The program holds some certain range(0-4) that I had initially set to it...At the bottom line I'm facing a problem to appear the rest of the graph in the component's output, and also to fix the phenomenically wrong pulses to my .txt file...Please I would appreciated if anyone can help me...Im sending you all files to have a picture of wht's going on...
    Thank you for your time...
    Michalis V.
    Postgraduate Student
    Department of Informatics and Telecommunications
    National & Kapodistrian University of Athens  
    Attachments:
    my_main.vi ‏20 KB
    results.txt ‏154 KB
    samples.xls ‏428 KB

  • Jitter of output digital waveform with external clock

    Hi,
    I need to generate digital waveform with 20 bits pattern * 1000 times. Digital waveform must be sync with 1 MHz external clock.
    It is not big deal.
    But there is additional requirement that digital waveform has jitter < 200 ps. It can be delayed for couple ns but it must be very stable.
    Can anyone point me on that parameter? Or share your expirience?
    Thanks!

    Hi Andrei,
    Tph on figure 3 is defined as tp - 2.2ns as we discussed earlier. The data jitter, along with channel to channel skew, is already taken into account. We don't specifically spec the data jitter since we have made this calculate for you. It is safe to say that the data jitter involved in tph is less than 200 ps however this is not a standard spec we provide.
    As for additional board recommendations, what is your application? The 6562 is designed for LVDS applications. The 655x series is highly recommended for high speed TTL based applications. If you reference the 655x manual you will notice similar or better specifications in regards to setup and hold times, which again already take into account data jitter and skew.
    I am curious as to why you would like the specific values documented. We provide the current specifications so that you do not have to use the individual statistics to calculate numerics such as the setup and hold times. Is there something specific you are trying to do here? You mentioned a simple example earlier, what is your actual application?
    Regards,
    Chris Behnke
    Sr. RF Engineer
    High Frequency Measurements

  • Digital waveform frequency measurment

    Hi,
    i have Motor driver can give me the speed as feedback "digital waveform"
    the frequency is proporational with the speed
    i have Cdaq 9188
    also i have ni9401
    1. at which slot i have to connect the cmodule 9401 to be able to reach the counters ?
    2. how i have to connect the speed feedback to module ?
    3. can i have guide about this issue ?
    thanks alot

    Try posting in english here
    Translation 
    Digital waveform editor to create waveforms PXIe-6536 I want to output, what do I like?
    I do not know the correct response is, at present we take the following approach.
    ① Digital waveform editor creates a waveform
       1.. Hws as the output file format
       2. "NI-HWS Express (load)" read
       3. VI confirmed the digital waveform graph output.
    ② PXIe-6536 for creating DAQ Assistant
       1. PXIe-6536 digital output in
       2. DAQ output waveform creation screen test assistant
       3. NI CB-2162 has been confirmed that the output waveform on
       4. DAQ Assistant SUCCESS
    Is conducted to the point where there are some drawbacks, however.
        * DAQ Assistant, you run alone, I get an error
    "-200,077 Error code is DAQmx Write (Digital 1D Wfm NChan NSamp). Vi: 3 occurred in
     Measurements: Requested value is a value that is not supported at this property.
    Property: Output.BufSize
    Requested value: 0
    Minimum: 2
    Maximum: 4294967295 "
        HWS * DAQ Assistant VI to read the attached file for the connection can not connect For the loop to be taken into
        * Thereafter, the sample rate settings do and what do I like?
    Such situation.
    Us, Labview for complete beginners because it is, I do not know how you like the above is correct.
    And I think there are many points, but fall short, you can ask that solved until you have any opinion you have any

Maybe you are looking for

  • Installing Windows 8

    How do I install Windows 8.1 on my 2009 MacBook Pro?

  • Aligning pages in Adobe Pro ver 7

    I can't find anywhere the ability to rotate pages by specific amounts. Only 90 or 180 degrees. Did I miss something? Will this be a feature in the new version 9?

  • How does one make a PLAF

    I understand that to make a custom LAF, all you need to do is extend one of the standard LAFs, but how do you describe how things are to look (and feel)? What I mean is if you want you text fields to have rounded corners, how do you go about having i

  • How to Parse an HTML File?

    Hi all I want to parse an HTML file? How is it possible? After taking an input which is an HTML file, i need to parse it, and i need to print/modify values based on some tags? Please help me, how to parse an HTML file?

  • Physical Path of BDS document

    Hi friends,    Can any one tell me how to find out the Physical path of BDS which are stored in the server Thanks and regards Srikanth. S