trigger several events to user in an architecture of producer/consumer

Hi all

I use a producer/consumer architecture, where the case within the property are selected with enums sent via a queue.

Enums are queued in the producer, which is a Structure of the event inside a While loop. Then each of the events in the producer is associated with a case in the well (to make it easier).

Now I would like to run several events in the producer, programmatically in a given sequence. The events involved in the sequence are basically all triggered by changing the value of a Boolean value (button).

Please find attached a schematic representation of the sequence, I would like to implement.

I heard of 2 solutions:

-"Writing to the node (Sgnl) Value property of the variable [I] want change."

-Dynamic user events

In any case, I don't know how to make sure this is done for several events in a specific sequence?

Thank you.

Florian


Tags: NI Software

Similar Questions

  • Trigger several events to a dynamically saved value of signage

    I have different controls for some pumps.

    I want to stop all with an emergency stop button.

    I use the event Structures to manage the user controls.

    In the previous version of my code, I register all events statically in the same vi. But to make the program compact and modular, in the attached version of the code, I use the references to the controls, and I go to a Subvi. In the Subvi I record the events of these references and I link the "event recording refnum" to the terminal dynamic events of the Structure of events.

    Everything works with the exception of the emergency stop.

    I can't use a reference of the emergency stop button to trigger the event, because the emergency stop opens the other files in vi for further confirmation from the user.

    When the emergency stop is confirmed by the user, I use the value property of a signalling to trigger the event stop of all structures event of the subgroup on the screws that control the pumps.

    Previously, I had only a single value of signage to trigger several events, but I saw that I have create the condition of critical competition and the Structure of events first, which handles the event, removes it from the queue, and other Structures of the event can't get the event.

    So, I use as signals of many boolean value pumps as much as I.

    But it does not always raise all events.

    Another detail, it is that I do not use the "Unregister for events function" in all the screws under that have Structures of the event. I saw no difference with this function, or without him...

    Apparently, Miss a clue of a general principle of LabVIEW.

    I join all of the template project.

    The main.vi starts the program.

    The problem of this thread is re-posted more clearly and it is resolved here:

    https://forums.NI.com/T5/LabVIEW/static-vs-dynamic-events-some-dynamic-events-are-flushed/m-p/318239...

  • Architecture feature producer consumer

    I was wondering if the loop of consumer in a producer consumer architecture works only when the loop of producer send him something, or he still works, even if it receives nothing from the loop of the producer?

    It depends on how you put in place. If you do not have a timeout on the dequeue, he'll sleep until he gets a message. If you have a time-out, it will run if the value of timeout is reached.

  • Programmatically change the number of producers in an architecture of producer/consumer

    Hi all

    I've got 3 momo SoMat I am streaming of data to 10 Hz. I plan on 3 producer loops and loop a consumer to treat.

    I am pretty sure when I show my customer that they want to increase the number of devices. This scuppers then the producer/consumer model unless I change by programming the number of producers and the rest of the architecture associated.

    Is there a way to do this or a better architecture?

    Phil

    As long as there is an ID any in your command of the queue, I do not see why your consumer cannot handle the producers as much as you need.  I would turn the producer code in a Subvi.  Make sure reentrant Subvi.  Then, you can call dynamically that VI as many times as you need, one for each instrument.

  • Is the reference of the register of necessary shift in architecture of producer/consumer?

    Hi guys,.

    I was just wondering if the producer/consumer architecture is necessary register wired shift to the reference of the queue or the notifier. Is this necessary?

    I think that it isn't, because it's quite a tunnel but could anyone who thinks that the shift register is necessary, explain to me why it is necessary?

    In each of the samples I found the reference to the queue or the Notifier is connected to a shift register, I tried to wire it to a tunnel and it works well, then, what is the best implementation?

    Thank you in advance.

    Thank you guys for your quick responses...

  • Several events triggered by a change

    Hello

    Now trigger several events with changing a field to single user. In Lookup.USR_PROCESS_TRIGGERS, I have defined the field twice and associated with two different events. My search looks like:

    Key code Decode
    USR_FIRST_NAMEChange of name
    USR_FIRST_NAMEChange of name
    ......

    It works perfectly, but it seems that the duplicate key of Code to randomly disappear after awhile, leaving me with a single entry for USR_FIRST_NAME. Is this normal? Is there another way to make a single field 2 events fire?

    Thank you

    -jtellier

    You're hurting.  You should have that key in code duplication.  Here's what you can do however.

    Key = USR_FIRST_NAME code decode = change of name

    Now on your definition of the process, as long as the task starts with "change of name" you can add as many instances as you want.  You can create the following tasks and they will all trigger:

    Change of name

    Change of name - full name

    Change of name - display name

    Change of name - Email address

    Just the first part of the questions.

    -Kevin

  • Error of timing architecture producer/consumer

    Hello

    I use architecture of producer/consumer for the acquisition of measures of constraint by using several channels. Also, I am interested to write data all 1 minute given that the program should be run for a month. Currently, I get a 200279 error whenever I increase the time of 10 sec. To control the execution of the loop of producer, I use 'weight up to the next multiple ms' function. According to the error message, I tried to fix the samples to read without increasing the frequency of data acquisition, but I still get the same error.

    Thank you

    Piyush

    Your test3.vi was not included, so we do not know what is happening there.

    What is the rate of acquisition for your data acquisition task?  DAQ hardware do you use?

    Have you tried to increase the size of the buffer?  There is a property node that can define it.

  • Instead of using the structure of the event with the producer consumer?

    I used the architecture of producer-consumer in the past to control a state machine with the structures of the event.  I'm working now with the basic version of LV that does not include the structure of the event.  Can anyone recommend alternatives to the use of the same architecture in this case?  Thank you, David

    Before the introduction of the structure of the event, the only option was the election.  Control terminals are in a time loop (the producer) with shift registers and a wait, usually about 100ms.  At each iteration of the loop, the control's current value is compared to the previous value.  If it has changed, and then take appropriate action.  Andrey suggested, queues are a good way to pass information between the loops.

    It works for the equivalent of the value change events.  Things like mouse to top or filter events were much more difficult or not possible.

    Lynn

  • HP Pavilion p6 - 2220t: HP Support Assistant update 11/20/2015 causing several event ID 3 warnings

    HP Pavilion p6 - 2220 produced t NumberB3F79AV #ABA

    Windows 7 Home Premium 64-bit Service Pack 1

    Windows Firewall and Microsoft Security Essentials

    HP Support Assistant 8.1.40.3

    HP Solutions Framework 12.0.30.219 Support

    Since HP Support Assistant updated on 20/11/2015, which has also updated HP Support Solutions Framework on the same day, I get several event ID 3 warnings in Event Viewer on my Pavilion Desktop.  Everyone can repeat 2 or 3 times when the computer is started or wakes.  There are 66 warnings until 6 days.  All come from HP health Active.

    Log name: Application

    Source: HP health Active

    Date: 25/11/2015-22:48:55

    Event ID: 3

    Task category: no

    Level: WARNING

    Keywords: Classic

    User: n/a

    Computer: PC - 1

    Description:

    COM exception running a command GET Casl Diags.PostCodeError = [NO SPECIFIC CASL = 0 x 80041002]: Exception from HRESULT: 0 x 80041002

    ****************************************************************************

    Log name: Application

    Source: HP health Active

    Date: 26/11/2015-05:06:13

    Event ID: 3

    Task category: no

    Level: WARNING

    Keywords: Classic

    User: n/a

    Computer: PC - 1

    Description:

    COM exception runs a command EXECUTE Casl Diags.ThermalDiagnostics = [NO SPECIFIC CASL = 0 x 80041002]: Exception from HRESULT: 0 x 80041002

    ***************************************************************************

    Log name: Application

    Source: HP health Active

    Date: 26/11/2015-05:05:36

    Event ID: 3

    Task category: no

    Level: WARNING

    Keywords: Classic

    User: n/a

    Computer: PC - 1

    Description:

    COM exception running a command GET Casl EmbeddedController.AuditLog.JSON = [NO SPECIFIC CASL = 0 x 80041002]: Exception from HRESULT: 0 x 80041002

    I know it's just a warning and it doesn't seem to affect the performance of my computer that I can say, but I would like to know why it's happening.

    Well, I found the task that updates HPSA in Task Scheduler.  I disabled it by using the Properties window.  On the chance someone may be interested, I'll post how it turns out.

    I hope that I can now keep the HPSA listed for my computer with no additional alert to update again HPSA that generates several warnings and is not compatible with my desktop computer Pavilion p6 - 2220t and/or Windows 7 sp1 64-bit operating system.

    This disabled the HPSA update only not any other.  It seems to be a standalone update for HPSA.

  • Structure of the event without user interface

    I tried a quick and effective solution for a structure of event that is not a case of timeout and is part of a vi that has no user interface, but I have sent configuration data to the structure of the event.

    Let me be more clear: I have a camera that generates several events taken by a loop with the structure of the event inside.

    The provider of the camera give me this example of Labview code with all the events I'm interested and how they are implemented. I should mention that when you write a command of camera that a response to an event, but when you connect first to the camera there are more than 100 events generated by the latter, or when you download camera there are also several events. When there is no communication to the camera, the structure of the example event is inactive. The example includes a user interface to change settings and the program responds very well.

    I have to integrate this camera in great demand in which camera photo will be configured in a pragmatic way with number of the type of user interface in the example given by the manufacturer of the device.  First, I tried to design a loop with timeout cases in which a queue can send the data to the device setting configuration. Everything is good until the download when code needs to hold events in a certain way; in my case, an event is taken another goes to the time-out period and so on. After two sets of 100 images download, during the third round Labview gets blocked (Labview not responding) and I have to kill Labview. I got designer of the camera that if camera events are not taken they are kept on a pile and when the battery is full causes the Labview locked.

    Maybe I give too many details, but the question is: how to communicate with a struct event that is not a case of timeout and does not part of a user interface vi (it doesn't have a sign in my application)?

    Oops... Sorry about that.  I've attached an example what I'm talking about here.

    -Austin

  • Need help with the events of user base in state machine example in queue

    I wrote a small example queue state machine to try to teach myself about the creation and use of the user events.  The purpose of the machine is periodically pick a number (I do now with a control instead of a generator of random numbers for troubleshooting), and compare this figure with the number I put in a control.  When they match, I want to raise an event to fire so I can do something about having found a match.  The examples in the file LV references help show events within the structure of the event, but I want to reach out of a State and trigger an event...

    Can someone point me in the right direction here?

    Thank you

    Hummer1

    I think the service you're looking for is generating the user event.  What to put in your consumer loop, inside the case structure when identical numbers.

  • AdfCustomEvent.queue does not provide several events (11.1.1.3.0)

    I created a JSF page in which I use ADFCustomEvent.queue to call a method in a pod of support from JavaScript code. It seems, however, that if several events are queued, method support the bean is called only once. This is expected behavior?


    For example, my JSF has simply a command button. When you click on it, the "clientListener" calls a JavaScript function. This JS function queue of events, and the "serverListener" sends those on the server. (Code example is below).


    < af:document id = binding = "#{"d1"backing_eventtest.d1}" >
    < af:form id = binding = "#{backing_eventtest.f1"f1"}" >
    < af:commandButton text = "events."
    Binding = "#{backing_eventtest." CB1}"id ="cb1 ".
    partialSubmit = "true" >
    < af:clientListener method = "OnButtonClick" type = "click on" / >
    < af:serverListener type = "eventServerListener".
    Method = "#{backing_eventtest.handlePageMessage}" / >
    < / af:commandButton >
    < / af:form >

    < af:resource type = "javascript" >
    OnButtonClick() {} function
    var BTN = AdfPage.PAGE.findComponent ("cb1");
    AdfCustomEvent.queue (btn, "eventServerListener", \{message:"Hello 1" \}, true);
    AdfCustomEvent.queue (btn, "eventServerListener", \{message:"Hello 2" \}, true);
    AdfCustomEvent.queue (btn, "eventServerListener", \{message:"Hello 3" \}, true);
    AdfCustomEvent.queue (btn, "eventServerListener", \{message:"Hello 4" \}, true);
    AdfCustomEvent.queue (btn, "eventServerListener", \{message:"Hello 5" \}, true);
    }
    < / af:resource >
    < / af:document >


    In the method of handlePageMessage of the bean of my support, the message 'Hello 5' only ever comes through. I was expecting sort all 5 events to come through.

    Are my expectations wrong, or is it a "problem"?

    Published by: user614824 on May 28, 2010 09:42

    I guess that your expectations are wrong here. The framework works as expected.
    The doc (5.4.3 what you will need to know the data Marshalling and Demarshalling)

    When you send information from JavaScript to Java, JavaScript data objects are converted (moult) in XML, which is then analyzed back or unmarshaled into Java objects on the server-side. For example, consider a JSF page that contains a commandButton control element whose ID is cmd. When a user clicks on the commandButton control component, the customer must communicate with the server that an actionEvent was triggered by this specific commandButton control. In terms of requestParameter, information is mapped with the key using the format event. + id, where id is the ID of the component. The key to map to the commandComponent requestParameter would therefore be the XML string that is stored as a value of the event.cmd key.

    This part of the documentation speaks of how events are passed to the server. Because an event is placed into the foreground of requestParameter (which is a java.util.map) each of your events overrides that you queued before. You will see then that the last of them.

    Timo

  • the space in the center of the display calendar top of the real calendar no longer displays a list filtered in several events.

    the space in the center of the calendar view top of the real calendar that is used to display a list filtered in several events. This list is now missing. How can I get that back?

    Finally, I noticed a menu item "events and tasks > find Events" with no shortcuts like Ctrl-F, which I tried. That fixed it.

  • Trigger consumer in a producer consumer architecture

    I want to trigger the loop of consumer in a producer consumer architecture, so that it can do what it should do, until he receives something new producer loop.

    Can someone tell me please how to do this?

    Thanks in advance!

    If the Dequeue-1 item timeout entry turns off the timeout.  That means he'll stay there forever until the data is available in the queue.

  • 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

  • I will lose Norto sure identity if I reset Firefox?

    I hate reset Firefox, even if it's slow, that I trust my Norton safe so identity.I just want to confirm that Iwill not lose

  • Re: Satellite P200 - question about the recovery part

    I have a Satellite P200 and a recovery disk. I don't want to use this as it clears my disk clean C: and E: which has all my data on it. Is there a restore button to factory settings which affects the C: drive and let E: in tact? I thought I read some

  • Games with touchpad Z510

    I got my lenovo Z510 for about 3 weeks now, and I'm running into a problem where I can't use my keyboard and use my touchpad at the same time, making it difficult to play games. I are entered in the settings and went to the mouse and paved tactile an

  • custom component buffers corrupt

    Hi, when I try and create a custom through part of hole in ultiboard, created tampons have 2 interiors - in all ready components created by holes just up and down - I do not know what are these interiors. I use the wizard of the part which seems to w

  • How can I transfer my address book from aol to Outlook Express so I can download it for my new IPad?

    I have a new IPad 2 and my address/contact list is in my old Dell Inspiron 5100 running Windows XP and no one has been able to help me get the address list transferred, including Apple.