Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

MAX crashes when accessing PCI card

I am trying to access a third-party PCI card (Acqiris DP110 digitizer) with MAX 3.0.0.3014, running under Windows 2000, Service Pack 3.
I used the VISA Driver Development Wizard to generate a Win2K driver, without interrupts nor subsystems. After installing the driver, MAX does find the card in its configuration window as a PXI system.

Problem 1 (maybe an indication for problem 3, further below):
The PCI card requests 4 resources:
BAR0 memory space, 256 bytes
BAR1 I/O space, 256 bytes
BAR2 memory space, 4 Kbytes
IRQ (although the generated driver does not support it, yet)
MAX shows the resource allocations as:
BAR0 Memory Range 0xFB000000 - 0xFB0000FF
BAR1 I/O Range 0xC800 - 0xD7FF
BAR2 Memory Range 0xFA800000
- FA8000FF
while the Win2K Device Manager shows the resources:
Memory Range FB000000 - FB0000FF
Input/Output Range C800 - C8FF
Memory Range FA800000 - FA800FFF
There is a clear discrepancy between Win2K and MAX. Why?

Problem2: I turned on NI-Spy. When I open a VISA session with MAX on this PCI card, Spy records 4 vi-calls, of which the last one is
viMemAlloc(id, 1(0x1), 0x011B89E8) which fails with status = VI_ERROR_NSUP_OPER.
What's the purpose of this call, and why should it fail?

Problem 3(the really serious one):
As soon as I try to access (an existing) hardware register in the PLX interface chip, at BAR0, with viIn32 or viOut32, the computer immediately reboots!!!
Note that the BAR0 and BAR1 requests are for the PLX9080 interface chip in PCI card.
Note also that the BAR0 resource allocation is the same in the Windows Device manager AND in MAX!

This problem has been observed with several similar PCI and compactPCI cards, on several computers. The cards are func
tioning OK with our own drivers. Thus, I exclude hardware problems.

Any ideas as to what might be happening, any suggestions as to what else to try?
0 Kudos
Message 1 of 2
(3,457 Views)
Greetings ywillener,
Regarding Problem 1, I would recommend using software that peeks at the PCI configuration space of your device and see if the BARs match Windows, MAX, or neither. You can use VISA to do this (peek at the Configuration space offset 0x10, 0x14, 0x18, 0x3f (byte) to get bar0, bar1, bar2, and the interrupt respectively), or consider using the "pcidump" application that is bundled with the Microsoft Hardware Compatibility Tests (not a small download, but I like this tool), and there are others that you can find online. I'm suspecting that the BARs will differ (I've seen this on some interesting hardware in the past).
Problem 2 is not my specialty, but I believe Dan said that this is expected behavior and not to worry.
Regarding Problem 3, if
any piece of NI hardware or software causes your system to crash, I recommend contacting National Instruments support staff directly at http://www.ni.com/ask, then select phone or email NI. National Instruments Applications Engineers are best equipped to help you resolve a system crash related to our products. Also, ensure that your system is configured to generate Kernel or Complete memory dumps when a system crash occurs (on Windows 2k/XP: Start > Settings > Control Panel > System > Advanced > Startup and Recovery). If you can get a Kernel or Complete memory dump, it will expedite the resolution of your issue (mini/small memory dumps are of little help).

Sincerely,
Jeremiah Cox
Staff Product Support Engineer -- System Software
National Instruments -- http://www.ni.com
0 Kudos
Message 2 of 2
(3,457 Views)