User event draw a graph

I have LV2010 and try to trace a user on a stream event. When the user presses Post Event, the same data gets plotted as X (with the help of the plot-style) in red. See attached VI.

The table has two plots-Num and event. The plot of Num is a 1 second plot continues to random numbers. The second plot is an event of conspiracy with (line X-style plot) and drawn only when the Post event is pressed. The x-axis of the waveform is set for minutes.

The problem is, when the event Post is pressed, all the data points are highlighted with X-style plot and I want data that a single point at the time highlighted with X-style plot.

Please help and thanks in advance.

-ipc

A version that does what I think you want is attached. The waveform of the event has a point added each iteration, but the value is NaN (not a number) unless the button is pressed. These points with NaN value will not appear in the field, only those with added values when the button is pressed.

Richard

Tags: NI Software

Similar Questions

  • How to check if a user event is registered before you destroy?

    I have a number of screws running asynchronously each registrant to manage a common user event. During the shutdown, each of these screws is unregistered for this event. Now I want to destroy the event.

    Or reference material on user events recommends I wait that all event handlers are registered before destroying the event, and I would like to do this way, even though the waiting may not be necessary in a situation of judgment (suggested in another thread of discussion).

    So my question is: how to check if a user event is canceled completely before I have destroy it?

    In other words: is there a way to see the event handlers registered how a given user event has? I am currently using this VI (see below) to track the number of registered event handlers:

    (let's call it with + 1 when you register a handler,-1 when the cancellation of registration). However, it feels like a hack, and I wonder if there isn't a more appropriate way to do so. Ideally, a sort of built-in? This looks like something that LabVIEW would need to keep track of...

    Thanks in advance,

    -Kevin

    Kevin,

    I looked through a documentation to verify whether or not a VI as it exists and unforunately library VI does not contain a means for the user to track the number of events. If we had a VI in the library with the functionality you're looking for it would probably work very similar to your under the hood.

    -Nick-

  • Draw two graphs, a simple graph

    Hello.  This is my first time using the command and the simulation.  I want to draw two graphs in one graph.  It seems that I have to use together and to build tables functions but I don't know how to draw them.  The points x and y (2) are only defined by a single set of points included in the defined table.  The points x and y (1) are the results of another formula, but the two parcels would fit in the same location in a single chart.  I hope that my question is understandable.  I attach a portion of the model I want to be plotted.

    Thank you

    Hello

    You can try something like that. Check the attached VI.

    Kind regards

    Amine31

    (Give congratulations to good answers and Mark as a Solution If your problem is resolved)

  • Best practices for user events

    Hey there,

    So I just started to work on projects of LabVIEW on an 8 months (taking my CLD next month) and I'm at the point where I really want to make sure I have make proper design decisions in my program. When I heard tails/user events I have initially just used them all willy nilly like. Now, I'm actually designing a large enough program from scratch and want to make sure to take good design decisions.

    So basically I'm curious, user events should be used to pass data between the parallel loops? Or should use them only for the 'events' that is just to inform the other loops that happens things? (I think too far in all this?)

    Thanks for your help.

    Paul

    You can still use the method that you use only parallel to store data in a shift register store it in a driving force. It is a separate VI which is used to store the data. Dump your data usage of vi and vi we you call data.

    This is how we do it.

  • Need help with user events

    I have an initialize VI where I create a number of user events.  Originally, these consisting of a number of different types of data and have been released as a cluster.  However, I had to change this to an array of variant, as I'm indexing later user refnums in a loop FOR to generate a Boolean matrix of the conditions-based events.  As I'm unable to elements of a cluster index, I have all types of event data changed to variants so that I could pass them on in a table that could be indexed.  It seems, however, that the labels property that populate the structure of the event with the names of the individual event to select from are lost during the use of variants - the structure of the event shows that multiple instances of

    : User event

    in the drop-down list.  Is it possible to get the event names to persist or pass them in the structure of the event, so I can configure cases properly?

    It seems so the VI changed with the data types variant event works, but for some reason, the structure of the event did not update to reflect the changes.  After removing and recreating the event record Refnum indicator in my VI initialization and recharge the parent VI, everything seems to work as expected.

  • VISA waiting on user event

    I have a producer/consumer program that uses an event Structure to manage the keys of the user interface.  I want to be able to use the VISA waiting on the event to read the characters of the RS232 port.  So I created my structure of the event a case for dynamic user events.

    I also create a while loop that has the VISA check and VISA waiting on event inside. I activated the "Serial character" event only.  When I get this event I use the create user Event.VI and the register of events to get an event Refnum

    How the Refnum of the event of this loop in my loop of producer?

    Paul_Knight_Lockheed_Martin wrote:

    Here is the code

    No, this isn't the code. It's a Subvi and a photo. Where you await events VISA? When you generate your user event? Based on the image you call the Initialize_Controller_Communication and remaining in this code to stop buuton is pressed. You start your event structure in the loop from the producer to the end of this VI. So, if you are not hitting the stop button to complete your initializtion it is no wonder that you never see your event executed structure.

  • How to pragmatically set the name of the user event?

    In LabVIEW 2010, I register a user event during execution by using the function of events Reg, but I want to put the name of the user event, according to the runtime. LV said "If wire you a cluster at the entrance to the data type of the user events , LabVIEW uses the type name of the cluster in the event user name." But I need set the name of the event based on the data that is generated during execution.

    How can I pragmatically set the name of a user with data from cluster event at run time?

    I can do this by changing the text of the label of the bunch before I use Reg events function?

    How will I know what name the user never received?

    Thank you.

    I found a viable solution. I can create a user with a name known event. The event that is sent with the event data will include a Source DN string that identifies the sender of the event. The event handler can then handle each event based on the name of the Source. This is equivalent to have several unique named events, is only right they all share a common event data format, which is OK in my case.

    It works very well.

    THANKS for all the suggestions.

  • Worth the user events until the structure of the event runs?

    If I create and enter a user event and immediately generate this event before that my structure of the event has seen the refnum inscription, is the event that is always guaranteed to be seen by the structure? In other words, events are queued to the top? It works, but I wonder if I can count on it. I am very sure that I can but I'm setting up a production code and want to be sure that I do not take just the benefit of a bug.

    A picture is worth a thousand words.

    To my knowledge, the registry for event creates the queue. This behavior is always the same in 7.1, so don't expect to change.

    I think that there was a recent discussion on the lavas on that, but I did not.

    Felix

  • Error 1 to generate the user event

    I have a master/slave VI tester to evaluate the functioning of a Global functional error which should gather errors are generated in each loop.  I get 1 error: invalid parameters to the user events VI generate in the FG of entry error and do not know why.

    I enclose my (LV 8.5) shots of screw and screen, because I think that images would explain better than words.  I have documented the code to indicate what should happen and what is happening.

    Please let me know if you need more details.  Thank you! Your help is appreciated!

    ~ Kristen

    In the case of initialization of your VI main, you're going to initialize the FGV Subvi error.  But you can't give the refnum of user events to store in the shift register.

    When you use this FGV later, it uses the empty refnum into the shift register and sends that to generate the user event, and it gives an error.

  • Problems after editing a Subvi containing a group of dynamic user events

    Hello

    I like the dynamic events in graphical interfaces as a means of code reuse. But this can lead to recording a lot of dynamic events. To handle this, I have a Subvi, which saves them for me. A typical looks like this:

    Can I use it something like this...

    The first time I do it, it works really well and keeps my code (relatively) pad. The problem that I have met a few times is changing the Subvi. Suppose I have add a new event. Now my "Event Registration refnum' and 'User events' cluster outputs are broken. No problem: remove those, create new ones, bind them to the output terminals. Fine. Now go to the appellant. Maybe I again to clear some unwanted and rewire here and there due to type definitions. Cool, actually. Regard to the block diagram is, that everything will be OK at this stage; There is no broken wires. However, there always pesky errors saying "generate the user event: contains terminal unwired or bad.

    It's obviously some kind of conflict def guy in a mask. I'll generally through the entire schema tearing wires, knots, generate screws of user event, event loops, cluster unbundlers, works. So I have this code all back in hand. This arrow always gray. I'm going to compile mass once or twice. Still a no-go. Make a new VI and copy the code in there. The same problem.

    I have encountered this problem several times and don't think I've ever hit to the solution. Finally, I just go back to before the changes and give up.

    Any idea what's going on? How to get it out?

    Thank you

    Nick

    The error is because the Terminal event data are left not connected to generate the user event which is Terminal type required: https://zone.ni.com/reference/en-XX/help/371361H-01/glang/generate_user_event/

  • Check if the user event destroyed?

    Is it possible to check if a user event has been destroyed or is even active before you sign up?

    For example, if a structure of the event is registered to a user event - the event user gets destroyed time of execution, is there a way to recover/get an error in the case where the structure existing by the user event that he must wait for no longer?

    See you soon

    Use the built-in in the range of comparison ' not a number/path/Refnum?

  • VI does not have dynamic user event

    I have several screw running in parallel. I want to instantly communicate a VI data to another.  I am trying to achieve using user events.  All my screws share a dynamic event via a global variable reference.  When I run the event user a VI, about 80% of the time it is received correctly by the other VI.  The other 20% of the time, the event is not received, and the data is transmitted as planned.  Here is some information on the screws that make the transmission and reception:

    Transmission of VI: front is open, no activity happening on the Panel, no calculation happening.  After I sent the user event, the event loop goes to the waiting state.

    Recieviing VI: front is closed, any activity that happens.

    What a bad way to pass data from a VI to another?  I don't like the use of global variables because you need constantly query variables and you can run in race conditions, but maybe it's what I do.  Does anyone have experience using the user events to pass data between the screws?

    j_osh_o wrote:

    Then I do a registration Dynamics refnum and record worldwide.

    This is most likely the source of your problem. The documentation do not insist on this point (and LV does not apply it), but you should NEVER share event reg refnums between the structures of the event. Each structure the event must have its own reg for node events or your events will go away, as you saw.

    As long as you remember this rule of thumb, the architecture you are using must be fine, although I would usually avoid putting references in globals. You seem to have got a few percautions (high level VI opens to them, made sure to write before running the readers as a writer), so it will probably not break for you, but still.

    Anyway, as others have mentioned, there are also other means of transmission of data between screws autour

  • Adding user events

    I have two screws that two raise user events (in the real application may have multiple events, can be added in the future). These screws must be independent of each other to be reused under source code control, so I like to keep a generic if possible solution. When I wire up one after another, the structure of the event only allows me to generate events user to one of the screws (a final) and not from these two subVIs.

    No elegant workaround solution?

    Hi jcurl,

    here a solution for you.
    You have over the "user event on" to the connector pane.
    Then, you can use the node 'Register of events' in your main vi.

    As an attachment, there is a screenshot and set the example.

    Best regards

    Mencef

  • confused by Create User Event

    I have not done much user events.

    According to the help of LabVIEW,.

    The entry for the function Create User Event is an individual item or a cluster whose name becomes the name of the user event, and whose data type defines the type of data for the event.

    In VI I inherited, the original programmer has a cable of a cluster error (no error) in the event user create.

    What does this do?

    NYC says:

    What does this do?

    Allows someone to send error information using a user event.

  • VI, Structure of the event - script user events

    Hello

    I'm writing a VI script, which will focus on a structure of the event in another VI and fill the event with registered user events connected to the dynamic Terminal structure.

    I use the 'SetHandledEvents' invoke the node and the wiring to the terminal of dynamic events.

    In my example VI, I created 3 num event user, Boolean, and string. I can right click and add the event very well to the structure of the event. Now, if I remove any of the event and run my script I can add a dynamic user events. If I change the number of gegistration event from 1 to 2. I get error 1. The case of the event is created, but it is not configured for any event.

    Any help would be greatly appreciated.

    My test images vi showing events three user sign-up.

    Attached is the VI containing my script.

    Thanks in advance

    KeV

    The user 1 problem script error event should be fixed in LabVIEW 2016. DQMH did a lot of event scripts, but it cannot automatically configure event framework names... the user must do this manually for now.

Maybe you are looking for