Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Can I use a NI GPIB-USB-A interface with HP Basic on a PC with windows 2000

I've tried to develop a LOAD BIN statement to initialize the NI GPIB-USB-A device with no luck.
0 Kudos
Message 1 of 4
(6,829 Views)
Hi James,
I have quite a bit of information for this, so here goes. The following was taken from HP's site:

--Snip Snip Snip --

HBW (HP Basic for Windows) includes five drivers for HPIB and GPIB cards: GPIB, GPIBH, GPIBN, GPIBTNT, and HPIBS.

GPIB: For I/O-mapped cards based on the TI 9914 chip. (Here, this means the 8234X cards.)

GPIBH: For memory-mapped cards based on the TI 9914 chip. (This in practice means the 27209 and 82335 cards. It cannot be used with the 8234X cards.)

GPIBN: For I/O-mapped cards based on the NEC 7210 chip. (Here, this means the National Instruments GPIB-PCII/IIA and AT-GPIB cards.)

GPIBTNT (added in HBW 6.32): This driver communicates though the National Instruments GPIB.DLL and in principle can access all National Instruments cards (and is the only driver supported for National Instruments cards on WinNT).

HPIBS: This driver communicates through the HP SICL interface library, not directly to card hardware; the HPIBS driver can be used to communicate with the HP 82340 and 82341A/B cards.

Note that HPIBS cannot be used to talk to the 82335 card. It is the only driver that works with HP cards on WinNT, and the only driver that works with the 82341D Plug-And-Play card on both Win95 and WinNT.

The GPIB, GPIBH, and GPIBN drivers are loaded using the LOAD BIN command, plus parameters defining the card type, the base address, the interrupt level, the interface select code (ISC -- basically just a number used by HBW to identify the interface), and whether the card is system or nonsystem controller. For example:

LOAD BIN "GPIBN;BOARD AT-GPIB BASE 02C0 INT 7 ISC 7 SYS"

Note that "SYS" makes the card a system controller; "NOTSYS" can be used instead to declare the card a nonsystem controller. Proper declaration of the parameters is required to get a card to work; if the base address is incorrect, HBW will not be able to find the card; if the IRQ level is incorrect or conflicts with another PC interface, the card may not be able to respond to SRQs. (You do not need to specify all of the parameters need; defaults are assumed if they are not specified, but it is a good practice to be explicit about them.)

With the National Instruments cards, as of HBW 6.32 you have a choice of drivers: either the hardware-based drivers or the GPIBTNT driver (which is generally preferred as it is much easier to use). The GPIBTNT driver is loaded with the following LOAD BIN statement:

LOAD BIN "GPIBTNT;DEV "

where "device_name" is the name of the device assigned to the GPIB card in the National Instruments GPIB Configuration Utility (such as "DEV1"). That's all there is to it.

Assuming a GPIB-PCII/IIA card is set to PCIIA mode and has the default settings, then you can load the GPIBN driver as follows:

LOAD BIN "GPIBN;BOARD PC2A BASE 2E1 INT 7 SYS"

Similarly, the AT-GPIB driver can be loaded with:

LOAD BIN "GPIBN;BOARD AT-GPIB BASE 2C0 INT 11 SYS"

* Note that if you do a LOAD BIN and it doesn't work, you get an "ERROR 167 -- INTERFACE STATUS ERROR". This can result from the slightest syntax error, so please be careful how you type in the invocation. However, you can load the driver in some cases and then find out it doesn't work, so performing a test with a simple program that does I/O is recommended.
--Snip Snip Snip --HBW (HP Basic for Windows) includes five drivers for HPIB and GPIB cards: GPIB, GPIBH, GPIBN, GPIBTNT, and HPIBS.

GPIB: For I/O-mapped cards based on the TI 9914 chip. (Here, this means the 8234X cards.)

GPIBH: For memory-mapped cards based on the TI 9914 chip. (This in practice means the 27209 and 82335 cards. It cannot be used with the 8234X cards.)

GPIBN: For I/O-mapped cards based on the NEC 7210 chip. (Here, this means the National Instruments GPIB-PCII/IIA and AT-GPIB cards.)

GPIBTNT (added in HBW 6.32): This driver communicates though the National Instruments GPIB.DLL and in principle can access all National Instruments cards (and is the only driver supported for National Instruments cards on WinNT).

HPIBS: This driver communicates through the HP SICL interface library, not directly to card hardware; the HPIBS driver can be used to communicate with the HP 82340 and 82341A/B cards.

Note that HPIBS cannot be used to talk to the 82335 card. It is the only driver that works with HP cards on WinNT, and the only driver that works with the 82341D Plug-And-Play card on both Win95 and WinNT.

The GPIB, GPIBH, and GPIBN drivers are loaded using the LOAD BIN command, plus parameters defining the card type, the base address, the interrupt level, the interface select code (ISC -- basically just a number used by HBW to identify the interface), and whether the card is system or nonsystem controller. For example:

LOAD BIN "GPIBN;BOARD AT-GPIB BASE 02C0 INT 7 ISC 7 SYS"

Note that "SYS" makes the card a system controller; "NOTSYS" can be used instead to declare the card a nonsystem controller. Proper declaration of the parameters is required to get a card to work; if the base address is incorrect, HBW will not be able to find the card; if the IRQ level is incorrect or conflicts with another PC interface, the card may not be able to respond to SRQs. (You do not need to specify all of the parameters need; defaults are assumed if they are not specified, but it is a good practice to be explicit about them.)

With the National Instruments cards, as of HBW 6.32 you have a choice of drivers: either the hardware-based drivers or the GPIBTNT driver (which is generally preferred as it is much easier to use). The GPIBTNT driver is loaded with the following LOAD BIN statement:

LOAD BIN "GPIBTNT;DEV "

where "device_name" is the name of the device assigned to the GPIB card in the National Instruments GPIB Configuration Utility (such as "DEV1"). That's all there is to it.

Assuming a GPIB-PCII/IIA card is set to PCIIA mode and has the default settings, then you can load the GPIBN driver as follows:

LOAD BIN "GPIBN;BOARD PC2A BASE 2E1 INT 7 SYS"

Similarly, the AT-GPIB driver can be loaded with:

LOAD BIN "GPIBN;BOARD AT-GPIB BASE 2C0 INT 11 SYS"

* Note that if you do a LOAD BIN and it doesn't work, you get an "ERROR 167 -- INTERFACE STATUS ERROR". This can result from the slightest syntax error, so please be careful how you type in the invocation. However, you can load the driver in some cases and then find out it doesn't work, so performing a test with a simple program that does I/O is recommended.

--Snip Snip Snip --

You can use a driver made by hp for our cards. Which is called "gpibtnt" and can be downloaded from hp.
The other information I discovered that will help out is as follows:

--Snip Snip Snip --
Following is the syntax for using National Instruments GPIB boards with HP Basic. Users must modify their load bin line to read:

"GPIBN;BO (_BOARDTYPE) IN (_IRQ) DMA (_DMA) BA (_BaseIO)"

where:

_BOARDTYPE = PC2 PC2A MC-NI (for MC-GPIB) AT-GPIB PC3NEW (for rev D and later PC3) PC3OLD (for rev C and earlier PC3) PCMCIA_IRQ = interrupt level_DMA = DMA channel_BaseIO = base address in hex



For 32-bit applications, the syntax to use is:

LOAD BIN "GPIBNI+;DEV xxxx"

where xxxx is the Interface Name assigned to the National Instruments GPIB board in the GPIB Configuration Utility.

--Snip Snip Snip --


This information can be found on our website in the knowledgebases under the title "What do I need to do to use National Instruments GPIB boards with HP Basic?"

Hope this helps out James!

Best Regards,
Aaron K.
Application Engineer
National Instruments
0 Kudos
Message 2 of 4
(6,829 Views)
I'm not sure why this was posted twice, but I answered your question on the other post: http://exchange.ni.com/servlet/Redirect?id=8490227

Best Regards,
Aaron K.
Application Engineer
National Instruments
0 Kudos
Message 3 of 4
(6,829 Views)

Connect device 

Install National Instrument GPIB-USB-HS Drivers. ( I used "ni488222.exe")

Reboot computer

Install Agilent I/O Libraries. ( I used  "Iolibs_k_01_00_00.exe" )

Run I/O config  : Auto config

Remove all configured interface except GPIB0.

Rename GPIB0 to hpib7 ( it may work if you keep the name as is but this is the way I did it )

In Hp Basic AUTOST :

LOAD BIN "HPIBS;DEV hpib7"

 

There you go, it works!

 

for additional info:

lucguerard@cmac.com

0 Kudos
Message 4 of 4
(6,157 Views)