Passage of the value of sub vi

Hello

I am programming some hardware and I'm having a pretty basic problem. I have a sub VI which controls the aquistion of data having a busy boolean signal that is set to true when the equitpiment is activated.  I would like to pass this signal on my main vi, but the light in my main vi ever. According to me, the question is the sub that VI only passes values back when he finished, and it ends when the equiptment turns off. I created a vi example to illustrate my point. Is there a way around this problem?

Thank you

Create a reference to the indicator control in main VI, pass it to the Subvi (via the connector pane) and write inside here using a property node.  Bob will be your uncle.

Oh Yes.  Please do not use stacked sequence structures.  Why a search on these forums for reasons and alternatives to the use of these horrible, horrible, horrible things.

Tags: NI Software

Similar Questions

  • Re: Passage of the value of the Java script

    Hello

    I would like to change the value in the text field of the java script P1_PERIOD and show the alert with the value of the P1_PERIOD
    When you press the button.

    The following code, I wrote in the button display attribute - attributes

    onclick = "JavaScript:ShowAlert (P1_PERIOD); »

    Java script:
    ---------------
    < script type = "text/javascript" >
    function ShowAlert (p_val)
    {
    Alert ('You have indexed' + p_val);
    }
    < /script >

    He's back char invalid error. Where am I wrong?

    Thanks in advance.

    Dip

    The correct call would be:

    onclick="javascript:ShowAlert($x('P1_PERIOD').value);"
    

    Denes Kubicek
    -------------------------------------------------------------------
    http://deneskubicek.blogspot.com/
    http://www.Opal-consulting.de/training
    http://Apex.Oracle.com/pls/OTN/f?p=31517:1
    -------------------------------------------------------------------

  • Passage/transfer the value looking for editing a page

    I have a jsp page where I run a method associated with a button. This will essentially create a "project". After the execution of the method I am forwarding to a page editor for this 'project '. I would like to have the edit page to search automatically for the project that I just created in the first page. What is the best solution?

    No it will work with two different views see also:
    http://blogs.Oracle.com/Shay/2009/11/passing_value_between_pages_to.html

    Published by: Shay Shmeltzer on Nov 24, 2009 09:51

  • ID of passage with its values in the fields in form when the button is clicked.

    Tried to pass the value according to the button clicked with his id in to form.

    I am able to get the id in the right place as you can see in the Image below, but not able to pass all the different values of it.

    Global function:

    function get_id (id)

    { var a = parseInt (id)

    Apex. Item (P73_SHIP_ADDRESS_ID). SetValue (a);

    }


    Static page source:

    declare

    Id1 number (10,0);

    Start

    for rec in (select * from OMS_SHIPPING_ADDRESS where USER_ID =: P1_USER_ID)

    loop

    Id1: = rec. SHIP_ADDRESS_ID;

    sys. HTP.p ("< br > < div >");

    sys. HTP.p ('< a >' | sys.) HTF.escape_sc (CRE. TYPE) | "' < /a > < br / >"

    || sys. HTF.escape_sc (CRE. ADDRESS_LINE1)

    || ' , '

    || sys. HTF.escape_sc (CRE. ADDRESS_LINE2)

    || "' < br / >"

    || sys. HTF.escape_sc (CRE. CITY)

    ||  '-'

    || sys. HTF.escape_sc (CRE. ZIP_CODE)

    || "' < br / >"

    || sys. HTF.escape_sc (CRE. STATE)

    || "' < br / >"

    || sys. HTF.escape_sc (CRE. COUNTRY)

    || ' < br / > < input type = "button" value = "sΘlectionner" onclick = "get_id (id)" id ="" | recomm. SHIP_ADDRESS_ID | ' ' ' > '

    );

    sys. HTP.p ("< / div > '");

    end loop;

    end;

    Below the Image if I click select can pass id to send the address id but able to pass the address line1.line2, city etc...

    I tried to move to the global function also does not work! If someone could guide me!

    123.JPG143.JPG

    Hello

    If you have already passed the ID, then why don't you create a dynamic action on change of SHIP_ADDRESS_ID and load the details of database and fill in other areas.

    In this way the use of ID is understandable.

    --

    Sunil Bhatia

  • Void string formula during the passage of several values of variable presentation

    Dear all,

    I have a scenario where I will get one or more presentation variable values, and each value should create a separate chart where each graph should filtered by a single value.

    For example: If suppose that my presentation of the values of variable passing as below.

    IN ("ASTON MARTIN", "KIA", "PEUGEOT", "DACIA")

    Then I should get four chart:

    as the first chart report filtered by ASTON MARTIN

    as the second chart report filtered by KIA

    as the third graphic report filtered by PEUGEOT

    as the fourth graphic report filtered by DACIA.

    Kindly help me out here.

    Thank you

    In your non-text expression expression may be only "Dim MBV CSD". "' @{RF1} {Lk Veh Vehiclemake}.

    Then

    LOCATE(',' || cast("Dim MBV CSD"."@{RF1}{Lk Veh Vehiclemake}"as varchar(1000)) || ',',  ',' || '@{L1}{FIAT,FORD}' || ',') >0
    

    PS

    But in this column (if is not text) you'll never find values 'FIAT', 'FORD' etc.

    Make sure that your model and reports are correct.

  • How is it that I can ping between ESXi vmkernel interfaces with the sizes of package exceeding the value set in my passage upstream and one located in my vmkernel port group itself?


    I have a 10 GB dell powerconnect 8024f the switch and the firmware is OLD, but the port config shows maximum frame size = 9000 to all cable ports

    2 guests ESXi 5.5 wired, build 1331820, put each host computer network is managed by a single port dual qlogic 8150 ANC

    When I connect to my windows VM to check my new 10 GB connectivity (it is configured for jumbo mtu = 9000 frames) and ping-l 8190 against ESXi vmkernel interface that was MTU of 1500, I get an answer without any packet loss... How can it be if the port is configured for only 1500 MTU?  I thought that the two vmkernel port group and vswitch properties must have 9000 mtu defined, it appears that the vswitch properties override the port group properties.

    But I know I must be missing something, a few important concepts, somewhere, because when I connect to ESXi via ssh I can ping devices with values greater than 8190 and not just windows virtual machines that reside on the same host where the ping uses the internal bus, but I am referring to the connections of the host of other ESXi on the switch management.

    In summary - how the VMkernel does ping and response to pings of bigger sizes greater than the value of the switch upstream?   and why do ping with large packets get answers when the vmkernel port group is always set at 1500, is this a bug or is this feature obsolete?   I remember specifically in ESXi5 that I had to configure the vmkernel port group and the vswitch for this property to work.

    Unless you specify "Don ' t fragment" (-f for Windows) you will be able to use any size package successfully.

    For ESXi, take a look at Troubleshooting ESXi Jumbo Frames.

    André

  • The values of different session during the passage of &amp; APP_SESSION. as a parameter

    Hi all

    I use APEX 3.1.1 and have the following problem: I have a JS function in my application, which generates a URL by using the provided parameters. His signature might look like:

    function xxx (p_param_item, p_session, p_app_process, p_app_id)

    Yes, I use this to call for a process on demand application (AJAX magic ;)

    The problem is that when I call a page using item & APP_SESSION. for the 3rd parameter, it seems that for some reason JS receives a different value (I checked myself put an alert and displays the value of the parameter and the & APP_SESSION. string substitution).

    I know will say you: + "then why don't you use & APP_SESSION.» Instead? "+ but the thing is, my JS code in a separate file, and for some reason, APEX does not replace this string on this separate file.

    Then... of suggestions? Ideas? New approaches?
    Thank you all in advance for your help.
    Kind regards

    A & iacute; Prom

    Hello

    In an external file, you can use-

    $x('pInstance').value
    

    or

    $v('pInstance')
    

    (depending on your version of APEX)

    to reference the value of the current session.

    Hope this helps,

    John.
    --------------------------------------------
    Blog: http://jes.blogs.shellprompt.net
    Work: http://www.apex-evangelists.com
    Author of Pro Application Express: http://tinyurl.com/3gu7cd
    AWARDS: Don't forget to mark correct or useful posts on the forum, not only for my answers, but for everyone!

  • The value of the seed of the generator of random numbers in Matlab node

    Hi all

    I need to use random variables inside a Matlab Labview Commsuite node. I generate with the randn() function. Is it possible to put the seed of the random number generator such as the random numbers are reproducible?

    Hi Steve,.

    You can use randn ('seed', seeds) to initialize the random number generator. The seed must be a positive integer value. For example, randn ('seed', 3). In addition, this seed is global within the entire application. This means that if the randn() function is called MathScript multi-node that could run in parallel, random results are not guaranteed to be the same after you change any part of your code. But you should always get the same results for repeated passages of the same code.

  • Access the values of cells in neighboring XTable Diadem

    Hello

    Can someone please help me understand how to access values in adjacent cells in the case of XTable EventValSet?

    Void XTable1_EventValSet (ByRef ByRef this, lines, columns, cells) ' set the event handler

    Select the box collar
    Case 1
    neighbor2 = This.Columns (2). Cell.Text ' this is pseudo-code... Note how you deal properly with an adjacent cell?
    Case 2
    neighbor1 = This.Columns (1). Cell.Text
    Select end

    End Sub

    This code is for discussion... I couldn't find a way to do it.

    Thank you

    Jim

    Kevin,
    I contacted R & D on this issue, and they offered very useful answers.

    The first thing we need to understand is that the XTable stores all values. This allows XTables to have very high performance, even for large sets of data. For this reason, there is no built-in way to access the values of the cells surrounding (or arbitrary). We are limited to what we receive in the case of managers since the XTable is a structure based on events.

    Alternatively, we can write our own class that implements the XTable. In this way, we have the ability to reuse the Manager of EventValGet in the EventValSet Manager to access arbitrary cell values. Our new class must implement all the cell properties that are available in the EventValGet code, but they are not too many, so it is not unreasonable. Here is an example:

    class MyNewCell
    Public text
    end class

    Void XTable1_EventValSet (ByRef ByRef this, line, column, cell)
    Dim oCell
    Set oCell = new MyNewCell

    Nearby Sun
    Select the box collar
    Case 1
    Call XTable1_EventValGet (This, lines, columns + 1 oCell, false)
    neighbour = oCell.Text ' Note This is pseudo-code... get a cell adjacent to the previous line
    Case 2
    Call XTable1_EventValGet (This, line, column - 1 oCell, false)
    neighbour = oCell.Text
    Select end

    MsgBox neighbor

    End Sub

    Void XTable1_EventValGet (ByRef this, line, column, ByRef cell, IsInputCell) ' Erzeugter event handler
    Cell.Text = line & "-" & Col
    End Sub

    It is worth noting that, although there is workaround, it is against the rules of design XTable.

  • move the cluster for sub vi

    Hello

    I want to spend a cluster that can change its content to one under VI. The cluster does not change by program, but during programming, that is, I could add or remove items in the / cluster. Using direct wire or local variables I would have to change each sub VI that uses the cluster updated the. I also tried the typedefs, but I met the same problem.

    At the same time the Subvi should be able to update the cluster I spent.

    In C++, I use classes like struct (equivalent to the cluster of LV) and pass a pointer to a class object to a function. Within the function, I choose the members of the class I want to use inside this function. If I change the class structure, the functions of the Word are not affected (of couse only as long that I remove irrelevant of class members of the called function).

    Example (from C++):

    settings * param;  'settings' is a class that I use to group variables

    doSomethingUseful (param);

    / * the doSomethingUseful function uses the pointer to parameter and accesses the members of

    Param-> variable1

    Param-> variable2

    ...

    Hereby, I can change the values of variables stored in the param object

    */

    Best,

    Max


  • Change the value of all slides

    Hello world

    I need help today with a problem on the slide - void / knot vi and property.

    I would like to change any value of slides with a sub vi

    Any ideas?

    Thank you

    Hello

    Using the node property, you can change the value of the slide.

    Siva

  • Assistance needed for the registration of the application and store the values in a table

    Hello

    Hope that this explanation is not confusing. I explained my application you want in the text below and also attached a skeleton VI + screenshot hoping that he will clarify

    I try to do a VI that does the following:
    1. some code (blue Subvi) runs every 200ms
    2. every 200ms, a random number is generated
    3. the random numbers are stored in a table in intervals of time s 0.8 ("iterations")
    4. at any time, the (blue Subvi) code needs to have access to the random numbers generated in 'the previous iteration.

    To clarify, the iterations are as follows:
    Iteration #1: 0 - 1.8 s
    Iteration #2: 2 - 2. 8 s
    Iteration #3: 3 - 3.8 s

    Iteration #4: 4 - 4.8 s
    ..
    And so on...

    So for each iteration: the blue (Subvi) needs to have access to the random numbers generated in the previous iteration, for example:

    Iteration #1 (0 - 1.8 s): The blue (Subvi) Gets an array that contains only the zero (random numbers are recorded for the first time)
    Iteration #2 (2s - 2 8 s): The code gets an array containing random numbers of iteration #1
    Iteration #3 (3 s - s 3.8): the code gets an array containing random numbers of iteration #2
    Iteration #4 (3 s - s 3.8): the code gets an array containing random numbers of iteration #3
    ..
    And so on...

    At any given time in time;
    -The code gets an array that contains all the random, recorded during the previous iteration numbers
    -Values since before her previous iteration are ignored and not stored anywhere

    Thus, for example, to the #7 iteration:

    -The values during the iteration #6 are made available to the code in the form of a table

    -Values of #1 to #5 iterations have been deleted and not stored anywhere

    It is important that all values since before recording the previous iteration are deleted because they are not necessary because VI actaual will work for a long period of storage of numbers a lot more than I have indicated here

    Screenshot of the skeleton VI:

    I tried to play with the paintings, the structures of the case and the registers at offset, but everytime I try I get something wrong

    The skeleton VI is also attached (Iteration_VI and Code_SubVI)

    Any suggestions?

    Thank you!

    Yes, I agree that you need help.  First of all, you really do need to learn more about LabVIEW - spend a few hours with the tutorials, such as those mentioned on the first page of the Forums.  Oops - links to the tutorials which had been present for years seem to have been moved "elsewhere" with August 2016 LabVIEW community reorganization.  But look for them...

    Here are a few screws that basically implement what I described above (with some minor modifications).  First of all, this is a Top level VI which runs at 5 Hz (200 msec waits).  It starts with an array of 5 elements of 0, then once per second, this is replaced by a table of random numbers generated by the Random 5-table sub - VI 5 elements.  Note that I do not use a loop timed - those who are really designed for LabVIEW RT, but use the simplest functions on the Palette of the timer.

    Can't you see how that works?  The array to initialize on the left begins you with a table of 5 elements of 0.  The Timer inside the loop, it runs at 5 Hz, 'Index' counts 1, 2, 3,... to tell you where you are, and 5 shows you everything that lives on the shift register.

    Now sub - VI Random 5-table is supposed to do the following - if she was called to 5, 10, 15,..., it must return a (new) array of 5 random numbers, otherwise, it must return the array that was passed in.  So if all "works", table 5 shows 0, 0, 0, 0, 0 for the first second, a table at random for the second second (which is not superfluous!), a different for the third random picture second and so on.  I have already said a way to build this, but I chose a slightly different method (equivalent).

    Whenever it is called, a new random element is generated and added at the end of a (growing) random table stored in the shift register.  If size become 5, we send this Random-table-of-5 out through Out table and reset the register shift to an empty array.

    The case by default (when the size is not equal to 5) is shown below - we just return the array of entry to and accumulate new random table in full growth.

    These code fragments extracted from VI.  If you have LabVIEW 2016 (see the "2016" at the top right of the image?  This shows that it is a snippet of code LabVIEW 2016), you can open a blank diagram and drag this image, where magic OR converts it to a VI.  Otherwise, the code yourself and try out it.

    Caution - it is designed to run once.  If you run the program of high level, a second time, you may find that the new Random 5 - table appears to 0.4 ", 1.4", 2.4"(instead of 1", 2 ", 3").  I leave as an exercise for understand you to (a) why he is and (b) fix the code.  If you can't do that, then move an another 3-4 hours with the LabVIEW tutorials (or start playing with this code, edit it in some small way and to understand how it works).

    Bob Schor

  • Passing values to sub VI and write data to controls

    As part of a control for a VFD interface I am interfacing with via Modbus TCP, I wanted to try some of my code partition in a Subvi

    However, in doing so, I will be very difficult to understand how I can read the current settings of player for the ramp up and down values and update these values in the front of my control.

    The Vi sub is tested and works exactly as I want. Selection playback (system lock on pressed) reads the registers of the reader and exports controls and indicators. The indicators have been included because I didn't know how to move the data off the sub vi without them. Update of work to write the current value in the controls in the VFD logs.

    However when I integrate my project more extensive this VI values are always represented by zeros if I lock switch. However, I see a momentary flash of the correct values after pressing the play button or if I change the closing operation changed, however, I would prefer that it to opperate in a mode of closing in order to reduce the overhead costs of communication on the disc.

    Hello

    A number of suggestions:

    1. use references and property nodes to define indicators FP of a Subvi (you can learn more here and here)

    2. do not put the indicators of production inside the case. When the case is not read, the VI generates the default values to the outputs and gives you the values null.

    Good luck

    Danielle

  • Pass the value of slot - VI VI

    Hello

    I have enclosed below my main vi and the Subvi. In the Sub - VI is a simple timer in a while loop that begins a Boolean button and stops when the time elapses. The problem is that I don't see the value of the clock when the Subvi works on my main vi and I just get the value after the end of the timer. I tried to solve the problem using references, but I can't make it work. According to me, Miss me something. Can you help me please?

    Yes it is.

    And if you read the message 3 in the link I gave, he would have given you this link.  How can I change the changes to a control/indicator a Subvi on the main VI?

    This shows you how to pass the main in sub - VI a VI command reference, so that the Subvi can update it using a value of property node.

  • How to trigger the value change in the structure of the event

    HII everyone, like the title, how should I trigger the value change event to display a message... Here is my connection... I want to trigger structure of the event to bring up the subvi, when the flame and the led are TRUE State... I have using the node property, but still not able to run event structure... How should I connect? Thank you very much...

    There are several ways you can do. First of all, you need to configure your sub - vi while he does everything you want when you run (in the properties of vi, top most window for example) and to make sure that it closes completely when you're done (when you click on the 'OK' button, for example).

    Spend you need an asynchronous call to the subvi. There are several ways to do so. My favorite one below. You go in the palette under 'Application control' and select a static reference VI. I like this approach because it keeps track of the way subvi for you, as long as the subvi is in the same project. Then, drag the sub - vi on the empty square which will be changes to your sub - vi icon. Then, you connect to an invoke node in the same palette under and select run VI. "Wait, that 's" set to false and the main VI will continue to function after the start of the vi of Sub. Together "Auto Ref" is the best way to go. Otherwise, you will need to follow the sub - vi reference and shut up yourself when you are finished.

Maybe you are looking for

  • How to join the forum

    I can't find out how to join the mozilla forum

  • How to see which folder iTunes is music?

    I have three files in the file called Music Explorer each with different air in them, so how can I know iTunes to use music with most of my songs in?

  • I can't connect my imesh

    pls. Guide me how to connect imesh

  • Windows Update loop 3 3

    After automatic updates system shows 3 3 0% windows and goes into a loop by restarting itself. I have re-installed Vista, but as soon as I shut down and restart the system, the same problem again. Any suggestions?

  • Word 2000 does not not in Vista

    After you download SP3 for office 2000, used the optimizer and cleaner registry Sammsoft. Always get the message no answer in Word. All other Office 2000 programs are working well. Tried other UN and re install several times.