Advertisement

Quick Links

OPERATIONS MANUAL
PCM-UIO48B
NOTE: This manual has been designed and created for use as part of the WinSystems Technical Manuals
CD and/or the WinSystems website.
If this manual or any portion of the manual is downloaded, copied or
emailed, the links to additional information (i.e. software, cable drawings) may be inoperable.
WinSystems reserves the right to make changes in the circuitry
and specifications at any time without notice.
Copyright 2011 by WinSystems. All Rights Reserved.

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the PCM-UIO48B and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Summary of Contents for WinSystems PCM-UIO48B

  • Page 1 OPERATIONS MANUAL PCM-UIO48B NOTE: This manual has been designed and created for use as part of the WinSystems Technical Manuals CD and/or the WinSystems website. If this manual or any portion of the manual is downloaded, copied or emailed, the links to additional information (i.e. software, cable drawings) may be inoperable.
  • Page 2 REVISION HISTORY P/N 403-0321-000 ECO Number Date Code Rev Level ORIGINATED 110425...
  • Page 3: Table Of Contents

    Table of Contents Visual Index – Quick Reference Top View - Connectors Introduction General Information Features General Description Functional Capability I/O Address Selection Interrupt Routing Digital I/O PC/104 Bus Interface Software Summary WS16C48 Programming Reference Sample Programs Summary C Source Code Listings Cables Software Drivers &...
  • Page 4: Visual Index - Quick Reference I

    Base I/O PC/104 Bus Address (8-bit, 16-bit) Selection Connector Jumper NOTE: The reference line to each component part has been drawn to Pin 1, where applicable. Pin 1 is also highlighted with a red square, where applicable. 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 5: Introduction

    The PCM-UIO48B utilizes WinSystems’ WS16C48 ASIC High Density I/O (HDIO) Chip. The first 24 lines are capable of fully latched event sensing with the sense polarity being software programmable. Two 50-pin I/O connectors allow for easy mating with industry standard I/O racks.
  • Page 6: Functional Capability

    15 o o 16 Interrupt Routing The PCM-UIO48B can generate an interrupt on up to 24 different lines each with its own polarity select. Interrupt support is provided on the first 24 bits of each device for ports 0, 1 and 2. This interrupt can be routed to the PC/104 bus via the jumper at J4.
  • Page 7: Digital I/O

    Digital I/O The PCM-UIO48B routes its 48 lines to 50-pin IDC connectors at J1 and J2. The pin definitions for J1 and J2 are shown below. P5-7 1 o o 2 P2-7 1 o o 2 P5-6 3 o o 4...
  • Page 8: Pc/104 Bus Interface

    NOTES: 1. Rows C and D are not required on 8-bit modules. 2. B10 and C19 are key locations. WinSystems uses key pins as connections to GND. 3. Signal timing and function are as specified in ISA specification. 4. Signal source/sink current differ from ISA values.
  • Page 9: Software Summary

    Software Summary WS16C48 Register Definitions – The PCM-UIO48B uses the WinSystems exclusive ASIC device, the WS16C48. This device provides 48 lines of digital I/O. There are 17 unique registers within the WS16C48. The following table summarized the registers and the text that follows provides details on each of the internal registers.
  • Page 10 A bit when read as a 1 indicates that an edge of the polarity programmed into the corresponding polarity register has been recognized. Note that a write to this register (value ignored) clears ALL of the pending interrupts in this register. 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 11: Ws16C48 Programming Reference

    – a value from 1 to 48 specifying the I/O pin to read from. This function returns the state of the I/O pin. A 1 is returned if the I/O pin is low and a 0 is returned if the pin is high. 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 12 This function clears the specified I/O bit. Note that clearing the I/O bit results in the actual I/O pin going high. This function does not affect any bits other than the one specified. 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 13 There is no return value and no harm is done by calling this function for a bit which did not have edge detection interrupts enabled. There is no effect on any other bits. 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 14 Port 2 Bit 7. It is necessary to use either clr_int() or disab_int() to avoid returning the same bit continuously. This function may be used in an application’s ISE or can be used in the foreground to poll for bit transitions. 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 15: Sample Programs

    Sample Programs There are three sample programs in source code form included on the PCM-UIO48B diskette. These programs are not useful by themselves but are provided to illustrate the usage of the I/O functions provided in UIO48.C. FLASH.C This program was compiled with Borland C/C++ version 3.1 on the command line with: bcc flash.c uio48.c...
  • Page 16: C Source Code Listings

    “As-is” basis and no warranty as to performance, fitness of purposes, or any other warranty is expressed or implied. In no case shall WinSystems be liable for any direct or indirect loss or damage, real or consequential resulting from the usage of this source code.
  • Page 17 “As-is” basis and no warranty as to performance, fitness of purposes, or any other warranty is expressed or implied. In no case shall WinSystems be liable for any direct or indirect loss or damage, real or consequential resulting from the usage of this source code.
  • Page 18 * return value : The current state of the specified bit, 1 or 0. * This function returns the state of the current I/O pin specified by * the argument bit_number. *================================================================= ==========*/ int read_bit(int bit_number) unsigned port; int val; 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 19 = (bit_number / 8) + base_port; /* Use the image value to avoid having to read the port first. */ temp = port_images[bit_number / 8]; /* Get current value */ /* Calculate a bit mask for the specified bit */ 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 20 /*================================================================ =========== CLR_BIT * This function takes a single argument : * bit_number : The bit number to clear. * This function clears the specified bit. *================================================================= ==========*/ void clr_bit(int bit_number) write_bit(bit_number,0); /*================================================================ =========== ENAB_INT 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 21 /* Get current polarity settings */ /* Set the polarity according to the argument in the image value */ if(polarity) /* If the bit is to be set */ temp = temp | mask; else temp = temp & ~mask; 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 22 /* Clear the enable bit int the image for our bit number */ temp = temp & ~mask; /* Update the enable register with the new information */ outportb(port,temp); /* Set access back to page 0 */ outportb(base_port+7,0x0); 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 23 /* clear the enable for this bit */ /* Write out the temporary value */ outportb(port,temp); /* Re-enable our interrupt bit */ temp = temp | mask; /* Write it out */ outportb(port,temp); /* Set access back to page 0 */ 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 24 !=0) for(x=0; x <=7; x++) if(temp & (1 << x)) outportb(base_port+7,0); /* Turn off access */ return(x+1); /* Return bitnumber with active int */ /* None in Port 0, read port 1 interrupt ID register */ 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 25 /* Return bitnumber with active int */ /* We should never get here unless the hardware is misbehaving but just to be sure. We’ll turn the page access back to 0 and return a 0 for no interrupt found. outportb(base_port+7,0); return 0; 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 26 “As-is” basis and no warranty as to performance, fitness of purposes, or any other warranty is expressed or implied. In no case shall WinSystems be liable for any direct or indirect loss or damage, real or consequential resulting from the usage of this source code.
  • Page 27 “As-is” basis and no warranty as to performance, fitness of purposes, or any other warranty is expressed or implied. In no case shall WinSystems be liable for any direct or indirect loss or damage, real or consequential resulting from the usage of this source code.
  • Page 28 /* If it’s 0 there are none pending */ if(current == 0) return; /* Clear and rearm this one so we can get it again */ clr_int(current); /* Tally a transition for this bit */ ++int_counts[current]; 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 29 “As-is” basis and no warranty as to performance, fitness of purposes, or any other warranty is expressed or implied. In no case shall WinSystems be liable for any direct or indirect loss or damage, real or consequential resulting from the usage of this source code.
  • Page 30 /* Disable interrupts while we restore things */ disable(); /* Mask off the interrupt at the interrupt controller */ outportb(0xa1,inportb(0xa1) | 0x02); /* Mask IRQ 10 */ /* Restore the old handler */ 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 31 /* Get the next one, if any others pending */ current = get_int(); /* Issue a non-specific end of interrupt command (EOI) to the interrupt controller. This rearms it for the next shot. outportb(0xa0,0x20); /* Do non-specific EOI */ outportb(0x20,0x20); 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 32: Cables

    *Only available for models: PCM-UIO48B-16 Software Drivers & Examples Examples (For WS16C48 Digital I/O Chip) Linux Drivers - Kernel 2.2, 2.4 linux_uio48_96.zip Linux Drivers - Kernel 2.6 uio48io_kernel_2.6.zip DOS Example C Functions uio48a.zip Windows XP Driver wsuio48_96xp.zip 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 33: Jumper Reference

    Base I/O PC/104 Address Bus (8-bit) Selection Connector Jumper NOTE: The reference line to each component part has been drawn to Pin 1, where applicable. Pin 1 is also highlighted with a red square, where applicable. 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 34 Interrupt Routing IRQ7 1 o o 2 IRQ15 IRQ6 3 o o 4 IRQ14 IRQ5 5 o o 6 IRQ12 IRQ4 7 o o 8 IRQ11 IRQ3 9 o o 10 IRQ10 IRQ2 11 o o 12 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 35 3 o o 4 I/O Base Address Select jumper 5 o o 6 J3 shown jumpered for 200H 7 o o 8 9 o o 10 11 o o 12 13 o o 14 15 o o 16 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 36: Specifications

    :FR-4 Epoxy glass with 2 signal layers 2 power planes, screened component legend, and plated through holes. Jumpers :0.025” square posts on 0.10” centers Connectors :50-pin 0.10” grid RN type IDH-50-LP Environmental Operating Temperature :-40°C to +85° C Noncondensing humidity :5% to 95% 110425 OPERATIONS MANUAL PCM-UIO48B...
  • Page 37: Warranty Repair Information

    Notwithstanding anything herein to the contrary, this warranty granted by WinSystems to the Customer shall be for the sole benefit of the Customer, and may not be assigned, transferred or conveyed to any third party. The sole obligation of WinSystems for...

Table of Contents