Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

ViOpen return with 0xBFFF0000

Hi,

I've a problem opening my PXI device using the VISA library (Version 4.0) with Windows XP.
Calling the function ViOpen with the correct device string returns 0xBFFF0000 (VI_ERROR_SYSTEM_ERROR).

Even if I try to view and open my device with the test panel of the tool "Measurement & Automation Explorer" I receive the same error.

To generate the windows driver I used the VISA driver development wizard.
The driver was installed correct and the windows device manger shows no conflicts.
My device even got a memory range assigned.

Under the "Measurement & Automation Explorer" I got an entry for my device under "devices and interfaces".
My card is shown with the correct string (PXI2::14::INSTR) but has a yellow exclamation mark on the icon.
Opening a test panel fails.
Same with the tool "VISA interactive control".

NI Spy shows:
viOpenDefaultRM (0x00F2B4B0) Status: 0 (VI_SUCCESS)
viOpen (0x00F2B4B0, "PXI2::14::INSTR", 4, 0, 0x00000000) Status: 0xBFFF0000 (VI_ERROR_SYSTEM_ERROR)
viStatusDesc (0x00F2B4B0, 0xBFFF0000, "Unknown system error (misce...") Status: 0 (VI_SUCCESS)

Please, can anybody help me with my problem.
Thanks in advance.

Best Regards,
Florian






0 Kudos
Message 1 of 8
(8,611 Views)
Hi Florian,

I found a knowledgebase which describes your problem:
http://digital.ni.com/public.nsf/allkb/4A6768E4DD0C583486256BFE00662B66?OpenDocument

Best regards
Dippi
0 Kudos
Message 2 of 8
(8,579 Views)
Hi Dippi,

Thank you for your answer.

The knowledge base document says that this error code is reserved, if the device is not properly configured to gernerate interrupts.
My device doesn't support PCI interrupts (the PCI interrupt bit in the IPR register of my card is disabled).

Does this mean that the ViOpen() function call will always fail if a device supports no interrupts?


Best Regards,
Florian
0 Kudos
Message 3 of 8
(8,565 Views)
Hi Florian,

there are only two things you can do.
1) Try to Discard and Disable Events. The functions which you has to use are:
     VISA Discard Events = viDiscardEvents ()
     VISA Enable Events = viEnableEvents ()

2) Goto
    ==> http://zone.ni.com/devzone/cda/tut/p/id/4713
            ==> 3.3 Interrupt Detection Information

I hope this will help you.
Best regards
Dippi
0 Kudos
Message 4 of 8
(8,554 Views)
Hi Dippi,

Thank you for your fast answer.


there are only two things you can do.
1) Try to Discard and Disable Events. The functions which you has to use are:
     VISA Discard Events = viDiscardEvents ()
     VISA Enable Events = viEnableEvents ()



But for these function calls I need an allready opened device.
My problem is that viOpen() fails and without a session handler (provided by viOpen) I can not call these functions.



2) Goto
    ==> http://zone.ni.com/devzone/cda/tut/p/id/4713
            ==> 3.3 Interrupt Detection Information



This section describes how to configure interrupts.
My device doesn't support Interrupts and I don't need them.
Of coure I doesn't check the "Generates interrupts" checkbox in the VISA driver development wizard.

Are there other reasons why viOpen() fails with this specific error code?
Is a device which supports interrupts a fix requirement of the VISA library?


Best Regards,

Florian

0 Kudos
Message 5 of 8
(8,550 Views)
Hi Florian,

Are there other reasons why viOpen() fails with this specific error code?
There can be more reasons:
- The Vendor ID of your device
- The serial ID of your device

Is a device which supports interrupts a fix requirement of the VISA library?
No it isn't.

You don't use a device of National Instruments I think, so the vendor ID and the serial ID can be a problem => but with that problem, I can't help you (if it isn't a device of NI)

best regards
Dippi
0 Kudos
Message 6 of 8
(8,548 Views)

Hi Dippi,


There can be more reasons:
- The Vendor ID of your device
- The serial ID of your device



You don't use a device of National Instruments I think, so the vendor ID and the serial ID can be a problem


You're allright, we don't use a decive of National Instruments.
We have our own PCI carrier board and use the PCI controller of the MPC5200 core.

Why can this be a problem?
The VISA library supports devices other than NI devices, doesn't it?



You don't use a device of National Instruments I think, so the vendor ID and the serial ID can be a problem => but with that problem, I can't help you (if it isn't a device of NI)


Is there no support on this forum if I using the VISA library with a device of a vendor other than NI?


Best Regards,
Florian
0 Kudos
Message 7 of 8
(8,522 Views)
 
 

Florian,

Without having access to your hardware and the INI file that you have created using the VISA Driver Wizard, it is very difficult for us to know what might be going wrong in the viOpen call.

Does your device use the Subsystem Manufacturer ID or Model Code? 

I just looked at your viOpen call. It looks like the third parameter in your call should be '0' instaed of '4'. Value 4 (VI_LOAD_CONFIG) is only supported for serial instruments, not PCI.

Please view the NI-VISA help documentation for information on the VISA function calls.

https://www.ni.com/docs/en-US/bundle/ni-visa-api-ref/page/ni-visa-api-ref/ni-visa-api-ref.html

Message Edited by Christian L on 08-01-2007 02:58 PM

authored by
Christian L, CLA
Systems Engineering Manager - Automotive and Transportation
NI - Austin, TX


  
0 Kudos
Message 8 of 8
(8,463 Views)