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

Tags: NI Software

Similar Questions

  • Assistance needed for the installation of windows server 2008 r2

    Hello users,.

    I am new to this technology of the virtual environment and I need help in installing windows server 2008 r2 on a machine virtual workstation. For it so what are the recommended setting for drivers, no. of processors, amount of RAM, type of CISS or sata... etc to give the best performance on my virtual machine. If possible please provide me details to my knowledge.

    Thanks in advance

    Are you sure that you have installed a Windows Server 2008 R2?

    Because the normal procedure is that after the installation, you will get a prompt to choose an administrator password. Once you are connected.

    There is no additional user created during installation. This only happens when you install versions of Windows desktop.

  • Assistance needed for the scaling of image 1024 x 1024

    Hi all

    I did a VI where I load a 1024 x 1024 BMP file. The BMP is generated by an another VI which is to get a picture of a videostream of my webcam. The raster image gets so grayscale for further processing. My final goal is to make a LV facerecognition

    So when I load the grayscale image I get nothing, but if I use the version 512 x 512, so, I'm able to evolve without any problem.

    I think it's sort of a problem of overflow, but I can't solve...

    Thanks in advance

    24-bit image data are an ara of U32.  If you change the entry in the function Array initialize as a U32 instead of a U8 it will work as long as you notice the depth of the image and use the correct entry to flatten Pixmap.vi.

    I have attached a version that seems to work.

  • How do I not what SATA driver do I need for the Satellite L300 - 03C

    How do I not what SATA driver do I need for the Satellite L300 - 03C so I can make nlite

    Hello

    Your laptop seems to be a Satellite L300 - 03C PSLB8C-03C01X.
    As already indicated on your first visit to thread the Toshiba Canada page and choose this model of laptop on the driver page.
    http://209.167.114.38/support/download/ln_bymodel.asp

    Then download the Intel Matrix Storage Manager (SATA) - image of floppy drive. It of for Vista, but the files in this package should work with Win XP too.
    Include these files using nLite to create the new disk Win XP that contains SATA drivers.

    Finally use this disk to start.

  • What USB 3.0 card is needed for the HP Pavilion 6370t?

    What is needed for the HP Pavilion 6370 t USB 3.0 card?

    Hi Fasteagle,

    HP sells USB 3.0 PCI-E x 1 cards.  I have one in my HP e9280t.

  • DVD how much we need for the files backup with backup and restore program?

    Hello how are you?
    DVD how much we need for the files backup with backup and restore program? Y at - it large differences in the time and space between write backups on DVD and external hard drive?

    I do not understand your question.  Asked how the space has been used on your C: drive and you answered 60 GB.  Now you say your PARTITION C: is 60 GB with only 20 GB used?  I really don't understand what you're so confused.  It's simple arithmetic grade 3rd.  What is space you USED on the C: drive, that multiply by 0.7 to obtain the amount of space will be used on your backup disk after compression.  Divide this number by 4.7 and round.  That's how many DVDs you'll need if you insist on the use of DVDs for backup.  Then

    (1) If you are using 60 GB, the answer is (60 x.7) / 4.7 = 8.936.  I rounded up to 9 and added 1 just to be sure.

    (2) If you use only 20 GB, the answer is (20 x.7) / 4.7 = 2.97 rounded up to 3.  Add 1 and get 4.

    If you use only 20 GB, I am very surprised, because almost any important installation of Windows 7 is going to take more than 20 GB.

    All of this assumes that you do NOT use the Windows backup and restore program, but one that I recommended.  When I used the windows one, the results were several times the space that I used on my C: partition.

    Good luck.

  • replace my keyboard (ez4805US) and the need for the tech manual...

    I need to replace my keyboard (ez4805US) and the need for the tech manual... where can I find a...

    Welcome to the HP Forum!

    docwho wrote:

    I need to replace my keyboard (ez4805US) and the need for the tech manual... where can I find a...

    If you really want the manual, I think that would help to identify your laptop with full p/n.

    Identify the same way I did in my signature with the full p/n, alphanumeric included acharcters.

    Kind regards
    ERICO

  • How to make a paper with some boxes to fill required for me to sign, and then some other boxes needed for the next person to sign. I want the boxes I've filled to be locked the next person.

    How to make a paper with some boxes to fill required for me to sign, and then some other boxes needed for the next person to sign. I want the boxes I've filled to be locked the next person.

    Hi johanb64152807,

    You can use eSign service, where you can send the document for signatures of several signatories, but the document will be sent to the following signatory after the earlier signed & it is not possible for him to make the changes.

    Documents KB for help: -.

    Kind regards
    Nicos

  • I can't get the file number I need for the license transfer process. Help, please.

    I can't get the file number I need for the license transfer process. Help, please.

    To the link below, click on the still need help? the option in the blue box below and choose the option to chat...
    Make sure that you are logged on the Adobe site, having cookies enabled, clearing your cookie cache.  If it fails to connect, try to use another browser.

    Get help from cat with orders, refunds and exchanges (non - CC)
    http://helpx.Adobe.com/x-productkb/global/service-b.html ( http://adobe.ly/1d3k3a5 )

  • Need for the intelligent algorithm

    Hello!!!

    My problem is:

    I have a string of characters composed by a name and two surnames...

    Example: "Maria Gomez Fernandez".

    And I have an array of strings:

    "Maria Fernandez Gomez"
    'Maria Fernandez2 Gomez'
    "Maria Gomez Fernandez '"
    "Maria Gomez. Fernandez; »
    etc...

    I need an algorithm to search for the string "more similar" table with my thong.

    Upper/lower case differences can be ignored as well as special characters (&, / $, "!") _ )...

    You know an implemented pl * sql routine to achieve this goal?

    Published by: pacoKAS on 23 / dic/2011 19:23

    Maybe it's
    http://docs.Oracle.com/CD/E14072_01/AppDev.112/e10577/u_match.htm

    May not be available in your version, but we do not know because you share that information with us :(

  • When you use a left and right axis, how to choose what issed axis for the value of y GetGraphCursor?

    I use a graph with a left and right axis (2 data sets).  I try to use a slider to select a point in time (x) and the values of y in the two sets of data.  I can't understand how the control, the value that is returned for the value is when you use the GetGraphCursor call.

    GetGraphCursor (panelHandle, PANEL_GRAPH, yourCursorNumber, & x & y)

    Using SetCursorAttribute with the attribute ATTR_CURSOR_YAXIS must be what you are looking for. The online help for this attribute explains wery well:

    Description: Used to change the y-axis which is associated with the bar graph.
    When a graphics cursor is created, the Y axis with which it is associated is determined by the value of ATTR_ACTIVE_YAXIS.  Subsequently, the association can be changed using ATTR_CURSOR_YAXIS.
    The y-axis associate serves as reference for the coordinates of the cursor position in calls to SetGraphCursor and GetGraphCursor.

  • How it warns Oracle to use an index for the join of two tables...

    How to prevent the Oracle to use an index for the join of two tables to get a view online that is used in an update statement?

    O.K. I think I should explain what I mean:

    When you join two tables that have many entries sometimes there're better is not to use an index on the column that is used as a criterion to join.

    I have two tables: table A and table B.

    Table A has 4,000,000 entries and table B has 700,000 entries.

    I have a join of two tables with a numeric column as join criteria.

    There is an index on this column in A table.

    So I instead of
      where (A.col = B.col)
    I want to use
      where (A.col+0 = B.col)
    in order to avoid Oracle using the index.

    When I use the join in a select query, it works.

    But when I use the join as inline in an update statement I get the error ORA-01779.

    When I remove the '+ 0' the update statement works. (The column is unique in table B).

    Any ideas why this happens?

    Thank you very much in advance for any help.

    Hartmut cordially

    You plan to use a NO_INDEX hint as shown here: http://www.psoug.org/reference/hints.html

  • Setting the value of a table of ActiveX control

    When controling a VI through ActiveX, how is possible to set the value of a table control?

    With digital controls, I have a problem: I just use SetControlValue and it works well:

    til SetControlValue ('y', 4) for example.

    However, in trying to do the same thing with a table, the control's value becomes an empty array:

    til SetControlValue ("arr', [3-4-5]") for example.

    What is the right way to do it?

    Hi Calvin,

    Have you tried passing a string and convert it to an array entry?  You can also try to use a 'matrix' control, rather than a table, as they are handled a little differently.

  • Alternative to obtaining the value of a table

    Nice day!

    I am new to the forum and Oracle (<-SQL Server Dev), I would like to know if there is an alternative to get the values in a table. I would like to avoid catching an exception if there is no data found especially and always continues with it.

    declare
    number of v_number;
    Start
    Select code in v_number from someTable where id = 1;

    -I still want to continue despite no data
    If v_number is null then
    -do something
    v_number: = 1; -1 initialization

    end if;

    -Continue normal processing.
    -other codes

    end;

    Thank you

    Welcome to the forum.

    Read about the MANAGEMENT of EXCEPTIONS like NO_DATA_FOUND.
    See: {message identifier: = 9360013}

    And of course the docs @ http://www.oracle.com/pls/db112/homepage
    http://www.Oracle.com/pls/db112/search?remark=quick_search&Word=exception+handling

  • How to load the values into a table?

    In my jspx page, I have a combo and a table... Based on the values of the drop-down list, when I click on a button, I want to load the values into a table... The data in the table are from 5 database tables. I created a viewObject readonly... What to do to load the values from the table, I click on a button?

    Ensure that you have defined a variable to bind your view object.

    Read-only or not, this is what would make the Execute with action of parameters available.

    John

Maybe you are looking for