Labview 7 index waveform array by channel name string

I was messing around with the index array waveform function with a waveform array(3 elements). I had used the set waveform attribute vi with the name input set to "Channel Name." The index waveform array function would not return any data when I was passing a particular channel name to it. Inside the vi I noticed that the name input has to have the format "NI_ChannelName" to match the string constant. Is this explained in the documentation anywhere?? Wouldn't it be more useful to make this string constant a string control input that we wired data into?? Then we could index the waveform array based on any name input that we set with the waveform attribute function.

Hi 08,
despite reanimating an 11 year old thread that information you requested is given in the "Set Waveform Attribute Function" help as written by Brandon…
Best regards,
GerdW
CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
Kudos are welcome

Similar Messages

  • How can I get an invidivual Virtual Channel name without having to pick through an array of all channels?

    I see "Get DAQ Channel Names.VI" and "Get Channel Information.VI" but I just want to get the name of just channel 0, or just channel 1. Is using an array of all channel names the only way I can do this?
    I have Labview 6.1.
    THANKS!!!
    Lauren

    Lauren,
    Yes, currently that is the best way to go about accomplishing that. I attached a little VI that demonstrates a very basic way of finding the first virtual channel that uses device channel 1.
    Ames
    Applications Engineering
    National Instruments
    Attachments:
    Find_First_Channel_1_Virtual_Channel_Name.vi ‏27 KB

  • Keeping Digital Waveform Graph Channel Name constant

    Hello All,
    I have currently run into a problem where LabView decides to change all of the channel names in my waveform graph to some type of default setting, e.g. Line 1, Line 2 etc.  I was wondering is there a possible way to keep the channel names on the digital wave form constant even if I change some of the digital waveform parameters, or pass a null digital waveform constant through one of the channels?  Any help on this would be much appreciated.
    Example:
    Problem
    Digital Channel Name Before:                                 Change Parameter:                              Digital Channel Name After:
    Valve 1                                                                     Only Channel 1&2 used                            Line 1
    Valve 2                                                                                                                                       Line 2
    Valve 3

    Hi di_1,
    Are you trying to add more elements to a property node?  Just grab the bottom and drag it down...check out the pictures.
    Stephen S.
    National Instruments
    1 Test is worth 1000 expert opinions
    Attachments:
    propertynode.png ‏83 KB
    grab the bottom of node.png ‏65 KB
    drag it down for more properties.png ‏96 KB

  • Digital waveform channel names are incorrect

    I create a task at runtime where the user selects which physical digital input channels to use and the names for each.  I then sample these digital inputs and write the waveforms to a TDMS file.  The file has the correct data, but only the first channel has the correct name.  Attached is example code that shows the problem.  What am I doing wrong?  I do a similar setup for analog inputs and it works fine.
    Attachments:
    Digital Channel Names.vi ‏89 KB

    How are you entering the names?  Here is text straight from the LabVIEW Help
    name to assign specifies a name to assign to the virtual
    channel this VI creates. If you do not wire a value to this input, NI-DAQmx uses
    the physical channel name as the virtual channel name. If you use this input to
    provide your own names for the virtual channels, you must use the names when you
    refer to these channels in other NI-DAQmx VIs and Property Nodes, such as the
    source input of the DAQmx Trigger
    VI.
    If you create multiple virtual channels with one DAQmx Create
    Virtual Channel VI, you can specify a comma-separated list of names to assign to
    the virtual channels. If you provide fewer names than the number of virtual
    channels you create, NI-DAQmx automatically
    assigns names to the virtual channels. 
    Are you entering multiple names seperated by a comma?
    Regards,
    Jon S.
    National Instruments
    LabVIEW R&D

  • How to display on the graph three or more waveforms where time scale is not an index of array but a real time

    How to display on the graph three or more waveforms where time scale is not an index of array but a real time:
    I measure three voltages Va, Vb, and Vc on my Test stands every 3sec. So I’m building four arrays (Va, Vb, Vc, Time) and combine all in one.
    Time
    Va
    Vb
    Vc
    0
    5
    3.5
    2.8
    3
    4.9
    3.6
    2.9
    6
    4.8
    3.8
    2.1
    Now I need to show on the graph in which scale X is “Voltage” and scale Y is “Time”.
    How can I do it?
    Thanks a lot,
    Boris

    Hi, thanks all your reply.
    You may find "points_to_bar_graph.vi" from this website, I find it by this way.
    I will ask a stupid question: I don't have any photo processing software, how can I save the vi into a picture format?
    So here I just paste it into word document.
    Attachments:
    question.doc ‏520 KB
    points_to_bar_graph.vi ‏62 KB

  • Get TDMS Group Channel Names Array

    I'm having trouble using the TDMS Get Properties to get the channel names of a group.
    I want an array of: ch1_unused, A_SRV_z, etc...
    Attachments:
    TDMS get Group Channel Name Array.JPG ‏64 KB

    If you want to get all the channels names under a group, please use "TDMS List Contents" node.

  • Channel name lost when averaging waveform

    Hi, I am writing an application where data is acquired for DAQ continuously. Data is averaged for example every 1ms and then written to file. Problem is that channel names are lost when doing averaging. I am using 'averaged DC-RMS.vi'. I could copy the attribute before averaging and then write them back afterwards, but doesn't sound like good solution for streaming data application with several channels. Is this a bug or feature? Is there any other way to maintain channel names?
    BR Marko 
    Here is sample picture:
    Attachments:
    Lost Channel name.png ‏29 KB

    Hi Marko,
    I have toiled with this same problem, without finding a
    solution.  It seems trivial enough, yet the answer still eludes me.  Could you please post your code for others to
    learn from.
    Thanks
    Alan 

  • Manipulati​ng the outputs of the Get Channel Names.VI version 5.1

    Using the get Channel Name VI. I get two arrays. One array lists the channel names acquired from the measurement and automation utility and the second array lists the accompanied units of those channels. The problem is in the order of channels listed. The VI sorts the array by date the channel was created in the measurement and automation utility. When I resort the channels in alpha numberic order I want to keep the units associated with their correct channels. How can this be done. Or can the get channel names.vi be modified to sort alpha numberically while outputing the correct units associated with those channels.
    Attachments:
    getnames.vi ‏19 KB

    Here's something to try (Sort 2D array ala index and bundle cluster array):
    http://sine.ni.com/apps/we/niepd_web_display.DISPL​AY_EPD4?p_guid=B45EACE3EA4356A4E034080020E74861&p_​node=DZ52026&p_submitted=N&p_rank=&p_answer=&p_sou​rce=External
    You just need to remove the indexing portion and directly feed in the names to the upper terminal of the index/cluster array and units to the bottom.
    2006 Ultimate LabVIEW G-eek.

  • Accessing custom device FIFO array element by name

    Hi,
    Some of my custom devices have a large number if I/Os. Because the FIFOs are arrays, my custom device RT driver VI has been referencing them by indexing the arrays. Is there a recommended method to reference FIFO I/Os by name, and preferably the same name as the channel names that are created by the initialization VI? Referencing array elements by index can get very confusing and not very flexible if I need to add or remove custom device I/Os. Thanks.

    You could use an enum diagram constant to wire to the index terminal of index array. Make the item name correspond to the element name.
    LabVIEW Champion . Do more with less code and in less time .

  • How do I add the channel-name to mixed signals?

    Hello,
    I want to save a XY-Signal to a tdm-File and import it into DIAdem.
    So I merged the X- with the Y-Signal and connect the merged-signal to the "Write To Measurement File" VI.
    In DIAdem I can see both signals but their name are "Untitled" and "Untitled 1". I don't know how to fix that.
    If I use the low-level storage VIs, the other problem occures. I can give the X and Y-Channels my desired names, but they are in waveform - I want them as numeric channels in DIAdem.
    So how can I give the mixed-signal the names
    or
    how can LabVIEW say to DIAdem that it is a numeric signal?
    KR
    Lukas
    Message Edited by schmiddy on 01-11-2008 04:31 AM

    Hey Lukas,
    To name your dynamic signals you can see this KB "How Do I Rename Signals in Dynamic Data?".  After you name your signals appropriately, you could then merge them together and write to a tdm file.  DIAdem will then be able to read the channel names from the tdm file.  I hope this helps.
    Best Regards,
    Software Engineer
    Jett R

  • Get daq channel names

    I recently upgraded from LabVIEW 6.i to LabVIEW 8.5. Back in 6.1 I could get all the channel names configured in MAX using Get DAQ Channel Names.vi. I was wondering how I can do this in 8.5. Ideally I would like the output to be an array of strings so I can then sort through them.
    Thanks

    Hello,
    I think that you can do that on daqmx. Using property node. See the attached file.
    Software developer
    www.mcm-electronics.com
    PS: Don't forget to rate a good anwser ; )
    Currently using Labview 2011
    PORTUGAL
    Attachments:
    ChannelName.PNG ‏19 KB

  • Please help me assign channel names

    Hi Im trying to log select data when any of 24 signals rises above 5 V which I have done with Greater or Equal Express VI. I'm having a hard time getting this data to my file via Write to Measurement File. A waveform plot that I have connected to this signal has no problem extracting the channel names from the signal. However they aren't as easy to get into my data file. I have been searching quite a bit and I know I need to convert to array to get names then back to dynamic for the file making. I'm not having any luck with this approach.  I have quite a few dummy channels involved and I thought about extracting channel names from mx, but obviously I'm only interested in the selected signals of specific channels that have specific voltages.  
    Thanks.
    Attachments:
    need help channel names.png ‏32 KB

    Hi nwiman,
    I looked a little into your code and I want to point a few things out to you.  I think you now have the Write to Measurement File almost worked out correctly.  Firstly, I want to let you know you are using a DAQmx task, and because we don't have you MAX configuration, we don't know what that is.  I chose to simulate a USB-6351 to get some analog inputs, it is titled Dev1 in my MAX.  Also, to avoid a buffer overflow error from DAQmx while it is waiting for the user to determine the file path, I used a File Dialog express VI to get the path before the While Loop starts.  Lastly I unchecked "Ask user to chose file" in the properties of Write to Measurement File and chose "append to file.  I also want to point out that your code has Tab constants, but the Write to Measurement file is set up for Comma delimited. To show you the functionality of the write to measurement file, I wired the signal after the DAQmx read to the write to Measurement File, and it works how I think you would expect it to.  I recommend using charts for your output signals and when they look like you would expect them, wire them into Write to Measurement File. 
    To run the snippet I have attached, you must simulate a USB-6351 in MAX.  Follow this link to add the simulated device to MAX, once it is in MAX you should not need to create a task or anything, just make sure it is named "Dev1".
    Regards,
    Chris
    National Instruments
    Applications Engineer
    Attachments:
    modified.png ‏555 KB

  • How do I get channel names written into a logged ascii file in Signal Express

    Hi there,
    This maybe a rookie question but I am a relative rookie to this software, and I hope it has an easy fix!
    Background:
    Take a load of analogue inputs from a DAQ device into Signal Express, first thing that hits me is that unlike labVIEW you cannot right click in the channel configuration window and change the name from say... Dev2_ai0 to Air Pressure? I feel that if this was possible then I would overcome my problem? anyway I can't so onwards...
    I goto the DAQmx Acquire window on the top left and can right click and rename the channel, which is great... however this does not translate to the logged data as I get the ai0 channel names across the top of the columns and not the names that I have put in.
    Is there anyway of getting data like the attached snippet?
    Many thanks for your help in advance.
    Neil Barker, Redbull Technology.
    Attachments:
    Channel names.gif ‏4 KB

    Hi Dan,
    Thanks for the reply, that has certainly fixed my issue as I wasn't expanding the channel and selecting the channel that I had renamed.
    One last thing though:
    I now not only get the individual channel name but the prefix for the DAQmx Aquire, for instance I get the Input of Braketest and then the channels under the input data.
    It looks a bit like this....
    Braketest - Front Pres
    Braketest - Rear Pres
    Braketest - FR Temp
    Braketest - FL Temp
    etc etc...
    Now all of the channel names at the top of the columns have this long name. Can this be rectified? can I remove the "Braketest" bit?
    By the way I am saving it as an ASCII so that I can read it in excel.
    Many thanks, Neil.

  • Photoshop CS6 using javaScript to truncate alpha channel name

    Hello,
    I'm a production artist and I work with PSD files that were created in Adobe Scene7 Image Authoring Tool. These PSDs contain a background layer along with 1-20 alpha channels. My script has to make a new blank layer for every alpha channel in the document. Then it fills the new layer with light gray. So far, my code accomplishes this. However, I'd like to apply the name of the alpha channel to the layer, but I need the name to be truncated. Every alpha channel starts with one or more characters followed by a backslash and then finishes with one or more characters. Here's an example:
    An alpha channel might be named:  Floor\floor
    In this example I need my layer name to be just:  floor. This means all character to the left of the backslash, including the backslash itself needs to be discarded. I was using the subSring() statement to do this. When I try to step through the code, line by line in ExtendScript, I immediately get an error that says Unterminated String Constant and Line 31 of my code is highlighted. I suspect it doesn't like the way I wrote the backslash character, although I surrounded it in double quotes to define it as a string.
    Can anyone tell me why I'm getting this error?
    Below is my code with lots of comments to walk you through the process. I wrote where the error occurs in red type.
    I'm new to JavaScript so I'm not sure my while loop is accurate.
    #target photoshop
    // The #target photoshop makes the script run in PS.
    // declare variable to contain the active document
    var myDoc=app.activeDocument;
    // declare variable to contain the number of alpha channels, excluding the RGB channels
    var alphaChan = myDoc.channels.length - 3;
    alert(alphaChan + " alpha channels exist");
    // create loop to make new layers based on number of alpha channels, fill layer with gray and apply alpha channel name to new layer
    for (a=0 ; a<alphaChan ; a+=1){
    // make new blank layer
    myDoc.artLayers.add();
    // fill blank layer with gray
    var color = new SolidColor();
    color.rgb.red = 161;
    color.rgb.green = 161;
    color.rgb.blue= 161;
    myDoc.selection.fill(color);
    //variable stores alpha channel name
    var alphaName = myDoc.channels[3+a];
    // variable stores lenght of alpha channel name
    var lz = alphaName.length;
    // declare index variable to initialize position of 1st  character of alpha channel name
    var x= 0 ;
    // truncate alpha channel name by removing all characters preceding the "\" symbol
    while (alphaName.subString(x) != "\"){          (ExtendScript gives an error for this line and highlights the backslash and surrounding quotation marks)
        alphaName = alphaName.subString((x+1),z);
        x+=1;
        z-=1;
    return alphaName;
    // remove the backslash from alpha channel name
    alphaName = alphaName.subString((x+1),z);
    //  apply truncated alpha channel name to corresponding layer
    myDoc.artLayers[a].name = alphaName;

    while (alphaName.subString(x) != "\"){ 
    should be
    while (alphaName.subString(x) != "\\"){ 

  • Removing quotation marks from channel names

    Firstly - I am new to both DIAdem and VB so please forgive my ignorance!
    I have a large data set containg many groups with (almost) identical channel names in each group. For reasons not worth going into some of the channel names have quoation marks around them, while others do not.
    I am trying to remove the quoation marks to make all channel names consistent throughout the groups, for this I was hoping to loop through the groups renaming channels as appropriate
    I think this should work:-
    For
     i = 1 to GROUPCOUNT
    Call GROUPDEFAULTSET(i)
     CN(""ChannelName"")="ChannelName"
    Next
    Where ChannelName is the name I am trying to replace, But I get the following error:- Expected ')'
    Can anyone point out where I am going wrong?
    (Note - I also tried using triple quotation marks ("""ChannelName"""), but I get this error instead - CN(""ChannelName""):=ChannelName Close bracket ")" expected for field index)
    For bonus points - how to I get the loop to skip over any groups where the channel I am referencing already doesn't have quotation marks in it, rather than giving me an error that the channel can't be found?
    Many thanks in advance for any assistance!
    Dan
    Solved!
    Go to Solution.

    Hello Dan,
    You are using an old script syntax to manipulate the data. Please find below the current way to replace quotation marks with an underscote:
    dim iLoopG, iLoopC, oGroup, oGroupChns, sQM
    sQM = chr(34) ' the " character
    set oGroup = Data.Root.ChannelGroups
    for iLoopG = 1 to oGroup.Count
    set oGroupChns = oGroup(iLoopG).Channels
    for iLoopC = 1 to oGroupChns.Count
    'msgbox oGroupChns(iLoopC).Name
    oGroupChns(iLoopC).Name = Replace(oGroupChns(iLoopC).Name, sQM, "_")
    next
    next
    Greetings
    Walter

Maybe you are looking for

  • After upgrading to Yosemite my IMac  Hangs

    After upgrading to Yosemite my IMac will hang usually on a given App and I have to force a power down and reboot to get it back in operation. Anyone else having this problem?

  • Upgraded 1phone 4 can no longer see who is calling on other line?

    Upgraded Iphone 4 now can no longer see who is calling while the phone is in use.  I hear the beep but see nothing, also does not show in missed call.

  • Digital signature stopped working in Acrobat Pro 9

    My digital id functionality in signing PDFs has suddenly stopped working. I've tried using it with multiple documents and none are working. I tried to create a new digital id, but that doesn't work either. Here's the error message I'm getting: (pleas

  • Ios 8.1.3 update is hung up

    I have an iPhone five. It iwas running iOS 6.1. I have tried to install the iOS 8.1.3 upgrade. The phone appears to be hung in the upgrade with the screen showing the black background with white the Apple and the upgrade line almost at completion. It

  • Problem with Enhancement Spot

    Hi Experts, I have implemented an enhancement spot in standard report program and export the data to some memory id. But the problem is when i am trying to execute the standard report the internal table which i want to export has entries. When i exec