Serial write takes unexpectedly long when more than 7 bytes are written

Hi,
My vi is attached. 
As you see, it's very simple.
- output buffer fifo is set to 128 bytes, which is generously higher than my needs.
- my baudrate is 2.5 mpbs.
- I write string of 9 bytes such as 012345678, and the execution time of the vi is around 40 us. 
  I thought it's because of the blocking structure of the synchronous write, and I decided to switch to asynchronous
  write, since I need to go above 20 kHz.
- when I switch to asynchronous write, it even gets worse, and I get ~58 us. it seems like asynchronous doesn't work at all.
so far, I explained my problem. I also did some simple experiments to debug the problem.
- when my string is shorter than 8 bytes, everything is beautiful, asynchronous write takes nearly 15 us.
  when I enter an 8 bytes or longer string, it jumps up to 58 us again.
what am I doing wrong? I'm stuck here.
Gorkem Secer.
Attachments:
serialWrite_niForum_pic.png ‏19 KB

The driver might for a lot of reasons not want to or even can't fill up the 8 byte hardware FIFO buffer entirely. This could be for instance since it has to work around some bugs in certain hardware. It might not be necessary for the specific hardware revision in your system but that driver has to work for many different hardware systems.
The magnitude of timing control you try to achieve is simply beyond a software system if you require reliable and hard timings. It may be possible to achieve on a simpler but still powerful embedded system with custom made software drivers and RT OS but not on a more general purpose RT OS even if the hardware is pretty powerful. But such more custom made solutions would be more than a few magnitudes more expensive to develop.
You can keep barking up this tree but it is unlikely that NI can do much about it without redesigning parts of the RT system, which is pretty much out of question as they simply license it from Ardence/IntervalZero and only adapt it where it is strictly necessary to work with their hardware. Most likely their license doesn't even allow them to customize it at will in any other way than is strictly necessary to get it to work on their own hardware.
Your options are as far as I can see, to either rethink the timing requirements or adapt the software in such a way that the bigger delay won't be a problem or to go with a hardware solution based on an FPGA board or similar.
As to the difference of asynchronous write and synchronous that is mostly about what VISA API is called underneath. The LabVIEW function remains blocking for as long as is necessary to pass the data to the OS driver. In synchonous mode the LABVIEW VI calls the synchronous VISA API once and that simply waits until VISA returns from the function. For the asynchronous case LabVIEW calls the asynchonous VISA function and then keeps looping inside its own cooperative multithreading layer until VISA indicates that the asynchonous function has been performed. This is mostly for historical reasons when LabVIEW didn't have OS supported multithreading and all the multithreading happened in the cooperative LabVIEW code scheduler. Nowadays asynchonous VISA mode has almost no benefits anymore but genearlly will cause significantly more CPU load.
Rolf Kalbermatter
CIT Engineering Netherlands
a division of Test & Measurement Solutions

Similar Messages

  • No flickr share sheet when more than 99 photos are selected

    flickr share sheet does not appear when more than 99 photos are selected. So does Facebook, Airdrop and others except only "add to iPhoto". They all show up when >100 photos are selected but for more they don't
    2010 MacBook Pro 15", Yosemite

    *<100 not >100

  • Report File Substeps only listed when more than 2 entries are present

    Hi All,
    a short question regarding report file generation. Our report file has the problem that the substep report texts are only printed when the substep has more than 2 entries inside. Once the third entry (even it is some dummy entry, but it must write something to the report file) is present the sub report texts can be found inside the report.
    Michael

    Hi,
    Can you post an small example showing your problem?
    Regards
    Ray Farmer
    Regards
    Ray Farmer

  • Info broadcaster - falls over when more than 2 queries are in a workbook

    Hi everyone,
    We use IB reports extensively with over 2,000 IBs being sent out weekly.
    I have a query I want so send out via IB and I can create an IB setting on the query without issue.  However when I insert more than one version of the query in a workbook, and try to create an IB setting on the workbook, IB falls over once I select Create new Setting.
    Its a fairly chunky query, we have no issues running the query in the Analyser and we have a number of workbooks with 20+ sheets and the query on each sheet, the workbook is fine.
    Its just when we create an IB setting we have issues.
    Anyone encountered this in your own businesses?
    Thanks
    Gill

    Hi Gill,
    We can't say that the Broadcasting is successful,if you are abe to precalculate through backend.This just for a testing of preclaculation server and not for broadcasting.
    If you are able to broadcast through web, then only we can say it is succeeded.
    Rgds,
    Murali

  • When more than two tabs are open (no matter the content), FireFox (3.6 and 4.0) slows down and the CPU usage value on the Task Manager shoots up to 100%.

    The Memory usage also shoots up to about 475k MB. This has happened over two computers, the first being a stock Dell Inspiron 1620 with Windows XP and this one being a stock HP G72 with Windows 7. I used a data transfer cable to transfer all settings from the first computer to this computer. The problem persisted through 2 updates (3.5>3.6>4.0). The only FF add-ons I have downloaded are NoScript and AdBlocker; I also have several unused toolbars downloaded from various other applications (Yahoo, Norton, and AVG) and frequently use the Google toolbar, which in an unrelated matter stopped saving my searches or suggesting searches while typing at the 4.0 upgrade. If you need any more information, I'd be happy to post it.

    Try a new Profile in Firefox 4 and see how it is. <br />
    http://kb.mozillazine.org/Creating_a_new_Firefox_profile_on_Windows

  • Why does Safari become unresponsive when more than 20 windows are open

    Does 3.0.3 fix this?
    It is extremely annoying to wait for the beachball for minutes on end after a certain number of windows( 15 to 25) are open. You can't open a new one , you can't close old ones, you can't scroll, you can't use the back arrow, you can't bookmark.
    I have tried iFreeMem to clear memeory, Empty cache, Clear History, keeping desktop clear of icons, nothing works.
    Mi compadres in the Photoshop Forum believe it is a file swap issue and the disk is being accessed repeatedly, but I don't think so. Fire Fox does the same thing but allows more windows to be open.
    I don't have any unresponsive or slow issues with anything else. Safari has always done this since at least 10.4

    It's not that I'm unfamiliar with tabbed browsing, I use it three times a day in Firefox for work purposes. Firefox has a less awkward tabbing scheme, for one thing.
    I't just that I never thought there would be a problem following links and leaving the previous windows open.
    Moving 25 gigs of files off my hard disk showed a temporary improvement in the number of windows I could have open in both FF and Safari, but it seems to have reverted to about 20 in S and 40 in FF. This , I thought, indicated that it was indeed a swap file slowdown, but now I don't think so. The next time I start linking, I'll use Open in Tab and see what happens. Not tonight, too tired.

  • Firefox 4 freezes when more than 3 tabs are open, it is using 1Gb of memory

    Win7 x64, Intel i5, 4Gb RAM, ATI Radeon 5700 series, all drivers up to date.
    I downloaded Firefox 4 today. I had 3 tabs open (two forums and 1 Google) I clicked on a Google article and Firefox froze. I opened Task Manager and closed it down. This happened 4 times. I started a new session, opened the 2 forums and put the same search into Google - it happened again.
    I uninstalled FFX4 and reverted to IE for my research. I then re-installed FFX3.6.16 and normality was restored.

    Try a new Profile in Firefox 4 and see how it is. <br />
    http://kb.mozillazine.org/Creating_a_new_Firefox_profile_on_Windows

  • Wcf Data Service fails when more than 8properties  in the 'select=' portion

    Hi:
    I am using WCF Data Service and Oracle
    EF Provider is ODAC11.2 Release 4
    Wcf Data Service fails when more than 8 properties are specified in the 'select=' portion of the URI
    here is my code
    var q = from c in this.ctx.SALESORDER_ITEM
    select new
    c.SORDERDETAILID,
    c.IID,c.DMFLAG,c.OWNERID,c.SKUID,c.SKU_ID,c.TRADENO,c.SOURCEID,c.SORDERID
    excetion:
    InvalidOperationException: An error occurred for this query during batch execution. See the inner exception for details
    The inner exception is null, but the DataServiceClientException states: Value cannot be null Parameter name: value
    the exception is thrown in base.OnStartProcessingRequest(args) method (overridden).
    Here is the call stack as well:
    at System.Data.Services.WebUtil.CheckArgumentNull[T](T value, String parameterName)
    at System.Data.Services.Internal.ProjectedWrapper.set_PropertyNameList(String value)
    at lambda_method(Closure , Shaper )
    at System.Data.Common.Internal.Materialization.Coordinator`1.ReadNextElement(Shaper shaper)
    at System.Data.Common.Internal.Materialization.Shaper`1.SimpleEnumerator.MoveNext()
    at System.Data.Services.Internal.ProjectedWrapper.EnumeratorWrapper.MoveNext()
    at System.Data.Services.DataService`1.SerializeResponseBody(RequestDescription description, IDataService dataService)
    at System.Data.Services.DataService`1.HandleNonBatchRequest(RequestDescription description)
    at System.Data.Services.DataService`1.HandleRequest()
    Is there a max number of properties in $select statement
    I think may be it is oracle provider's problem ,but i don't konw how to debug it Can anyone help me
    Any help is greatly appreciated

    I believe the null/empty string issue is unrelated to the 8 column issue, at least for ODP.NET. For example, let's take the original query in the OBE:
    http://.../yoursvcfile.svc/EMPLOYEES?$select=EMPLOYEE_ID,FIRST_NAME,LAST_NAME,SALARY,DEPARTMENT_ID,DEPARTMENT,EMAIL,PHONE_NUMBER,MANAGER_ID
    Let's make all the columns selected not nullable. You can do this with the Oracle Dev Tools. Specifically, PHONE_NUMBER and FIRST_NAME are the only nullable fields. I make them non-nullable and re-run the query and the same error occurs. Thus, these values should never be made null. Moreover, in all 107 rows, none of these row values consist of empty strings anyway.
    Looking into the problem further, WCF DS is calling methods in the System.Data.Services.Internal namespace.
    http://msdn.microsoft.com/en-us/library/system.data.services.internal.aspx
    Specifically, we see your issue when the ProjectedWrapperMany method is called. You will notice that there is ProjectedWrapper0, ProjectedWrapper1...ProjectedWrapper8 methods also present in the same namespace. As soon as the number of columns exceeds 8, ProjectedWrapperMany is called and we see the error. We're going to ask MS to help analyze the issue since this is an .NET-internal method being called.

  • Hi i  insttalled the free trial 3O days MacScan on OsX10.5 is it normal that for full scaning it takes so long time more even than one day?! on the other hand this application hasn't any uninstaller on image disc ,so how can i uninstal it from my hard?

    Hi i  insttalled the free trial 3O days MacScan on OsX10.5 is it normal that for full scaning it takes so long time more even than one day?! on the other hand this application hasn't any uninstaller on image disc ,so how can i uninstal it from my hard?Thanks

    Get rid of the tracking cookies. They are used to profile and track your browsing history. While they are privacy invading, by calling them spyware, MacScan is being a little dramatic in trying to sell you its crap. And in the future, for whatever browser you use, don't allow third-party cookies.
    To prevent tracking, get Ghostery. In addition to having Ghostery and forbidding third-party cookies, I clear out all cookies from one browsing session to another. If you always do that, you won't have any tracking cookies to worry about, so you won't need MacScan to find them for you. Btw, MacScan finds the tracking cookies in the first few minutes of scanning; if you want to use it for that, then that's all the time you need to run it for. But, as I said, you won't have any tracking cookies around if you just remove all cookies and don't allow third-party cookies. As soon as you visit a site that needs them, you'll just get new ones. No problem.
    Read all about cookies here.
    http://en.wikipedia.org/wiki/HTTP_cookie

  • Multiple select queries used in Excel BI report ,fetching data from Sharepoint DB(SP2010_Prod_ProjectServer) causing blockage on DB ,when more than one workbook(same copy of Excel BI Report) refreshed using Refresh All option.

    I am using mutiple select queries to fetch data from Project Server 2010 DB(its sharepoint DB) and these queries fetch data in Excel BI report by establishing connection with DB using instance name and all. I have enhance all these select queries and data
    is being fetched in secs. but when more than one copy of same Excel BI report is refreshed using 'Refresh All' option, then these select queries cause blockage on DB.
    Please let me know mitigation for this blockage issue.
    Should I use begin transaction and commit transaction statements/ shared lock statements.
    please reply

    Hi,
    run same query at the same time?

  • I have a 16GB san disc that when more than half full and trying to download to my Mac gives a "communication error" message.  How can I seamlessly upgrade the computers software to handle SDHC cards of this size?

    I have a 16GB San Disc that when more than half full and trying to transfer the images to the iPhoto library I get the message "communication error".  How can I update my computers software to be SDHC compatable?  I can buy a card reader but thought an update to the software would fix this problem.
    Thank you for any solutions or advice.

    KRDHarris-
    I am not familiar with Flickr, but found their support page at <Flickr Support>. You may get better help there than here.  I get the impression that the App is somewhat buggy.
    The iTunes preview page indicates the App is for iPad as well as the iPhone.  <Flickr App Preview>
    Fred

  • Lync BToE - USB HeartBeat is not passed from Lync for long duration (more than 20 seconds)

    Lync BToE - USB HeartBeat is not passed from Lync for long duration (more than 20 seconds)

    Hi,
    Did the issue happen only for you or for multiple users?
    Make sure phone update to the latest firmware.
    Best Regards,
    Eason Huang
    Eason Huang
    TechNet Community Support

  • Since upgrading to IOS 5 the address book only takes over 277 of more than 400 addresses on my notebook

    Since upgrading to IOS 5 the address book only takes over 277 of more than 400 addresses on my notebook - any suggestions why?

    Since upgrading to IOS 5 the address book only takes over 277 of more than 400 addresses on my notebook - any suggestions why?

  • How to get more than 256 bytes data

    hello.
    I use Schlumberger 32K Card�iJava Card 2.1�j.
    Please tell me how to get more than 256 bytes data from the applet in the card!!
    According to JCRE specification, need to use Get Response Command.
    What is Get Response command?
    Do I have to write processing of Get Response command to an applet?
    Or JCRE processes Get Response command?
    If knows, please tell me about!!
    Thanks.

    Thanks for your response!!
    I understand that I have to write processing of Get Response command to an applet.
    But case of Schlumberger 32K card, when host send Get Response command to an applet, card reply 6F-00!?
    I'm investigating now, and it seems that response is returned before applet processes Get Response command(CLA = 00, INS = C0).
    Do JCRE perform the process of Get Response command?

  • Add row not working if more than 5 records are displayed on the screen

    Hello all,
    Does anyone know why the add row button on an sql updateable report would stop inserting a blank row for data entry when more than 5 records have been entered into the form? I can insert up to 5 records. After that, a blank row is no longer supplied by the button. Odd. Have any ideas?
    Any assistance would be greatly appreciated!!!
    Michelle

    You're welcome, Michelle!
    The "Maximum Row Count" setting determines the maximum number of rows Apex will, or could, retrieve for a report. In your original settings, this was only 15, so matched the numbers of rows on a page - therefore, you would (A) only have one page of records and (B) never see a "New Row" as that would be record number 16 (or something higher than 15), which Apex would ignore!
    One thing to note, though, is that some of the pagination schemes (the ones with a "Z" in the description) will count the full number of records available every time the report is loaded - for small tables, this is not an issue but for large tables, you may want to use one of the other schemes.
    Andy

Maybe you are looking for

  • Low Volume with Intel HDA ALC889

    Hi, I have a Intel board with Intel HDA ALC889 and I get sound out of it without problems. To get a half-decent volume, I have to set all volume controls (i.e. Master, PCM, Front) to 100 %, but sometimes it is still too quiet. Additionally, when I in

  • How Do I Get ID3 Ratings Into iTunes?

    I have a very large MP3 library and I have my song ratings embedded into the ID3 tags. iTunes (10.6) does not recognize those ratings. Does anyone know how to make those ratings visible to iTunes? Thanks, Mike

  • How to run EBOOT file on PS3?

    I was wondering how I can run an EBOOT file on the PS3? Ages ago I purchased Crash Bandicoot from the Playstation store to run on my PSP, well I got a PS3 for christmas and I still have the file on my computer so I was wanting to stick it on my USB H

  • Takes half a minute to connect to wifi after sleep

    I close the lid and my macbook goes to sleep but it take 20 seconds to 30 secs to reconnect to my  wifi. Anything I can do?

  • Remove Mandatory field in Cost center master data

    Dear All,   I want to remove the mandatory person responsible in the cost center master data. How to do this Regards Vasantha