Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

poor performance of NI-GPIB-USB-HS under linux

Hi,

I have a linux system with two GPIB interfaces on it, an old  PCI-GPIB (rev 01) and a brand-new USB-HS.  Running a test code that communicates with a well-tested GPIB instrument (a CAMAC crate controller) shows that the old PCI board is 10 times faster than the USB-HS for a simple repeated write operation.   The system does support USB2; diagnostics do not return any errors for either interface.

Details:
up-to-date gentoo box,   2.6.19-gentoo-r5 kernel
c code, gcc 4.1.1 compiler.  Relevant code is:
  
        for(i = 0; i < count; i++)
        {
                data[3]=i%256; data[4]=(i/256)%256; data[5]=i/(256*256)%256;
                ibwrt(cc12,data,6); /*typical camac write data*/
          }

        tend();
        t =  tval();
        printf("%d calls to tend() = %2.6f seconds\n",(int)count,t);

a few lines of dmesg output:

ehci_hcd 0000:00:02.2: new USB bus registered, assigned bus number 1
ehci_hcd 0000:00:02.2: USB 2.0 started, EHCI 1.00, driver 10 Dec 2004
hub 1-0:1.0: USB hub found
Initializing USB Mass Storage driver...
usb 1-3: new high speed USB device using ehci_hcd and address 3
USB Mass Storage support registered.
USB Universal Host Controller Interface driver v3.0
ohci_hcd: 2006 August 04 USB 1.1 'Open' Host Controller (OHCI) Driver (PCI)
ohci_hcd 0000:00:02.0: new USB bus registered, assigned bus number 2
hub 2-0:1.0: USB hub found
ohci_hcd 0000:00:02.1: new USB bus registered, assigned bus number 3
hub 3-0:1.0: USB hub found
...
Symbol usb_register_driver is being used by a non-GPL module, which will not be allowed in the future
Please see the file Documentation/feature-removal-schedule.txt in the kernel source tree for more details.
Symbol usb_deregister is being used by a non-GPL module, which will not be allowed in the future
Please see the file Documentation/feature-removal-schedule.txt in the kernel source tree for more details.
nipalk: no version for "nNIKAL100_getTimeOfDayInterval" found: kernel tainted.
ACPI: PCI Interrupt 0000:01:04.0[A] -> Link [APC1] -> GSI 16 (level, high) -> IRQ 20
usbcore: registered new interface driver ni488




0 Kudos
Message 1 of 2
(3,067 Views)
This result does not surprise me.  Unfortunately, USB is going to have much higher latency than PCI will for such small byte transfers.  The GPIB-USB-HS will peform on par with the PCI-GPIB when doing high byte count transfers.  National Instruments will continue to make the USB latency better, but faces the real world limitations of USB. 

Craig A
National Instruments Engineer
0 Kudos
Message 2 of 2
(3,054 Views)