background image

 

 
The First 16 double words of a PCI device's configuration space are referred to as 
the device's configuration region. Within these the 16 (0-15) double words, the 04, 
05, 06, 07, 08 and 09 double words are referred to as Base Address0, Base 
Address1, Base Address2, Base Address3, Base Address4 and Base Address5. 
For more detailed information for about these 16 double words, please referring 
the book titled 

PLUG AND PLAY SYSTEM ARCHITECTURE 

(written by Tom 

Shanley, Addison-Wesley Publish Company, 1995). These base addresses are 
utilized as control register and/or I/O register for many data acquisition boards. On 
PCI-P16R16 and PCI-P8R8 series boards, the base address2 is utilized as the 
base address of digital input and digital output. So the Digital I/O functions for PCI-
P16R16 and PCI-P8R8 series are coded as follows: 
 

#define WORD    unsigned int 
#define UCHAR  unsigned char 

void   P16R16_DO(WORD BaseAddr, WORD wOutData) 

      outport(BaseAddr,wOutData); 

WORD   P16R16_DI(WORD BaseAddr) 

 WORD 

DigitalIn; 

    DigitalIn=inport(BaseAddr); 
    return DigitalIn; 

void   P8R8_DO(WORD BaseAddr, WORD wOutData) 

      outportb(BaseAddr,wOutData); 

UCHAR  P8R8_DI(WORD BaseAddr) 

    UCHAR DigitalIn; 
    DigitalIn=inportb(BaseAddr); 
    return DigitalIn; 

 

PCI-P16R16 Series User Manual (Ver.2.8, Apr. 2011, PMH-013-28)   

 

29

 

Summary of Contents for PCI-P8R8

Page 1: ...at any time without notice The information furnished by ICP DAS is believed to be accurate and reliable However no responsibility is assumed by ICP DAS for its use nor for any infringements of patents...

Page 2: ...and PEX P8POR8i P16POR16i 19 2 HARDWARE APPLICATIONS 20 2 1 RELAY OUTPUT 20 2 2 OPEN COLLECTOR OUTPUT 21 2 3 PHOTOMOS RELAY OUTPUT 22 2 4 ISOLATED INPUT 23 3 SOFTWARE INSTALLATION GUIDE 25 3 1 SOFTWA...

Page 3: ...he ON OFF state of external devices drive external relays or small power switches or activate alarms etc PCI P16C16 The PCI P16C16 is a 5 V PCI card that support Plug Play functionality to automatical...

Page 4: ...round loops block voltage spikes and isolate the host computer from damaging voltages PhotoMos relays are used where it is necessary to control a circuit using a low power signal with complete electri...

Page 5: ...rs None External Power status Table 1 1 Features of PCI P8R8 P16R16 P16C16 card PCI P8POR8 PCI P16POR16 PEX P8POR8i PEX P16POR16i Bus Type 5 V PCI Bus PCI Express x 1 Common Features z Optically Isola...

Page 6: ...ram Figure 1 1 Functional Block diagram PCI Controller EEPROM PCI BUS Buffers Drivers Buffers Filters Photo Couple Photo Couple Photo Couple Photo Couple Relay Relay Relay Relay Transistor Transistor...

Page 7: ...T Contact Rating AC 120 V 0 5 A DC 24 V 1 A Operating Time 5 ms typical Release Time 10 ms typical Insulation Resistance 1000 M Life Mechanical 5000000 ops Electrical 100000 ops General Bus Type 5 V P...

Page 8: ...lter 0 455 kHz Typical Digital Output Isolation Voltage 3750 Vrms Channels 16 Compatibility Transistor Open Collector Output Capability DC 600 mA 30 V for one channel 100 duty Response Speed 1 kHz Typ...

Page 9: ...th Filter 0 455 kHz Typical Relay Output Channels 8 16 8 16 Relay Type PhotoMos Relay Form A Contact Rating AC 350 V 130 mA Peak AC Operating Time 0 7 ms typical Release Time 0 05 ms typical Insulatio...

Page 10: ...first All the necessary and essential information is given in the Quick Start Guide including Where to get the software driver demo programs and other resources How to install the software How to test...

Page 11: ...cking the card Feel free to contact your carrier and retain your carton in case there is error 1 This card should be packed with an anti static mat 2 The user should wear an anti static wristband grou...

Page 12: ...ard Layout Figure 1 2 PCI P8R8 Layout Figure 1 3 PCI P16R16 Board Layout Note CN1 D I O channel 0 7 for PCI P8R8 P16R16 JP1 JP8 Select the input AC or DC signals of D I channel 0 7 for CN1 CN2 D I O c...

Page 13: ...channel 0 7 for PCI P16C16 JP1 JP8 Select the input AC or DC signals of D I channel 0 7 for CN1 CN2 D I O channel 8 15 for PCI P16C16 JP9 JP16 Select the input AC or DC signals for D I channel 8 15 f...

Page 14: ...tor CN1 CN2 Figure 1 6 PCI P16POR16 Layout Note CN1 D I O channel 0 7 for PCI P8POR8 P16POR16 JP1 JP8 Select the input AC or DC signals of D I channel 0 7 for CN1 CN2 D I O channel 8 15 for PCI P16POR...

Page 15: ...O channel 0 7 for PEX P8POR8i P16POR16i J1 Select the input type AC or DC signals for D I channel 0 7 CON2 D I O channel 8 15 for PEX P16POR16i J2 Select the input type AC or DC signals for D I chann...

Page 16: ...d below shows each digital input channel and the corresponding jumper PCI P8R8 P16R16 P16C16 P8POR8 P16POR16 DI6 DI4 DI2 DI7 DI5 DI3 DI1 DI0 DI14 DI12 DI10 DI15 DI13 DI11 DI9 DI8 CN1 CN2 Channel Mappi...

Page 17: ...ws how to select the digital input type Without Filter For DC Signal Default Setting With AC Filter For AC Signal 1 2 3 1 2 3 Figure 1 11 Jumper Settings If you are using AC input signals you must sho...

Page 18: ...connect Pin1 2 to obtain the ground isolation protection which is the default setting However for the ground non isolation the Pin2 3 for the JP2 jumper should be connected The figure below shows how...

Page 19: ...CI P8R8 P16R16 PCI P8R8 P16R16 PCI CON 2 Extender Cable NO Normally Open COM Common NC Normally Closed DIA Digital Input Point A DIB Digital Input Point B CON 1 CON 2 PCI P16R16 Series User Manual Ver...

Page 20: ...CON 2 CON 1 GND External Power Ground OUT Open Collector Output DIA Digital Input Point A DIB Digital Input Point B External Cable Ext Power External Power Input PCI P16R16 Series User Manual Ver 2 8...

Page 21: ...P16R16 Series User Manual Ver 2 8 Apr 2011 PMH 013 28 19 1 6 3 PCI P8POR8 P16POR16i and PEX P8POR8i P16POR16i i NO CM CON 1 CON 2 CON 2 External Cable DIA Digital Input Point A DIB Digital Input Poin...

Page 22: ...the control code A 1 in the control register will energize the corresponding relay The relay will switch from COM to NO normally open A 0 in the control register will turn off the corresponding relay...

Page 23: ...e 2 3 Heavy load relay circuit 2 2 Open Collector Output For PCI P16C16 Only The PCI P16C16 provides 16 channel open collector outputs and 4 channels per common power Each common power has designed fu...

Page 24: ...ys The board can eliminate ground loop problems and isolate the computer from damaging voltages Use the PCI P8POR8 P16POR16 and PEX P8POR8i P16POR16i to switch loads up to 350 VAC and 130 mA Load Powe...

Page 25: ...will give the digital input state of the photo couple isolation input Figures 2 3 and 2 4 show the basic circuit of the digital input 5 24 VAC DC Switch DIA 0 DIB 0 If Using AC Signal JP1 must be shor...

Page 26: ...input current will not active the photo coupler isolator Calculate input voltage and current then replace resister Ri PC 814 Ri 1 2 k 1 W If 20mA Vin On board circuits External Circuit Figure 2 4 Isol...

Page 27: ...EXE file in the NAPDOS folder on this CD Step 2 Click the item PCI Bus DAQ Card Step 3 Click the item UniDAQ Step 4 Click the item DLL for Windows 2000 and XP 2003 Vista 32 bit Step 5 Double Click Uni...

Page 28: ...The NAPWNT SYS and P16R16 SYS files will be copied into the C WINNT SYSTEM32 DRIVERS folder Windows 95 98 ME The P16R16 DLL and Nappci Vxd files will be copied into the C Windows SYSTEM folder For mo...

Page 29: ...lows Step 1 Select Start Control Panel and then double click the System icon on Windows Step 2 Click the Hardware tab and then click the Device Manager button Step 3 Check the PCI P8R8 P16R16 P16C16 P...

Page 30: ...P8R8 P16R16 series cards are installed in the system and also records all their I O resources information in the library The function is implemented based on the PCI Plug Play mechanism Please refer...

Page 31: ...ilized as control register and or I O register for many data acquisition boards On PCI P16R16 and PCI P8R8 series boards the base address2 is utilized as the base address of digital input and digital...

Page 32: ...VendorID DeviceID WORD wIrqNumber wTotalBoards 0 initial board number is 0 Bus 0 for Bus 0 Bus 10 Bus Function 0 WhichLong 1 for Device 0 Device 32 Device WhichLong 0 WriteAddress Bus Device Function...

Page 33: ...vice Function WhichLong dBaseAddress _inpd 0xcfc wBaseAddr3 WORD dBaseAddress 0xfffe wConfigSpace wTotalBoards 3 wBaseAddr3 WhichLong 8 Base Address 4 WriteAddress Bus Device Function WhichLong dBaseA...

Page 34: ...Space wTotalBoards 1 wBaseAddr1 WhichLong 6 Base Address 2 WriteAddress Bus Device Function WhichLong dBaseAddress _inpd 0xcfc wBaseAddr2 WORD dBaseAddress 0xfffe wConfigSpace wTotalBoards 2 wBaseAddr...

Page 35: ...s increment board number wGetAddress 1 if wTotalBoards 16 return NotFoundBoard else return NoError void WriteAddress UCHAR bBus UCHAR bDevice UCHAR bFunction UCHAR bWhichLong DWORD dOutData WORD HiWor...

Page 36: ...ws BAR 2 DI DO Register Register Function Script Bar No Offset Name Operation Access 0x00 DI Port R 16 bit 0x00 DO Port W 16 bit 0x0C Read D O Readback R 16 bit 2 DIO 0x3C Read Card ID R 16 bit 4 2 1...

Page 37: ...OR8i and PEX P16POR16i DigitalIn inportb BaseAddr 0x0C 4 2 3 Card ID Register The format of the Card ID register is given as follows BaseAddr 0x3C X X X X Bit3 Bit2 Bit1 Bit0 It can be used to read th...

Page 38: ...the DLL driver has not been installed correctly During the DLL driver installation process the install shield will register the correct kernel driver to the operating system and copy the DLL driver a...

Page 39: ...emo programs P16R16 MSC LARGE LIB large mode library P16R16L LIB Demo code Lib for TC P16R16 TC HUGE DEMO huge mode demo programs P16R16 TC HUGE LIB huge mdoe library P16R16H LIB P16R16 TC LARGE DEMO...

Page 40: ...er executing the utility detailed information for all PIO PISO cards that are installed in the PC will be shown as illustrated below Note The PIO_PISO EXE application is valid for all PIO PISO cards T...

Reviews: