read the values of an array element and by sending a digital output to a designated channel according to the value read from the table

Hello world

could someone help me before I get out of my hair. Here's my problem.

I read 3 values of an array of 3 elements i.e. 1,2,3. These values are then compared to a constant value, example if the first element of the array is 1 and it meets the comparison condition can send a digital camera of output for that channel on data acquisition

I want to be able to send a value from a table to its corresponding comparison and then on its designated channel on the acquisition of data, the whole point of this is due to the fact the table element will not always read the value 1,2,3 for example could be 2,3,1

Here's one the vi I have so far

If someone could help it would be much appreciated

all the best

brand

Take time to explore the many examples included with LabVIEW that cover the basics.

-Indexing table

-reading a spreadsheet file

Tags: NI Software

Similar Questions

  • Control the Boolean commands and generate a corresponding digital output

    Hi all

    I'm working on a project of activation of the electrode, here, I thought that how could I order an electrode in a time and generate a digital output of it accordingly. I want to replace it with each electrode with a LED on the front panel and generate a numerical value to each LED on the block diagram.

    If it can be divided into two parts

    1 control the Boolean outputs

    Here, my goal is that if I have 5 leds that are used as a Boolean control, must be ordered so that only one of them lights up at the same time and the rest goes off.

    I mean for example if #3 was turned on and that the user pressed the #3 #2 should be turned off and only #2 lights.

    2. generate the corresponding numerical value


    Depending on the position of the LEDs I want to generate a corresponding numerical value, as previously released 3 coming and exit 2 then comes when the second LED illuminates.

    I ask all participants to this group to help me with this.

    Concerning

    Why don't you use the radio button control? You can replace the boxes if you want the buttons.

  • Save the values of array element and confirm by the ID of the table

    Hello

    [Apex 4.2.1] Oracle 11g.

    I create an interactive report using some elements of the page. Now, I am able to write these items in a table by using a button with a dynamic action:
    BEGIN
      INSERT INTO teststable
        (ID
        ,TESTVALUE
        )
      VALUES
        (teststable_sequence.NEXTVAL
        ,:P35_TEST
       );
    Now, I want to confirm this as:
    Your current selection has been saved with id  'Select ID from teststable where .....'
    Is there a way to indicate to the user the ID that was just created? Don't forget there are several users simultaneously online.

    THX in advance
    Thorsten

    Thorsten wrote:
    OK, now I know that I need to use

    apex_application.g_print_success_message

    but it won't work either:

    DECLARE
    l_id testschema.testtable.id%TYPE;
    BEGIN
    INSERT INTO testschema.testtable
    (ID
    ,Testvalue
    )
    VALUES
    (testschema.testtable_sequence.NEXTVAL
    ,:P35_TEST
    )
    RETURNING id INTO l_id;
    
    COMMIT;
    apex_application.g_print_success_message := l_id
    END;
    

    Do you know why?

    It only works when the page is rendered

    Create an item hidden on your page or use if available. for example P35_ID

    Change your dynamic action that has this process

    change the return clause:

    RETURNING id INTO :P35_ID;
    

    Enter P35_ID in the Page items to be returned

    Create a real action such as:

    Action: Run the JavaScript Code
    Code: alert (' your current selection has been registered with the id ' + $v ('P35_ID'));

    Please note that you can change this option to show a more user-friendly message instead of an alert

  • compare the two array element and ignore the undesirable element of the array

    Hello

    Here I attached the vi. In this vi I compare table with ideal picture of A to z. normally in an entry, that we get a data with noise, as is show in this vi normally I just need to compare the value has Cwith c D with D with A & B with B, and so on. now the problem is I have to compare ideal picture with input .and string array if the input string is not in series from A to Z the whole comparion is .i false hope you understand my problem and give some suggestion thank you

    Please take a look at this modified version of your code and I would like to know if that's what you are trying to achieve.

    Please, ask questions and make sure you are comfortable and understand what I coded.

  • How can I turn the power on and off NI 9263 voltage output using a distribution channel?

    LabView 8.6

    cDAQ-9172

    NOR-9263

    I used the simple fan control - but can it be modified to turn on and off via a channel instead of a button.

    In other words for example 5 seconds now and 10 seconds off the coast.

    I would also be adjustable.

    Hi Helpme9211,

    Try it please change as my attached screenshot.

    Sincerely, Kate

  • Best way to update table attribute with one value calculated from another table JDeveloper

    I have a simple chart. Payment: Payment_Product = Master: detail.

    So first of all, I have to insert in payment, then in Payment_Product. TotalSum default value is null. After validation, I want TotalSum must be calculated according to Product.Price and Payment_Product.Quantity.

    What is the best way to do this in JDeveloper (12.1)?

    payment_product.jpg

    The best way to do that will not do.

    Don't store calculates the basic values unless you have checked, it improves the speed. Otherwise, this will cause almost always more trublen that she enjoys.

    Calculate this total when you do the report. At this point, you have several aggregate function build SQL where sum() is one of them...

    Good bye

    DPT

  • The search in a table a value then delete this array element

    Hello.

    I have an array of VO (id, link, title, url...) I want to get an ID of this array element and remove the element with the corresponding id. Any thoughts on how I would go to this topic?

    Thanks in advance!

    Ryan

    I don't know much on your and this probably isn't the most elegant solution, but you can do something like:

    for (var i: Number = 0; i<>

    {

    If (myVOArray [i] ["id"] is "someId")

    {

    myVOArray.splice (i, 1);

    }

    }

  • Select the value equal to the table

    I use Dreamweaver CS5 with PHP and a MySQL database.  I'm reading from a table (states []) in the database that list all States an entrepreneur might work to, that is, WA, ID, OR... my record of the insert is savaing my table with the abriviations of State with the coma in the meantime without space, which is fine with me.  My code for the insert recording is:

    If (isset($_POST['states'])) {}

    $_POST ['States'] = implode (',', $_POST ['states']);

    } else {}

    $_POST ['States'] = null;

    }

    To test what must be my result, I tried to hard-code the value for area WA selection that selects the WA (Washington) very well in the dynamic list/Menu. The checkbox allow multiple selections is selected for this list/menu.  When I try to hardcode several States like WA, ID, nothing is selected.  I also tried selecting WA ID and WAID.  What is the correct format of the select value equal to in order to select multiple items.

    Once the coding is figured out I was going to try to understand how to navigate in PHP and do select dynamically recording and echo (or otherwise print) in the right format for several States in the table would be selected.  However, if anyone out there has a sample, that would be great.

    Thank you in advance for your help!

    Darren

    First and perhaps that I read it wrong, but 'implode' in your example should not "explode" because you have the array, but you want to get the values out of it?

    Now I know that my next suggestion is not what you want to hear, but I used to think like you and store things in a table, a table in a loop and then try to check the loop if some values exist.  However, as time has taught me it is not necessarily the best way to store values you need for this type of proceeding.  Most of the time in cases like this, your username will seek entrepreneurs in a specific State.  So what I recommend is to create another table with 2 columns:

    contractor_id (a way to identify the contractor, it will be a primary key, which will connect a key for the "contractor_id" in your original table)

    contractor_state (this allows to link an id to a State)

    A single loop would be to query the status of the contractor, the contractor ID is filled and you can run a join to remove the door contractor while the ID condition is met.  The flip side is to get all the contractor IDs meet the criteria of the State.  You must perform a JOIN on the request to combine the original with this new table table if you want to remove the name of the contractor as well as the State didn't give one example.

    Perhaps a good article that you want to read is the first response of this StackOverflow question and the link in the response are talking about standardization and serialization of data:

    http://StackOverflow.com/questions/1790481/PHP-MySQL-storing-array-in-database

  • Tween an array element

    I created a script that will movieclips to fill the stadium. In this case, a ranking.

    each created movieclip is positioned and placed in a table.

    The problem becomes an array element and the power of tween it

    * I would like to experiment with tween different combinations to get them out of the scene. Here's what I got

    I am able to get the clips on the stage... [Can't get them off =]

    Import mx.transitions.Tween;

    Import mx.transitions.easing. *;

    Block = new Array();

    var Xposition:Number = 0;

    var Yposition:Number = 0;

    var stack:Number=Math.ceil(Stage.height/30);

    var Numofstacks:Number=Math.ceil(Stage.width/30);

    var fadeit:Tween;

    var n: Number = 0;

    for (r = 0; r < (Numofstacks); r ++) / / 25

    {

    PositionY = 0;

    for (c = 0; c < (stack); c ++) / / 3

    {

    var particle = this.attachMovie ("block", "gabarit@sur" + r + c, this.getNextHighestDepth ());

    Particle._y = PositionY

    Particle._x = which

    Block [n] = particle._name;

    trace (Particle._name)

    PositionY = PositionY + 30;

    n ++

    }

    Which = which + 30

    }

    runit var = setInterval (effects, 3000)

    effects function (): Void

    {

    trace ("Go")

    for (a = 0; c <(Block.length-1); a ++) / / 3

    //{

    Yvan = new Tween (block [0], "_alpha", Strong.easeOut, 100, 0, 1.5, true);

    //}

    clearInterval (runit);

    }

    Do not store the _name in table property, store the particle itself.

    Block [n] = particles;

  • CSS: apply the border of the table one table and not another

    I applied the underside of the table for all tables border on my site

    table { width: 100%; border-collapse: collapse; border-spacing: 0; } th, td{ border: 1px solid #999;

    How can I make no border on certain tables while keeping the border on the other?

    I tried to add only one class for some tables and elements and which does not:

    .borderlessTable {
      border
    : none;
    }

    Use CSS classes in your stylesheet.

    table.bordered {border: 1px solid #333}

    table {border: none}

    This table has borders

    This table has no borders

    Nancy O.

  • ExportCollectionAction causes the current values of lines to be copied into the first row of the table

    Greetings experts,

    I use JDev 11.1.2.3

    I am faced with a really strange behavior of the exportCollectionActionListener. I have a table for each row in this table, a link that calls a popUp. This popUp tells the story of this selected save changes (means it displays data from a different table/VO, who keeps a history of the first) in a table. I have a button that calls the exportCollection for this second table. When I press on it, an excel file is generated and downloaded and everything is perfect until now. If there was not any which record in this table, and o back to the first, by pressing the button send is not track all changes. But if there where all records from this table of history (always talking about the history of the current line), go back to the first and press on submit, that the very first line of the table of fir trees, gets all of it's values as the last row of the second table, as it is copied from one to the other. I have to press on restore back to normal (note that the popUp has it's CancelListener to call a restore of a bean to support operation).

    Why is this happening?

    Thanks in advance

    I found a work around for this problem.

    I added the code that causes the whole view Refresh (ie: the whole page), the popUp cancelListener, also I changed the commandLink partialSubmit property and set it to true. It's not like totally cool watching the screen charge for this fragment of a second after the closure of the pop-up window, but it not the drill.

  • By subtracting the tables table 1 d 2d

    Hello world

    So I'm having a different problem now with subtraction tables table 1 d 2d.  I would like to subtract each row and output the result in the form of a table 1 d.  Anyone have any ideas?  I tried to look away, but the info online doesn't seem to work for me.  Such as:

    http://forums.NI.com/T5/LabVIEW/subtract-2D-array-elements-and-insert-the-result-into-a-new-row/TD-p...

    I am only interesting see the result in the form of a 1 d array and do not care to keep the original 2d table.  For example:

    Table 2D:

    1 2

    5 2

    6 4

    Result:

    -1

    3

    2

    Thank you!

    Jon

    Are you the 2D table indexing itself or are you indexing inside a loop with autoindexing?

  • Extract the supplied index value of array element

    Hello

    A similar question might have been asked before, but I couldn't find one that exactly matches what I want. Also, I'm using labview 8.5 so could not read most of the views that you guys tied with other solutions.

    The files that I use are attached. Test_FIFO_TimeTagging-Nov16 - try1.vi is the main vi.

    The absolute time in milliseconds in the table of resorption. As can be seen, it is derived from the berries Micro2 and Macro2. I want the user can specify the duration, that is, whether the current item in the table of absorption has a value greater than the value of the user entered, so I want the index of this item in the resorption so that I can use this index to create Micro2 and Macro2 subtables that contain only items from index 0 to index I get resorption.

    I do not know how to retrieve the index of an array given the value of the element, so can't go forward.

    Thank you

    Kaiser

    Hey Kaiser,

    the function that you need is 'threshold 1 d table '. (I guess that your time values are sorted, otherwise using subdashboards makes no sense...)

  • The value of property to an array element node: How does it work?

    As I tried in vain to understand my shipment of samples recent misconception (here), I came across a behavior that I'm not sure I understand.

    Here it goes:

    Move a table of numeric values to the FP show. a few items. The easiest way is to take a 'table - Numeric (Silver)' pre-formed object with 3 items listed.

    Now, right-click on the top element and select: create > property node > value

    Change this to write about the BD and to connect a constant, say 1. Run the VI, you get this:

    ===>

    So far so good.

    Now do the same for the THIRD item and wire a different constant to the AP, say 3. Rerun the VI, you get this:

    ===>

    All right...

    I mean, it is not already made a lot of sense, but wait what will happen...

    Now remove the first NP and run VI again:

    ===>

    Quite logical, right? ... not!

    At least * I * can't make sense of it and it smells like a bug to me... or a weird feature.

    Tested in LV 2013 SP1 (62 + 2 bits) on Windows 7 64 bit.

    You create a shortcut to write to the ArrElem.Value property.  The property ArrayElement to a table is a little funky, it is the last element that was active.  With only a single PN on your comics in writing a value, click in the central element of the array, and then run the VI, repeat for the other elements.

  • Get all the different values in a table - 'or array elements' does not work with I32

    Hello

    I just found out that "array elements or" does not work with a table 1 d of integer values. I didn't expect that.

    I did a semi quick forum search and did not find a pointer to an effective solution. Can someone give me a hint?

    Do not back my initial intention is to list all the values that appear in an array of integers.

    I thought that if I converted the figures for powers of 2 and or I had solved the problem at hand - only to discover that the elements of array does not.

    If someone could propose a different approach, I'd be happy too.

    I should mention that the execution time is a factor here - I need a fast code, but any suggestions are welcome because they could help me get started.

    Best regards Florian

    Hi Florian.

    try this:

    "Function, it seems, the table of GOLD ' is polymorphic (as written in the context-sensitive help), but does not support arrays of I32. At least the error message means just that...

Maybe you are looking for