3 initial functions – ADLINK cPCI-9116 User Manual
Page 64

54
• C++ Library
6.3 Initial
functions
6.3.1 _9116_Initial
@ Description
This function is used to initialize the cPCI-9116. Each cPCI-9116 card
must be initialized with this function before calling other functions is
permitted.
@ Syntax
C/C++ (DOS)
int _9116_Initial( I16 card_number, U16 *op_base_address,
U16 *pt_base_address, U16 *irq_no, U16 *pci_master);
@ Argument
card_number :
the card number of the cPCI-9116 to be
initialized, totally 4 cards can be initialized,
valid card numbers are CARD_1, CARD_2,
CARD_3, CARD_4.
op_base_address :
the physical location of the S5933(PCI
controller) operation Registers in I/O space.
pt_base_address :
the physical location of add-on registers in
pass-through I/O space. (The base address
used in CH4)
irq_no :
the interrupt IRQ level of your cPCI-9116 card,
this available IRQ value is automatically
assigned by the system BIOS.
pci_master :
BIOS enables or disables bus mastering in
PCI Command Register
@ Return Code
ERR_NoError
ERR_PCIBiosNotExist
ERR_PCICardNotExist
ERR_PCIIrqNotExist