Interrupt the Visa waiting on event

I use VISA waiting on event, character in series, to wait for the serial data to arrive. The data arrives once per minute. I have the time-out set for 70 seconds so that the program will not do no matter what bed until they arrive a minute data. If I want to stop the program, I have to wait the arrival of message because the program is 'blocked' waiting on the service of the event. How can I stop waiting on event? The problem I see is that while it expects nothing is read. If no Boolean values are read. I have a feeling that I might have to accept this flaw in the case where the function. All advice is appreciated. Thank you.

ssmith

Rather than use the event, you can use the VISA to the Serial Port bytes. As long as you put a reasonable waiting time in your loop (i.e. 100-250 ms), you can stop the program quickly. You can also change the time-out period of the event to something much smaller and ignore timeout error, you would get. Use one of the calendar functions (i.e. number of cycles) to determine how many times you get data and define an error if the instrument stops sending.

Tags: NI Software

Similar Questions

  • 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.

  • What is the measure of the value "Waiting" in AWR report?

    Event Expected % Time - out Wait total (s) times AVG wait (ms) Waiting for /txn
    SQL * Net more data from dblink406 7474661184.13
    reading of scattered files DB28 6593301212.97
    SQL * Net message from dblink the30 115254813.63
    log file parallel write21 02117789.52

    Hi all

    As the example below, I question what is the measure of the value "Waiting" in the section "event wait" AWR report?

    Because "Expected" the value is high, but "Queue time Total (s)" is low. example "SQL * Net message from dblink the" a 30 115 "expected' but 'Queue time Total (s)' lower 'DB file scattered read' w 28 659 'wait '.

    Could you please explain more about the value "waiting"?

    Thank you

    Hiko

    taohiko wrote:

    Event Waits %Time -outs Wait total (s) times Avg wait (ms) Waits /txn
    SQL * Net more data from dblink 406 747 466 1 184.13
    reading of scattered files DB 28 659 330 12 12.97
    SQL * Net message from dblink the 30 115 254 8 13.63
    log file parallel write 21 021 177 8 9.52

    Hi all

    As the example below, I question what is the measure of the value "Waiting" in the section "event wait" AWR report?

    It is simply a... count the number of times where the system had to "WAIT" on the specified event.

    Because "Expected" the value is high, but "Queue time Total (s)" is low. example "SQL * Net message from dblink the" a 30 115 "expected' but 'Queue time Total (s)' lower 'DB file scattered read' w 28 659 'wait '.

    Watch "AVG time-out.    In one case, there are fewer occurrences of the event, but the average wait by event time was higher.

    If I buy 3 burgers and pay $1000 each

    or I buy 500 burgers and pay $1.00 each.

    Why 3 hamburgers cost more than 500 burgers?

    Could you please explain more about the value "waiting"?

    "Waiting" is the number of times that the system had to wait for the named event, during the sampling period.

    "Total wait time" is the total time (measured in seconds) spent waiting on all occurrences of the specified event, during the sampling period.

    "Avg" wait"is the time (expressed in milliseconds) means spent on each occurrence of the specified event, during the sampling period.

    It seems pretty obvious.  You count how many times it happens something (wait), you measure it, time spent doing this something fracture (total wait time) and tells you the total time spent (total wait time) by the number of times it happened (waits) to find out the average time spent on each occurrence of that something.

    Thank you

    Hiko

  • My HP Photosmart Premium is saying "preparing the printer can not be interrupted. Please wait... "What is happening?

    My HP Photosmart Premium is saying "preparing the printer can not be interrupted.  Please wait... "What is happening?

    http://h30434.www3.HP.com/T5/scanning-faxing-and-copying/HP-Photosmart-premium-error-message/TD-p/1470957

    HP support

    Edit:

    I know that maybe it's a little late to come and see this post was several months ago, but I had the same problem.

    I ended up turning off the machine and opening printer and check the ink cartridges (I had seen just to find the part number for a new cartridge).  I found that the blue cover which snaps into place on the ink cartridges was broken not closed completely.  This has caused the printer constantly tries to go into maintenance mode, but it could never align cartridges.  She also told me that there is a paper jam, even when there is no paper in the machine.  I even let the maintenance run all night without success.

    Once the cartridges have been broken in place and the blue cover has been fully guaranteed, the printer worked.

    above compositions of this thread:

    http://h30434.www3.HP.com/T5/eprint-print-apps-mobile/HP-OfficeJet-Pro-8500A-plus-printer-is-stuck-in-maintenance-mode/TD-p/1207907

  • "the db file sequential read" waiting for event slow down an application.

    "the db file sequential read" waiting for event slow down an application.

    It is a rather strange problem. There is an update statement that hangs on the wait event 'db file sequential read' and until you restart the database, the query works fine. It happens once a week, usually Monday or after several days of large amount of work.

    I checked the processor and is fine, memory is very good, although the SGA and PGA have taken maximum memory. Flow of the disc seems to be ok since each another session on the basis of data looks very good.

    I guess that there is a missing configuration to avoid having to restart the database each week.

    Any help is greatly appreciated.

    Hello

    If you want same order of the tables as plain exp after reboot just go with ordered hint

    UPDATE item_work_step
    SET user_name = :b1,
    terminal = SYS_CONTEXT ('USERENV', 'TERMINAL'),
    status_cd = 'IN PROCESS'
    WHERE item_work_step_route_id =
    (SELECT item_work_step_route_id
    FROM (SELECT /*+ORDERED */ iws.item_work_step_route_id
    FROM user_role ur,
    work_step_role wsr,
    work_step ws,
    app_step aps,
    item_work_step iws,
    item_work iw,
    item i
    WHERE wsr.role_cd = ur.role_cd
    AND ws.work_step_id = wsr.work_step_id
    AND aps.step_cd = ws.step_cd
    AND iws.work_step_id = ws.work_step_id
    AND iws.work_id = ws.work_id
    AND iws.step_cd = ws.step_cd
    AND iws.status_cd = 'READY'
    AND iw.item_work_id = iws.item_work_id
    AND iw.item_id = iws.item_id
    AND iw.work_id = iws.work_id
    AND i.item_id = iws.item_id
    AND i.item_id = iw.item_id
    AND i.deleted = 'N'
    AND i.item_type_master_cd = :b3
    AND ur.user_name = :b1
    AND aps.app_name = :b2
    AND ( iws.assignment_user_or_role IS NULL
    OR ( iws.assignment_user_or_role IN (
    SELECT ur.role_cd
    FROM user_role ur
    WHERE ur.user_name = :b1
    UNION ALL
    SELECT :b1
    FROM dual)
    AND iws.assignment_expiration_time > SYSDATE
    )
    OR ( iws.assignment_user_or_role IS NOT NULL
    AND iws.assignment_expiration_time <= SYSDATE
    )
    )
    AND (iws.pend_date IS NULL OR iws.pend_date <= SYSDATE
    )
    ORDER BY aps.priority,
    LEAST (NVL (iw.priority, 9999),
    NVL ((SELECT NVL (priority, 9999)
    FROM item_work
    WHERE item_id = i.parent_id
    AND work_id = 42),
    9999
    )
    ),
    DECODE (i.a3, NULL, 0, 1),
    NVL (iw.sla_deadline,
    (SELECT sla_deadline
    FROM item_work
    WHERE item_id = i.parent_id
    AND work_id = 42)
    ),
    i.parent_id,
    i.item_id) unclaimed_item_work_step
    WHERE ROWNUM <= 1)
    

    If you want to get rid of the nested loops use USE_HASH

    UPDATE item_work_step
    SET user_name = :b1,
    terminal = SYS_CONTEXT ('USERENV', 'TERMINAL'),
    status_cd = 'IN PROCESS'
    WHERE item_work_step_route_id =
    (SELECT item_work_step_route_id
    FROM (SELECT /*+ORDERED USE_HASH(ur wsr ws aps iws iw i) */ iws.item_work_step_route_id
    FROM user_role ur,
    work_step_role wsr,
    work_step ws,
    app_step aps,
    item_work_step iws,
    item_work iw,
    item i
    WHERE wsr.role_cd = ur.role_cd
    AND ws.work_step_id = wsr.work_step_id
    AND aps.step_cd = ws.step_cd
    AND iws.work_step_id = ws.work_step_id
    AND iws.work_id = ws.work_id
    AND iws.step_cd = ws.step_cd
    AND iws.status_cd = 'READY'
    AND iw.item_work_id = iws.item_work_id
    AND iw.item_id = iws.item_id
    AND iw.work_id = iws.work_id
    AND i.item_id = iws.item_id
    AND i.item_id = iw.item_id
    AND i.deleted = 'N'
    AND i.item_type_master_cd = :b3
    AND ur.user_name = :b1
    AND aps.app_name = :b2
    AND ( iws.assignment_user_or_role IS NULL
    OR ( iws.assignment_user_or_role IN (
    SELECT ur.role_cd
    FROM user_role ur
    WHERE ur.user_name = :b1
    UNION ALL
    SELECT :b1
    FROM dual)
    AND iws.assignment_expiration_time > SYSDATE
    )
    OR ( iws.assignment_user_or_role IS NOT NULL
    AND iws.assignment_expiration_time <= SYSDATE
    )
    )
    AND (iws.pend_date IS NULL OR iws.pend_date <= SYSDATE
    )
    ORDER BY aps.priority,
    LEAST (NVL (iw.priority, 9999),
    NVL ((SELECT NVL (priority, 9999)
    FROM item_work
    WHERE item_id = i.parent_id
    AND work_id = 42),
    9999
    )
    ),
    DECODE (i.a3, NULL, 0, 1),
    NVL (iw.sla_deadline,
    (SELECT sla_deadline
    FROM item_work
    WHERE item_id = i.parent_id
    AND work_id = 42)
    ),
    i.parent_id,
    i.item_id) unclaimed_item_work_step
    WHERE ROWNUM <= 1)
    

    and for small tables, you can try adding for example FULL (your) FULL (wsr)

    It can be rewritten in a different way, but it's the fastest way to try how query will be if you rewrite it. Check the explain plan command if certain partially ordered tables are not joined because you can get the Cartesian join, it seems that it will be ok.

    View query result in the em console.

    Concerning

  • What are the following wait events? Someone can it translate into the details?

    What are the following wait events? Someone can it translate into the details?
    PX Deq: Example table Q
    PX Deq Credit: send blkd
    PX Deq: Join AC
    PX Deq: Signal ACK
    PX Deq: Fragment of Msg
    direct path read
    PX qref latch
    SQL> select event,total_waits,time_waited,wait_class from v$system_event order by total_waits;
    EVENT                          TOTAL_WAITS TIME_WAITED WAIT_CLASS
    ------------------------------ ----------- ----------- --------------------
    db file scattered read             9333287     2471813 User I/O
    *PX Deq: Table Q Sample            11401065    43684227 Idle*
    *PX Deq Credit: send blkd          13798394    25448649 Other*
    SQL*Net message from client       20767011  1179217392 Idle
    SQL*Net message to client         20767019        2618 Network
    *PX Deq: Join ACK                  23735308     1022426 Idle*
    *PX Deq: Parse Reply               24882798     1278726 Idle*
    rdbms ipc message                 25223968  2147012652 Idle
    *PX Deq: Signal ACK                26615286    27873560 Other*
    cursor: mutex X                   26745289       52071 Concurrency
    *PX Deq: Msg Fragment              43670924    78219774 Idle*
    
    EVENT                          TOTAL_WAITS TIME_WAITED WAIT_CLASS
    ------------------------------ ----------- ----------- --------------------
    PX Idle Wait                      68927042  4364594403 Idle
    PX Deq: Execute Reply             88498025     4326377 Idle
    PX Deq: Execution Msg            823922687   792964190 Idle
    *direct path read                1274423531     7242769 User I/O*
    *PX qref latch                   2.3745E+11    49638018 Other*
    
    122 rows selected.

    http://download.Oracle.com/docs/CD/B19306_01/server.102/b14237/waitevents.htm#i968375

  • Den inst and Mettler balance does not not for the Visa print command

    Hello, I am working at the interface a S-8001 Instrument in Denver and an analytical balances Mettler Toledo PB5001 in the same .vi. Using the subvi VISA I can get two scales to account for their mass in the .vi, but only if I send them constantly of the data (i.e., baud and comm port, etc. are configured correctly). My problem is that ongoing surveys are both unnecessary and are prone to error and the .vi are save only a part (or a zero) in any event given sample. I can confirm in addition to using hyperterminal print control correct for the Denver Instrument balance is "esc + P", and I think that the command of Mettler is a variant of '' IF. '' However, enter either of these commands (and other variations) in the terminal 'chain to write' the visa write .vi does not appear to send the necessary information to the balance to deal with the measure. I spoke with support technique both Metter and DI and after spending time with each other that they were unable to solve the problem... but suggested that perhaps the wonderful world OR maybe get an idea. Forward to your response. Thank you!

    How do you send the esc character? You can just type esc. Hex 1B then you could do a right-click on the control of the chain and select "hexadecimal display. There are other such features a cast and table byte in string that are useful when doing non-ASCII.

  • Why "limit maximum instances of this event in the queue" in the dialog box change events?

    Why I "would limit the maximum instances of this event in the queue" in the dialog box change events?

    I think that this is new for LV 2014, but I couldn't find an explanation for an instance of good use. A research on OR displays only the 2014 help text, which explains what it does, but not why?

    Does anyone know good arguments to use this option?

    Thanks in advance.

    Justin Tyme

    It is useful for user interface elements that can enqueue actions as quickly as they can be made.

    For example, say it takes takes 1 second to take a picture and save it. The user presses the button "Take a photo", but they do not see a new image file again after a wait of 250 ms (human beings humans can be impatient) so they press twice. Finally, they see a new file image... and then another... and then another... To get rid of this possibility, check this box.

    Or that you have a cursor to adjust some settings. Moving the cursor updates very fast! If the user swipes from 0 to 1 then the program might try to send all the rest as a parameter to your instrument, which takes some time. Instead of sending all of these values, it is probably better if the software can keep up with the cursor and send a value of about 1 at the same time, the cursor said 1. If you do not check this box, the user can be 1, but the unit will continue to receive values from 0.53, 0.54, 0.55...

  • Windows has recovered from an unexpected shutdown. Windows can check online for a solution to the problem. Problem event name: bluescreen

    Have had problems since 31/12/09.  Tech replaced Dell hard drive 14/01/10 because all software solutions did not resolve various problems, including the screen black and white letters indicating the mode without failure, or count down the regular opening.  System Restore has used several times, all software removed and replaced.  New Quickbooks reinstalled two times 10, it usually starts up quickly.  I was told not to turn it off, just let it run.  It automatically goes into sleep mode, it still does not start correctly.  Last message is that Windows has recovered from an unexpected shutdown;  Windows can check online for a solution to the problem.  Problem event name: bluescreen

    Windows has recovered from an unexpected shutdown.  Windows can check online for a solution to the problem.  Problem event name: bluescreen.

    Hi slopchop

    In the last few days have installed new programs? Or Anti Virus?

    Try the steps in this link and check:

    http://support.Microsoft.com/kb/958233

    http://support.Microsoft.com/kb/925810

    Also refer to:

    http://social.technet.Microsoft.com/forums/en-us/itprovistasetup/thread/0a28ca4a-82a2-465D-92ef-b471ae86c887

    http://social.technet.Microsoft.com/forums/en/itprovistaapps/thread/2e6991f4-7489-4D6F-A0B5-74de3d694d74

    After back and let us know if it helped to solve your problem.

    Thank you and best regards,

    R uma - Microsoft technical support.

    Visit our Microsoft answers feedback Forum and let us know what you think.

  • What is the cause of the message "Waiting for Service ' Console CVD activity

    I have two related questions.

    basis, I just started centralizing 200 computers ish, all except 2 appears fine, 2 questions, one below and another with VSS errors.  This message is just for the question "in waiting for the Service.

    1. What is the cause of the message "Waiting for Service ' Console CVD activity and is there anywhere that documents these meanings of status.
    2. No idea where I should start troubleshooting the message "Waiting for Service ' I get to the computer below.

    I have a computer with this status which comes to have installed the client and will not be to centralize.  Other computers seem to work properly (centralized).

    The computer is to ping requests, but appears as disconnected in the console.

    I deleted the CVD and restarted the centralization CVD using a different policy on a different volume without change.

    Journal of the history of CVD below

    Description of the Type of weather

    31/01/2014-08:52:32 AUDIT_EVENT assign device, device: PC30866 (1995), cardiovascular disease: 11614, political CVD: don't Default - every 4hrs - no drive D (1.1)

    02/05/2014-13:53:58 politics AUDIT_EVENT assign CVD, CVD: PC30866 (11614), CVD policy: Migration Post-quotidien (1.0)

    31/01/2014 General Office EVENT 20:44:46 service error

    31/01/2014 General Office service EVENT 17:39:04 error

    31/01/2014 14:44:34 EVENT has not finished downloading, internal error, exception attached

    31/01/2014 General error from the EVENT 13:05:15 service office

    31/01/2014-12:30:37 TRANSACTION_START PC30866 - centralize endpoint

    the transaction log has an inscription mentioning a failure (not sure if it is the server or PC related) disc.

    Diseases cardiovascular diseases cardiovascular name Type State layer size (MB) data transferred (MB) branch reflector savings start time end time transfer (MB)

    Of the endpoint PC30866 centralize 11614 reading disc failed 169648 1531 0 31/01/2014 12:30:37 05 d 04:16:52

    The next event is in the application event log and the Mirage event log for the failed computer. (there were not all other errors in the paper since the deployment of mirage customer and there is no errors in the system event log)

    Event type: error
    Event source: VMware Horizon Mirage customer
    Event category: no
    Event ID: 0
    Date: 31/01/2014
    Time: 20:44:46
    User: n/a
    Computer: PC30866
    Description:
    Error general service office
    Unexpected exception taken (sender Name:Wanova.Desktop.Service.exe
    There is no policy context.
    , the object exception System.OutOfMemoryException: Exception of type 'System.OutOfMemoryException' was thrown.
    System.Collections.Generic.List to ' 1.set_Capacity (Int32 value)
    System.Collections.Generic.List to ' 1.EnsureCapacity (Int32 min)
    to System.Collections.Generic.List' 1. Add (T item)
    at Wanova.Net.DataTransfer.TransferStreams.SignatureResponseStream.ProcessChunk (ChunkInfo chunkInfo)
    at Wanova.Net.DataTransfer.TransferStreams.ChunkInfoDecodingStream.BeginWrite (Byte [] buffer, TransferStreamWriteCallback onWriteComplete)
    at Wanova.Net.DataTransfer.DataHandler.ExecuteDataStreamTask (DataHandlerExecutionTask task, MarkCompletionCallback markCompletionCallback)
    at Wanova.Net.DataTransfer.DataHandler.ExecuteTask (IExecutionTask task, MarkCompletionCallback markCompletionCallback)
    Wanova.Net.DataTransfer.ExecutionController.QueueListener (Group IExecutionTask)
    to Wanova.Common.ThreadUtils.ParamaterizedWorkItem'1.Run (object fakeParam)
    at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context (Object state)
    at System.Threading.ExecutionContext.Run (ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx)
    at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem)
    at System.Threading.ThreadPoolWorkQueue.Dispatch)
    at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback (), ends at True)

    For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

    It turns out that this computer seems to have hard drive errors, so not a matter of mirage.

  • Once a day linking Bing itself forces on FireFox. He interrupts the connection.

    Once a day linking Bing itself forces on FireFox. He interrupts the connection.

    This is the link that is displayed: go.microsoft.com/fwlink/?LinkID=219472 & clcid = 0x409

    I get this message: the connection was reset

    The connection to the server was reset while the page is loading.

       The site could be temporarily unavailable or too busy. Try again in a few moments.
       If you are unable to load any pages, check your computer's network connection.
       If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the Web.
    

    Try again

    I don't use any of Bing. Only StartPage Qwant and DuckDuckGo.

    PS I also asked this question on the MS 8.1 Bing forum. As he might also be a Windows problem.

    Thank you very much.

    Ok. The only thing I forgot to do, is use Qwant to for a search on the link I provided. And now the answer has been:

    https://answers.Microsoft.com/en-us/IE/Forum/IE10-windows_8/Windows-8-goes-to-Bing-by-itself-all-the-time/386e9a25-8149-4EE6-84b4-65332022c2a7

    So I solved it myself. Laughing out loud.

  • I can't delete a game called Float that gives the message waiting. The cross and the oscillation with delete option appear, but it won't when I select Remove. Any ideas please?

    I have a new mini iPad 4. I can't delete a game called Float that gives the message waiting. The cross and the oscillation with delete option appear, but it won't when I select Remove. I don't know how it came to be. Any ideas please? Thank you.

    First try a reset to see if it finishes downloading. Press and hold the home and power buttons until the Apple logo appears. Release the two buttons. Wait until the iPad tour starts on its own.

    Check if you can remove the application. If not go into settings > general > use iCloud and storage > storage > storage management. Wait for the list of apps to open. See if the float is on the list. If it is delete it from there.

  • New bug? Horizontal white background interrupts the background image tiles after 1 to 2 pages

    My site was going on well on Firefox (and all the other major browsers), until recently. Now Firefox interrupts the white tile background image, bottom horizontal bar across the width of the page and about an inch long. What's up with that?

    This BUG really does wreak havoc on my website: link to my Site

    Correct immediately!

    Works for me on the site.

    What gets selected if you right click on that white space and open the Inspector?

    Reload Web pages, and ignore the cache.

    • Hold SHIFT and click reload.
    • Press 'Ctrl + F5' or 'Ctrl + Shift + R' (Windows, Linux)
    • Press 'Cmd + Shift + R' (MAC)
  • Since 10.11 I have not been able to download via the usb port of my Davis Vantage weather station. No solution of tech Davis on the issue even with the new recorder of events in the resort. Is there a problem with the usb?

    Since 10.11 I have not been able to download via the usb port of my Davis Vantage weather station. No solution of tech Davis on the issue even with the new recorder of events in the resort. Is there a problem with the usb?

    What Mac? (details)

  • My iPad detects inactivity while I'm listening to a story.  Then he slips into the mode "sleep" and interrupts the story.  Any suggestions on how to avoid this?

    My iPad detects inactivity while I'm listening to a story.  Then he slips into the mode "sleep" and interrupts the story.  Any suggestions on how to avoid this?

    Setting to never by using the auto-lock settings application.

    Settings > general > auto lock > never

Maybe you are looking for