Queue function re-enterant

I have a producer consumer with multiple consumers. Each consumer has its own queue. Say three consumers. I am using a que library where obtain queue, enqueue, dequeue are all wrapped in upper level functions.My question is should these wrapper VIs needs to be re-enterant? TIA
CLD,CTD
Solved!
Go to Solution.
Attachments:
Queue.jpg ‏108 KB

MainVi.jpg shows how data is passed from UIR loop to other loops.
The image attached as "AnotherThread.jpg" different queue are used to enqueue and send data to other loops.
Can the same wrapper marked as shared clone be used across each queue and can still create separate queues? Or should there be different wrappers created, one for each queue?
CLD,CTD
Attachments:
MainVi.jpg ‏185 KB
AnotherThread.jpg ‏159 KB

Similar Messages

  • Simplified Queue functions

    The one problem with using the Queue functions is that they are all primitives. With that in mind MK and myself developed a Queue handler API that incorporates the primitive functions - as well as more advanced functions into a polymorphic VI.
    We hope this improves your Queued State Machine experience.
    Visualize the Solution
    CLA
    LabVIEW, LabVIEW FPGA
    Attachments:
    Queue API.llb ‏404 KB

    VADave wrote:
    We also used to use enums but to make a generic Queue handler we had to adapt to strings.  We chose not wire the errors into the primitives so that an error generated in elsewhere by the code will not impact the operation of the Queues.  
    The main code error cluster is routed to the error cluster of the Queue handler so that we can trap on any error and redirect the queue to the error case. The error trapping is done be the Queued Error handler.vi which is placed to the left of the program cases.
    In the Error case we look at the Queue element to tell if it is a programming error - misspelled string, missing case etc. or a genuine error from the program. We felt that there is a negligible chance for a Queue error since only the Queue handler vis interact with the actual Queue.
    Could you share an example of your main code to illustrate the use of your VIs and what you are describing here. I've been working on a very similar set of VIs to publish on DevZone as a reference design/design pattern for this purpose and at the ame time clean up/consolidate the myriad of different implementations currently posted on DevZone.
    I agree with your use of strings for the queue element to make the tools more reusable and digestible by less experienced LV users, though using a unique TypeDef Enum and associated library to manage the queue for each application would be stronger SW design. In some cases I think it is appropriate to choose ease-of-use over robustness.
    Christian Loew, CLA
    Principal Systems Engineer, National Instruments
    Please tip your answer providers with kudos.
    Any attached Code is provided As Is. It has not been tested or validated as a product, for use in a deployed application or system,
    or for use in hazardous environments. You assume all risks for use of the Code and use of the Code is subject
    to the Sample Code License Terms which can be found at: http://ni.com/samplecodelicense

  • I am trying to use IMAQ acquire and other IMAQ functions with Queue functions.

    i am trying to use IMAQ acquire and other IMAQ functions with Queue functions.
    i mean i would like to acquire the image in a queue and deque it afterwards. would be the queue function accept the IMAQ data type?

    Refer posting, http://exchange.ni.com/servlet/Redirect?id=8879554

  • What is the purpose of queue functions?

    well what is the relation of queue functions of Labview
    and queuing theory, like MM1 system MD1 system etc.
    thanks

    Others may have a better explanation and example, but I have found that queues in LabView are very useful when you need to transfer a lot of information quickly and want to make sure you don't overflow or drop elements. They are better at this than using variables because the writer can keep writing whether or not the reader has read the last element. 
    For instance, recently we were trying to record data on a cRIO device and get the fastest rates possible. We were recieving data from the FPGA FIFO and writing directly to file. When you try to record 32 channels of 32 bits/element at 1 kHz you begin to test the limits of your write to file function. Queues worked better than variables for this because every so many cycles the write function would sort of hiccup and pause, causing the elements in the queue to increase (backup). If we were using regular variables we would have had to wait for the recording to catch up before we could continue reading data. This would mean we would be overflowing the FIFO or missing data points. However, with a queue, elements could back up a little and then the record function would catch up. (As a side note, write to binary file worked faster than TDMS in these benchmark experiments.)
    Can anyone explain it better?
    [will work for kudos]

  • How Queues functionality helps in Service Module

    Hi,
    How Queues functionality helps in Service Module.
    how to get the queue details assign to the service call(Technician)
    Please Suggest
    Regards
    Vikram

    Sridharan,
    How to add technician to a queue.
    Employee should be user of SAP?
    Please Suggest.
    Vikram

  • Enum edits break queue function

    I am using an enum datatype with a queue to create a data manager
    subvi. The problem starts when I add items to the enum: all the wires
    to the queue functions break. I understand that I changed the datatype
    and that the queue functions are some kind of polymorpic functions that
    adapt to the datatype you wire to it. What I would like to know is how
    I can easily make the queue functions adapet to the new datatype. Or
    should I fall back to strings instead?

    Hi Aart-Jan,
         It looks like CHAOS has a solution!  Oh well, for what it's worth...
          I coded this (attached) under 7.1, used a strict (simple) enum bundled with variant, but was unable to reproduce the problem.  I've experienced odd behaviour related to type-def ambiguity at the output of case structures, and where shifted value is supposed to determine type in other cases.  I'd try, instead of deleting/replacing the queue operators, deleteing/re-wiring, forcing shift-register to use queue-type from case shown.
    Cheers,
    D.
    Message Edited by Dynamik on 09-14-2005 04:24 PM
    When they give imbeciles handicap-parking, I won't have so far to walk!
    Attachments:
    quetyp.llb ‏20 KB

  • Can the same partner function be entered in the sales order more than once.

    Hi
    I know that as per standard same partner function cannot be entered more than once in Sales order.
    If somebody has tried ways to do this please share.
    THanks
    Alags

    Yes. You can have multiple Ship to Party, Bill to Parrty & Payer in Sales Order. But Sold to Party will have to Unique & single.
    This functionality of having multilpe Partners is widely used & just follow as Deepak suggested above & you too can have multiple Partners of same type in single Sales Order.
    But there has to be a strong Business case in doing so... say different Ship tp Party for different line items in Sales Order or different BIll to Party for some line Items in Sales Order.
    Hope this helps,
    Thanks,
    JIgnesh Mehta

  • Code to call a function when enter key is pressed

    hi all,
    In a table control program i need to call a function when i press enter key...
    but im not able to do that since the function is always called when i press a push button on the screen.... can any one help me in this.. please....

    Hi John,
          You are not getting any value in SY-UCOMM when you press "Enter",because the function code is not set for 'Enter" key in "Function Key" of the GUI-STATUS..
    First define some fucntion code say 'ENT' for the Enter button available in "Fucntion key" of the GUI status.Once you done and activate the program and test it.The function code which u defined will be coming to SY-UCOMM field when you press 'ENTER" button and you can handle the various fucntionality whichevcer you want on "ENTER" .
    Eg:
    case sy-ucomm.
    When 'ENT'.
    Endcase.
    Regards,
    Vigneswaran S

  • Planning function "Allocation" - enter or upload distribution keys via web

    Hey all
    We want to use the planning function "allocation" and want to find out, if there is a possibility to enter the distribution keys for that planning function either over a web interface or by flat file upload.
    The idea is, that all companies over the world (sender) can maintain their distribution keys (can change every month) themselfs.
    We are actually using "BW-BPS 3.5"!
    Thanks for your help.
    Roger

    Hi Roger,
              It should be possible to do it. I have come across a similar situation although the planning function in question was "Distribution using the posting keys".
    The layout can be web based where the user enters the different posting key percentages for allowable entries to the different allocation units.
    Then once he saves this, and the entries are validated on the front end, you can use an automatic planning function to activate the posting key settings.You will use an user-exit to achieve this.
    The user-exit basically initializes the original set of parameter group for that function using "UPF_PARAM_INIT",
    for the planning function in question which itself can be found by using "UPF_PARAM_INFO_GET"....
    Once you have done this..then you can set your PGroup settings again from the new values.Here you are taking entries from the web/layout..which are stored as some values in another keyfigure(z_dist_factor) etc...and then use the FM "UPF_PARAM_INFO_SET" followed by a "UPF_PARAM_SAVE" to finish and exit out.
    I think if you read thru some of the code in the above mentioned FM ,...you can easily construct what you want to achieve.Good Luck.
    Sudz.

  • Add functionality for enter and close in a dialogue window

    Hi
    I have a dialogue screen.
    On pressing enter or the enter icon I need some functionality.
    And on clicking the close icon or close(on the dialogue window) i need to exit.
    How to add functionality to close and enter?
    (The icons are functioning properly but Enter and close are not functioning)
    Here is the code i have used
    gv_save = gv_code.
    CLEAR gv_code.
    CASE gv_save.
    WHEN 'OK' OR 'ENTER'.
    PERFORM char_convert.
    LOOP AT object_tab WHERE selected = 'X'.
    UPDATE imptt SET pyear = gv_exponent
    WHERE point = object_tab-point.
    ENDLOOP.
    LEAVE TO SCREEN 0.
    CLEAR gv_annual.
    ENDCASE.
    ENDMODULE. " USER_COMMAND_1001 INPUT
    MODULE cancel INPUT.
    gv_save = gv_code.
    CLEAR gv_code.
    CASE gv_save.
    WHEN 'CANCEL'.
    LEAVE TO SCREEN 0.
    ENDCASE.
    Please help me .
    Best regards,
    Kranthi

    You need to take ABAP help and build logic, so that If so & so condition pick LOGO1
    and for so & so Condition LOGO2 & for rest LOGO3.
    You need to incoroporate the Logic in your program for Script / Smartform.

  • Petition: "Insert to queue" function for creativ

    I would really appreciate such an option in zens. I was disappointed that my micro didn't have it. It might be confused with "add to selected" but it's quite different, let me explain it by an example.
    For instance with "add do selected" i added 00 songs to my selected music. While listening to those songs let's say in shuffle mode(that's i use most), all of a sudden I wanted to listen R.E.M losing my religion, and just after that let's say linkin park-numb. So what I do is although it's in my selected music I enqueue losing my religion as st and numb as 2nd. These songs play and aferwards it continues with other songs in my list. The use of it is I can do it any time I want, i don't need to create a playlist in a certain order each time my tastes change.
    I remember there was such a function in winamp, maybe it was a plug-in or a patch, I'm not sure.
    I guess an "insert to queue" tab in the menu appearing when you tab the scroll pad in the "selected music", would be very useful and I would be very grateful for it. It wouldn't be a hard thing to include in the firmware i guess.
    SSR said Rio Karma had such an option. It would be nice if my zen had.
    So, to sum up:
    I signed for the petition to include "insert to queue" in the next firmware for all zens

    a play next or insert into que option would be good.
    Also when adding music to a playlist on the player, i've found the only wauy to insert a track somewhere is to open a playlist, then add a new track, then go to selected music, if you select change order it wont let you put the new track in the playlist, loaded in selected musis, only at the top or the bottom of a playlist.
    the only way round this is to have just the playlist and the aditional tracks loaded then to save them as a playlist with the same name, it will say "playlist already exists on player overwrite?" save it, then clear the selected muisc, re-load the playlist with the new tracks at the bottom or the top, and then sort out the order.
    save and overwrite the playlist again, and the new tracks have been inserted.
    theres got to be an easier way than that, come on creative.

  • I need a queue function in  itunes !!!!!!!

    Hello
    Am I the only who thinks it is very annoying that itunes does not have a queue funktion. If you want to pick the next song, you have to create a play list to chose what to hear next. So I would love if itunes has added this function to their next version.
    Fillip Dk

    Several people have made this point, but Apple doesn't read thre forums.
    How about putting your suggestion to Apple with this feedback form:
    http://www.apple.com/feedback/itunesapp.html

  • RW_SERVER_QUEUE: Stop Cleanup Queue Function

    How can I stop the rw_server_queue function "clean_up_queue" from running? I don't want all my scheduled jobs lost if I stop/start the report server.

    Jon,
    Thanks for your response. I am running in 8i. Can
    reports be scheduled via dbms_jobs in 8i? I have
    searched the documentation and do not see any
    examples showing how to do that.Yes, you can use dbms_jobs in 8i to schedule a stored procedure. The stored procedure can use util_http to request the report. Look at pr_example below.
    Re: Auto running of Reports

  • Will check RFCs enter RFC queue?

    Hi Experts,
    I have a doubt , if we put a check RFC in an event , and that event gets triggered does the check function module enter the RFC queue( i.e. SM58 )?

    Hi,
    I found the answer. It is not transactional RFC hence does not enter the queue i.e.  in  SM58

  • Enter Functional area in KB31N

    Hi,
    Would anyone be knowing how to bring Functional area in KB31N?
    I don't see the option of adding functional area in KB31N as a receiver in - - -  SPRO>Controlling>Cost Center Accounting>Define Own Screen Variants for posting in Controlling.
    Regards,
    Khyati

    Just a note that I am able to use functional area in FAGLSKF but it does not serve my purpose. CO Distribution cycle is not considering cost center/functional area entered in FAGLSKF.

Maybe you are looking for

  • WebLogic 10.3.5 with Apache Connector Config

    Hi, I have multiple apache/OHS running on the same HP-UX machine and am running into following issue in deploying SOA Processes on the second server. deploy/sca_AIAErrorTaskAdministrationProcess_rev1.0.jar [deployComposite] INFO: Creating HTTPS conne

  • Open Dir, SMB, AFP, Changing Password on first login (Windows)

    Hey all... I've read up on some documentation but have run into a roadblock trying to set up file sharing for Open Directory user accounts with OS X Server 10.5.6. I have AFP and SMB (and Open dir) services enabled. Using all default settings I am ab

  • Images not printing properly in InDesignCS4

    I posted this in the color management forum but realize this may be a better place. Apologies for double-posting... I have made the switch from Apple Pages to InDesign (CS4) and am having poor print results. The same document, with the same image sou

  • Data migration ALE or idocs and bapis

    hi , thank you guys for the support. i am into a data migration project. i need the initial setup for the idocs and bapis. i dont know anything about these so can u send me the process for the setup and the data migration process too with idocs and b

  • Cfchart yaxis scale is wrong when combining bar and line charts

    Hi, I am trying to combine a bar and line chart ti display data.  Everything looks good except that the yaxis scale is off.  I set the scaleMin to 0 but that doesn't help.  Below is my code, the custom XML style and a screen shot.  My ultimate goal i