Best way to generate the software clock for USB-6501 of Measurement Studio for c# VS2008

Hi all

I wonder if there is a better way to generate a clock software for USB-6501 of Measurement Studio for VS2008 in C Sharp?

I have developed a clock using C Sharp "Thread.Sleep (msecPauseTime)"; and statements to switch digital output high and low. There are a few things I noticed in creating a software clock in this way:

  1. The smallest delay by the Thread.Sleep command time is 1 millisecond (which means higher clock period is 2 msec-500 Hz, not holding not ball account no. 2 below).
  2. Sometimes the delay I see on an oscilloscope is considerably longer than the delay that I specified in the sleep command.

In my application, I create signals (a clock, a latch enable and data series) to control what an attenuator step through the USB-6501 RF connected to a USB 2.0 on my computer. This particular step RF attenuator can accept clocks with frequencies up to 10 MHz, so I would like to generate a software clock (without having to connect to an external clock to a line of input on the USB-6501) which is closest to this maximum frequency, and I think that the USB2.0 line could handle clock speeds over 500 Hz. Also, I would like to know why the delays that I see on the scope are sometimes longer than the time specified by the Thread.Sleep command. Is it caused by the suspension of the execution of my program processor for something else, as I suspect? Of course, this isn't a big deal, because it does not affect the time as my serial data and pieces change compared to my clock. However, I would like to know why it does this.

I appreciate your help.

Thank you

Jonathan Becker

Doctoral research engineer

Carnegie Mellon Silicon Valley

Jonathan,

Since the USB-6501 DIO is software programmed, you are at the mercy of the planning of the operating system and won't be able to work reliably with an external clock in the software.

You can try to set the priority of your thread 'generation of clock' to improve performance, however, because Windows is not a deterministic operating system, there are still no guarantees.  Operating systems are not required to honor the priority of threads.  You can find examples and information on the definition of the priorities of the threads in c# here:

http://msdn.Microsoft.com/en-us/library/system.Threading.thread.priority.aspx

Kind regards

Tags: NI Software

Similar Questions

  • What is the best way to generate the density curve for example spectral dBuV / 200 Hz?

    There are large screws for PSD, but this is an easy way to create a field of spectral density with units dBuV/200 Hz?

    Hey steveMAX,

    If you have equipment that can acquire these tensions, then it should be too difficult. You can use the Express VI spectral measures to produce the data. This will automatically give you the output in dB. You can then resize the axis on the graphical indicator you create so that you can display the correct data and label the axis correctly.

    Kind regards

    Chris

  • best way to generate the format avery label

    I have data in oracle xe and I use apex 4... What is the best method to generate the label... format Avery...

    1. use Jasper
    2 other methods...?
    I don't want to use bi... THIRD party cost solutions or...

    Published by: susf on June 22, 2012 21:34

    susf wrote:
    I do not know how do I get labels State... from...
    And I tried... He
    Report 1

    Cheena chris cox Green

    Jose Orange

    But does not show the image...

    More do not know how do I get label... Thanks to this method...
    He will just show me a picture...
    How can label processed... through this approach...

    The OP was able to understand:
    >
    You're right - no page element need! It took me a little bit, but I figured out how to get what I need from your example. The CSS that I use also includes: height of the line, font-size, border and width. I had serious performance problems until I removed the title of column sorting (unchecked all boxes). I added .csv and .pdf links, but they do not have the inline-block formatting so were of no use.

    Of course I learned a lot about the functioning of the reports and models. Thanks for sharing this info Paul - I appreciate it greatly.
    >
    Although it may take several days. Note where they say + "I of course learn much about the workings of the reports and models." + is the most important: to understand the concepts and techniques involved and when and how they could / should be applied to meet the needs.

    The images are only data [form of]: replace the image data and the name with the data required in your report.

  • Best way to apply the Format mask for the fields in a Table of the ADF

    Hi all

    12.1.3 JDev

    I would like to introduce the price data, quantity etc. fields of the ADF Table of the user interface in a specific format.

    These formats need to be dynamic, because they change according to the locale selected and sometimes they differ in the same locale.

    I tried approach converter custom but not satisfied because it is called several times when it is used in a table of the ADF and when asked that told me that this is the behavior.

    Custom converter of an attribute in a table called several times

    So, please suggest a better way to apply the format mask (which has min & max fractions, grouping, rounding) to the fields in the Table of the ADF.

    Please let me know if you need more information.

    Thank you

    B S Bilodeau.

    The second question, which I've mentioned here is the converter is called several times for each click on the table.

    This isn't a problem, this is the expected behavior (and you can't avoid it).

    Dario

  • Best way to set the default values for the form elements

    Hello

    I have a form with a lot of defaults that is mentioned below...
      Field                      value  
      created by             :APPL_USER
      creation_date         SYSDATE
      last_updated_by     :APPL_USER
      last_update_date    SYSDATE
      item1                     value1
      item2                     value2
    I am currently using calculation-> after presents... then when we create/update a record... these computaion takes place and the default value for the inserted values get... THIS WORKS PERFECTLY WELL.

    I want to know... If this approach is fine OR we can have a better approach to achieve...?

    Thank you
    Deepak

    Hello

    I think it's good if it fits your need.

    But why you have these fields in the form?
    created by: APPL_USER
    CREATION_DATE SYSDATE
    last_updated_by: APPL_USER
    last_update_date SYSDATE

    The user can enter the ones?
    I thought that those who are to audit and I would fill those drop with trigger in the database.
    So that you get the same "correct" values if you need to manipulate the data with example of sql client

    BR, Jari

  • I bought CS6 using a Windows computer, but the software is for Mac. can a colleague I just their email the download link? Thank you.

    Hello

    I use an old Windows PC and earlier bought CS6 (Standard model), but have not downloaded or installed. This is for iMac to a colleague who will happen to our office in the next few days. What is the best way to transfer the software on his computer? My first thought would be to send the download link, and download it or install it on any other computer until the arrival of the iMac to my colleague. Does this sound right?

    To be clear: I want to ensure the software (CS6) I bought on my PC (which must still be DL'ed or installed) can be installed on the new iMac a colleague.

    Thank you

    Marshall

    Hello

    the file download and installation CS6 Design Standard for Windows and Mac are different.

    You can download and install from the following link: download Creative Suite 6 applications

    The serial number for these products are also platform-specific.

    If you have purchased the license for Windows computer it may not work on the Mac operating system.

    You might also check out the following link for the same: a product for another language or version of trading platform

    Kind regards

    Shipti

  • What is the best way to support the retina screens?

    Hello

    I've done recently for my custom panel UI code only, but my retina users report that everything is still pixelated (I did have the chance to find a machine of the retina to test yet myself). I had hoped to make the user interface in the code would make it works naturally, but appears not to be the case.

    In this research, I stumbled upon the users of mobile applications using FlexGlobals.topLevelApplication.applicationDPI together a target DPI, but appears not to exist in the CS Flex SDK 3.4.0 (which seems to be something Flex 4).

    What is the best way to support the retina display for my Panel? As far as I know, Flex 4 does not work with the CSXS library.

    Thank you

    Cameron

    Looks like there is no way for you to do this in Control Panel. We need to update some components to be HiDPI aware first. Stay tuned...

  • Best way to generate a PWM for a stint with LabView2010 and a laptop

    Hello

    as mentioned in the title, I'm looking for the best way to generate a PWM signal to a relay. I want to use a laptop computer and the LabView2010 for she. I have read through several topics, but after a time that he just got more confused. For example the NI USB-6008 OEM case seems to be a solutiion at low prices, but I don't know if I can use for the generation of PWM signals like this thread says is not possible:

    http://forums.NI.com/T5/Multifunction-DAQ/using-PWM-on-NI-6008/m-p/231860/highlight/true#M13339

    But then again this thread right here makes it seem as if it was doable:

    http://forums.NI.com/T5/Digital-I-O/generating-a-PWM-using-USB-6008/m-p/421654/highlight/true#M5527

    Once again in abbreviated form.

    What I need:

    -the best way to generate a PWM signal to control a relay

    What I have so far:

    -LabView2010

    -Laptop

    If possible, it would be good to have two channels for two separate signals, but it is more low importance right now.

    Hey Kambra,.

    The first thread you mention is correct, you can't make output PWM in any deterministic mode with a 6008. The 6008 is strictly software timed, which means that each digital writing that is done in the unit must go through the operating system and down to the device. And there is a lot of jitter of the involved BONE. The second article you mention says the same thing. They emphasized that they could reduce the jitter of some, but still can not remove it entirely. In the second thread, they mention using a M-series USB device do output PWM deterministic (timed material).

    The compromise really down to your application and its requirements. If your application to control the relay requires no determinism, then you can use the 6008. If you need precise control over the relay, try the USB M series.

  • I'm looking for the best way and the best way to get a product key for my windows 7 Edition family.

    Hello.  I'm looking for the best way and the best way to get a product key for my windows 7 Edition family.  Thanks Bob

    Original title: product windows keys 7

    The cheapest option is the OEM System Builder for Windows 7 Home Premium license, but has some license restrictions:

    Amazon.com: Windows 7 Home Premium 64 - Bit System Builder...

    The OEM of Windows 7 versions are identical to the versions commercial full license with the following exception:

    -OEM versions don't offer any free direct support from Microsoft technical support Microsoft

    -OEM Licenses are tied to the computer first you install and activate it on

    -OEM versions allow all hardware upgrades except for an upgrade to a different model motherboard

    -OEM versions does not move directly from an older Windows operating system

    What is OEM software? :
    http://support.Microsoft.com/GP/oemsupport_1/en-GB

    Licensing FAQ:
    http://www.Microsoft.com/OEM/en/licensing/sblicensing/pages/licensing_faq.aspx

    OR

    A detail that does not have these restrictions:

    Where can I still get Windows 7?

    Full version - Microsoft Windows 7 Home Premium

    Version upgrade - Microsoft Windows 7 Home Premium Upgrade

    Family Pack: Upgrade of Microsoft Windows 7 Home Premium Family Pack (3 users)

  • What is the best way to store the RCS for an insert/update in this rec

    Oracle on Win 64 non-conteneur 12.1.0.2

    When a record in one table is inserted or updated, what would be the best way to store the RCS for this record in this folder.

    I thought of a line after trigger, but did not know if this trigger to store the current_scn would still fire that trigger again (recursive trigger).

    Someone at - he a good idea of what the best way is to do?  The devs don't want to store the pk and the SNA in yet another table...

    Yes, row_dependencies would be the best way to go.  But mgmt doesn't recreate all tables for this.

    3rd party applications retrieve data from tables (all data).  We are looking for a way for them to just pull what is new or updated updated since their last sweater.

    I suggest that you try again and give all OF THE REQUIREMENTS.

    You have rejected ANY answer given and he justified using 'hidden' on what knowledge management or the devs want or do not want to. Stop making us guess what are the requirements and constraints. If you want a real answer then tell us ALL the news.

    When a record in one table is inserted or updated, what would be the best way to store the RCS for this record in this folder.

    Solomon answered repeatedly. If you want to add a column to a table to store the then "best" SNA is to let the Oracle to do this for you automatically by using the DEPENDENCY LINE.

    As he says also re-create the table to add this clause will be MUCH MORE EFFECTIVE that everything THAT you can do it manually. It will be also more accurate because Oracle will fill the value ORA_ROWSCN with the SNA at the time the line was committed. You, as long as user, can't fill a column in function when a line is engaged since real VALIDATION belongs to a transaction, not the line or the trigger that you use.

    Yes - there are two drawbacks to this method:

    1. you need to re-create the table

    2. you cannot add an index to this "hidden" column

    The devs don't want to store the pk and the SNA in yet another table...

    Then? Who cares what the devs want to do? You want the BEST solution? Next, you will need to put aside personal preferences and determine what is the 'best' solution. Why it is important that certain dev wants to do this or not?

    OK, the problem of biz is now, 3rd party external users are an all-wheel drive large number of tables in the database via the API that we wrote.  That was obviously interrupted OLTP during the day.  To reduce to the minimum, we want for them just to extract data that has been inserted/updated since their last sweater.

    It is the definition of a "replica" DB Then why don't you consider a real replicated DB? You can use DataGuard and have replicated DB which is read only that can be used to generate reports. Oracle does ALL the work to keep ALL the tables in sync. You and your developers do NOTHING!

    We thought that store the RCS higher their last sweater would allow the API to extract only data with YVERT higher than their last data pull CHN.

    OK - except you keep rejecting solutions actually do. Ask you questions about the SNA stored in the same table, but then reject the solution that does this. And then you add your "devs" don't want to store the info in a new table either.

    Then your solutions must ONLY use the replication or Log Miner. The REDO logs have all changes, if you want to extract yourself. Replication (e.g., DataGuard) will use these logs for you to maintain a replicated database.

    We thought about it, but recreate all tables in production with ROWDEPENDENCIES as well as dealing with CF and other dependencies idea this was shot.

    Well you NEVER mentioned you "thought that" and rejected it. And you NEVER mentioned anything about FKs and other dependencies. What is FKs and other dependencies which prevents this working solution? Tell us! Give us ALL the information.

    Wouldn't a trigger AFTER LINE capture the commit YVERT?  Or is after really not after validation?

    No - a trigger has NOT one commit. A trigger runs as a step in a transaction. Validation applies to the entire transaction. Until you, or Oracle, issues a commit, there is NO "committed SNA" to be stored as ORA_ROWSCN.

    You can easily see that for yourself. Create a simple table with dependencies of the line and then update two different sessions.

    create the table emp_scn rowdependencies in select * from emp where rownum<>

    Select empno, emp_scn ora_rowscn

    Update emp_scn set work = 'b' where empno = 7499

    commit;

    The first SELECT statement will show you that each row has the same SNA.

    EMPNO, ORA_ROWSCN

    7369,70622201

    7499,70622201

    7521,70622201

    Now, do the update (but no commit), then SELECT it

    EMPNO, ORA_ROWSCN

    7369,70622201

    7499,

    7521,70622201

    Where is the value of 7499? This session will NOT see a value for the changed lines in the current transaction. Other sessions will still see the old value.

    Now do the validation, then SELECT

    EMPNO, ORA_ROWSCN

    7369,70622201

    7499,70622301

    7521,70622201

    7499 now has a new and different value than the other lines. It will not be this new value until the validation occurs.

    Yes, row_dependencies would be the best way to go.  But mgmt doesn't recreate all tables for this.

    Well, you got the answer you want. You ask the best way. Now, you say that you were told the best way. But now you don't like the answer.

    How is it our fault? Your question has been answered wasn't she?

    Here are the facts:

    1 oracle creates a history of changes - the REDO log files

    2. you can use Log Miner to extract these changes

    3. you can create your own change log by adding a log file of MV to your table.

    4. you can then write a custom code to use this MV log file to determine which rows to "reproduce".

    So far reject you all THE POSSIBLE solutions.

    Accept it or change the requirements to allow one of the solutions proposed to be used.

    Personally, if I HAD to use a customized solution, I would use a MV journal to record the ROWID of the lines that have changed (for tables ROWID cannot be changed). I would then extract the appropriate lines by pulling on the lines corresponding to these row ID.

    Even that has problems since a line can be changed several times and children lines can also be amended several times - these questions FK you mentioned.

    I suggest you read this entire thread on AskTom a dozen years ago. It addresses ALL these issues.

    https://asktom.Oracle.com/pls/Apex/f?p=100:11:0:P11_QUESTION_ID:16998677475837

    Then in your next reply on this topic give us a summary of where some things with your question and what help you further expect.

  • Volume: Best way to decrease the volume for a portion of a clip

    I have an audio clip of speaking me - about 22 minutes. I knew it would be difficult to change because of its length, so I divided into eight sections and each section has recorded independently.

    However, I made a couple of mistakes here and there. So instead of wasting time to record a whole clip again and again until I understand well, I have just re-recorded paragraphs which should be corrected.

    So, imagine a master audio clip named Project1 in setting up first. In the track above, where the third paragraph starts, is another audio clip - Project1-3. I'm trying to understand the best way to kill the volume on Project1 - just for the duration of the third paragraph. So when I listen, I should hear the patch, Project1-3, instead of the main audio, Project1.

    I checked a few tutorials, but I'm a bit confused. I thought it was something I have to do in the Source monitor, by using keyframes, but it does not work too well.

    I put a screen shot in line @ https://www.geobop.com/images/audio.png

    In the upper left corner, you can see where I created a key by clicking on the Volume and selecting the level. It was set to 0 by default, so I changed the value of-20. But when I preview the video, I can still hear the sound and changes in value-20.

    Can someone tell me what I am doing wrong?

    Thank you.

    Rather than apply keyframes to the Volume setting, you will find may be easier to use the razor tool to split the audio clip called "Project1" into several segments in the timeline panel.  Then, disable the unwanted segment (select it in the timeline panel and choose Clip > enable) or raise TI (press point comma), leaving a space.

    Your tracks can be difficult to hear suddenly as the stopwatch for the effect of Volume Audio is enabled by default.  If you look at the effect controls panel, while the audio is selected, you can proceed to the next and previous keyframe to see what 'level' to each key frame.

  • What is the best way to make the completely white background for the pictures of the products?

    What is the best way to make the completely white background for the pictures of the products?  I just need to show a product on a completely white background.

    Shoot on properly informed white background is easy. Then be tot apply an adjustment layer to whiten the BG, then apply a mask for the domains you want to not so bright.

  • Best way to integrate the CC edge animate as short Intro for Web site

    Hi people,

    I hope I'm in the right forum. I want to take a short animated introduction developed beachfront animate CC and use it as an intro to a Web site. I don't know how is the best way to integrate the animation. I published my animation film, and it works fine by itself. The site of course works fine by itself. But how do trigger you the animation to run from the index.htm page or how it normally does? I hope I'm being clear enough.

    Thanks in advance,

    -TT

    Hi-

    Check this: How to use Edge animate content in your site built with Dreamweaver | Adobe Dreamweaver tutorials CC

    2nd topic on the page, specifically: "adding edge animate the content of sites created with Dreamweaver. Watch the vid and you can see the embed code that it generates. Does that help?

  • What is the best way to create the layout for a single page website in Adobe Muse?

    I was wondering the best way to create the layout for a single page website in Adobe Muse. Does anyone have any suggestions?

    You can have access to this tutorial (and their other) a month for only $9.99. Is it too expensive for you!

  • What is the best way to check the data

    What is the best way to check the actual changes in the data, i.e., to be able to see each insert, update, delete on a given line, when it happened, who did it, and what looked like to the front row and after the change?

    Currently, we have implemented our own audit infrastructure where we generate standard triggers and an audit table to store the OLD (values at the beginning of the Timekeeping point row before) and NEW (values at the beginning of the point of timing after line) values for each change.

    I put this strategy due to the performance impact there (important say least) and because it's something that a developer (confession, I'm the developer) came with, rather than something is a database administrator came with. I looked in the audit of the Oracle, but it doesn't seem like we would be able to go back and see what a line looked like at some point in time. I also watched flashbacks, but this seems like it would take a monumental amount of storage just to be able to go back a week, much less the years currently keep us these data.

    Thank you
    Matt Knowles

    Published by: mattknowles on January 10, 2011 08:40

    mattknowles wrote:
    What is the best way to check the actual changes in the data, i.e., to be able to see each insert, update, delete on a given line, when it happened, who did it, and what looked like to the front row and after the change?

    Currently, we have implemented our own audit infrastructure where we generate standard triggers and an audit table to store the OLD (values at the beginning of the Timekeeping point row before) and NEW (values at the beginning of the point of timing after line) values for each change.

    You can either:
    1. set up your own audit custom (as you do now)
    2 flashback Data Archive (11 g). Application for licence.
    3 version check your tables with Workspace Manager.

    >

    I put this strategy due to the performance impact there (important say least) and because it's something that a developer (confession, I'm the developer) came with, rather than something is a database administrator came with. I looked in the audit of the Oracle, but it doesn't seem like we would be able to go back and see what a line looked like at some point in time. I also watched flashbacks, but this seems like it would take a monumental amount of storage just to be able to go back a week, much less the years currently keep us these data.

    Unfortunately, the audit of data always takes a lot of space. You should also consider the performance, as custom triggers and Workspace Manager will perform much slower than the FDA if there is heavy DML on the table.

Maybe you are looking for

  • My has no speaker volume in apps

    ON the phone, I can use the speakers but when in apps, in that it acts as the headphones are

  • Cliq 2 1.1.30 updated

    I have a lot of difficulties since I decided to try this update that was sent to my phone and would prevent not arise even if I hit No.. Anyway... I talked to customer service 2 x. They did a factory reset the phone and he has still the 1.1.30 update

  • Virus SEV 2012-1889

    How to remove the virus SEV 2012 - 1889

  • bizarre events when using z2

    Hi everyone I use Z2 for two weeks and it's really an incredible experience. recently I face some odd problems with my camera. first annoying problem occurs while watching a movie on my camera that is played by the default movie player, I use a hands

  • Connectivity between 10GBase-SR &amp; 1000BaseSX

    Hi guys,. Urgent need comment can transceiver module tengig to 1 end and 1 transmitter/receiver in concert to another are compatible and link can happen. Model: WS - X 6724-SFP Type: 1000BaseSX ----------------------------------- Model: WS-C4948-10GE