Empirisoft Support

    Welcome to Empirisoft Support
Results 1 to 4 of 4

Thread: USB Polling rate

  1. #1
    Join Date
    Feb 2009
    Posts
    2

    USB Polling rate

    Hello,
    We are using a DirectIn input device of empirisoft, with Delphi 2006 and Matlab 2006b software for our experiments.
    As we learned lately, USB devices are polled by MS-Windows at 125 Hz rate (every 8 MSec).
    Is there a way to eliminate this 8 MSec timing uncertainty in measuring reasponse time ? (We are interested in 1 MSec resolution).
    Sincerely,
    Erez Ofek
    IIPDM
    University of Haifa,
    Israel

  2. #2
    Join Date
    Nov 2005
    Posts
    294
    Hi Erez,

    Just curious - how did you learn about the 125 Hz polling rate?

    Our USB equipment uses special firmware which requests a status poll from the computer once per millisecond.

    John

  3. #3
    Join Date
    Feb 2009
    Posts
    2
    [edited formatting by moderator]

    Hi John,

    Thank you for your reply.

    One of our researchers recently got a review of his research, which mentioned the problem of using a standard keyboard for measuring response time. When we looked for this issue in the internet, we encountered a post by Mario Kleiner, who is one of the developers of the Psychophysics Toolbox for Matlab.

    In the post he discusses the 8 msec period of the windows polling :
    http://tech.groups.yahoo.com/group/p...x/message/9006
    I'm a software person, so please pardon my ignorance.
    But aren't the request of USB device from the host computer, handled by the host and its operating system? If they are - how can you impose windows to serve the device every 1 msec? This issue is important to us because we need to know if we can use the empirisoft Direct-In with softwares like Matlab+ Psychophysics Toolbox and with Delphi.

    Thanks in advance,
    Erez Ofek
    IIPDM
    Last edited by jarvis24; 02-05-2009 at 11:22 AM.

  4. #4
    Join Date
    Nov 2005
    Posts
    294
    Hi Erez,

    Thanks for the link.

    Each USB device contains a a set of something called 'descriptors' in its firmware. These descriptors tell the host computer what sort of device is attached (a camera, a memory stick, a mouse, etc), what format the transmitted data will take, and how frequently the device needs to transmit data to the host computer.

    One subset of these descriptors is a request for polling rate. As I mentioned earlier, our firmware requests a 1 mS 'tick' on this rate.

    It's quite easy to confirm this with an oscilloscope. Probing either of the two USB data lines will show that they're idle except for bursts of activity 100 or 125 times per second. Since most people don't type nearly so quickly - 100 characters per second! - a 100 Hz polling interval is more than adequate.

    Running the same test on our keyboards and button boxes shows communication occurring once per millisecond.

Similar Threads

  1. refresh rate, test online
    By aurelie Dommes in forum DirectRT Older Versions: General Questions
    Replies: 3
    Last Post: 11-05-2007, 10:58 AM
  2. 60/75 Hz refresh rate bug in older Win2000/Win XP
    By Henrik in forum DirectRT Older Versions: Troubleshooting
    Replies: 3
    Last Post: 04-23-2007, 11:17 AM
  3. ...test millisecond accurate keyboard refresh rate
    By bbhsieh in forum Hardware: How Do I...
    Replies: 4
    Last Post: 01-11-2006, 01:43 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •