linux-old/Documentation/digiboard.txt
<<
>>
Prefs
   1The Linux Digiboard Driver
   2--------------------------
   3
   4The Digiboard Driver for Linux supports the following boards:
   5
   6 DigiBoard PC/Xi, PC/Xe, PC/Xeve(which is the newer, smaller Xe with
   7 a 8K window which is also known as PC/Xe(8K) and has no memory/irq
   8 switches) You can use up to 4 cards with this driver and it should work
   9 on other architectures than intel also.
  10
  11In case you have problems with this version (1.6.1) of this driver, please
  12email directly to me as I made the last update. It you have a report about
  13running it on other architectures than intel, email me, so I can document
  14it here.
  15
  16A version of this driver has been taken by Digiboard to make a driver
  17software package which supports also PC/Xem cards and newer PCI cards
  18but it doesn't support the old PC/Xi cards and it isn't yet ported to
  19linux-2.1.x and may not be usable on other architectures than intel now.
  20It is available from ftp.digi.com/ftp.digiboard.com. You can write me if
  21you need an patch for this driver.
  22
  23  Bernhard Kaindl (bkaindl@netway.at)  6. April 1997.
  24
  25Configuring the Driver
  26----------------------
  27
  28The driver can be built direct into the kernel or as a module.
  29The pcxx driver can be configured using the command line feature while
  30loading the kernel with LILO or LOADLIN or, if built as a module,
  31with arguments to insmod and modprobe or with parameters in
  32/etc/conf.modules for modprobe and kerneld.
  33
  34After configuring the driver you need to create the device special files
  35as described in "Device file creation:" below and set the appropriate
  36permissions for your application.
  37
  38As Module
  39---------
  40
  41modprobe pcxx io=<io> \
  42  membase=<membase> \
  43  memsize=<memsize> \
  44  numports=<numports>  \
  45  altpin=<altpin> \
  46  verbose=<verbose>
  47
  48or, if several cards are installed
  49
  50modprobe pcxx io=<io-1>,<io-2>,... \
  51  membase=<membase-1>,<membase-2>,... \
  52  memsize=<memsize-1>,<memsize-2>,... \
  53  numports=<numports-1>,<numports-2>,... \
  54  altpin=<altpin-1>,<altpin-2>,... \
  55  verbose=<verbose>
  56
  57where <io-N> is the io address of the Nth card and <membase-N> is the
  58memory base address of the Nth card, etc.
  59
  60The parameters can be specified in any order. For example, the numports
  61parameter can precede the membase parameter, or vice versa. If several
  62cards are installed the ordering within the comma separated parameter
  63lists must be consistent, of course.
  64
  65io       - I/O port address of that card.
  66membase  - Memory start address of that card.
  67memsize  - Memory size of that card, in kilobytes. If given, this value
  68           is compared against the card to verify configuration and
  69           hinder the driver from using a misconfigured card. If the parameter
  70           does not match the board it is disabled with a memory size error.
  71numports - Number of ports on this card. This is the number of devices to
  72           assign to this card or reserve if disabled.
  73altpin   - 1: swap DCD and DSR for 8-pin RJ-45 with modems.
  74           0: don't swap DCD and DSR.
  75           other values count as 1.
  76verbose  - 1: give nice verbose output during initialisation of the driver,
  77              possibly helpful during board configuration.
  78           0: normal terse output.
  79
  80Only the parameters which differ from the defaults need to be specified.
  81If the io= parameter is not given, the default config is used. This is
  82
  83  io=0x200 membase=0xD0000 numports=16 altpin=0
  84
  85Only applicable parameters need be specified. For example to configure
  862 boards, first one at 0x200 with 8 ports, rest defaults, second one at
  870x120, memory at 0xD80000, altpin enabled, rest defaults, you can do this
  88by using these parameters:
  89
  90  modprobe pcxx io=0x200,0x120 numports=8,8 membase=,0xD80000 altpin=,1
  91
  92To disable a temporary unusable board without changing the mapping of the
  93devices following that board, you can empty the io-value for that board:
  94
  95  modprobe pcxx io=,0x120 numports=8,8 membase=,0xD80000 altpin=,1
  96
  97The remaining board still uses ttyD8-ttyD15 and cud8-cud15.
  98
  99Example line for /etc/conf.modules for use with kerneld and as default
 100parameters for modprobe:
 101
 102options pcxx           io=0x200 numports=8
 103
 104For kerneld to work you will likely need to add these two lines to your
 105/etc/conf.modules:
 106
 107alias char-major-22    pcxx
 108alias char-major-23    pcxx
 109
 110
 111Boot-time configuration when linked into the kernel
 112---------------------------------------------------
 113
 114Per board to be configured, pass a digi= command-line parameter to the
 115kernel using lilo or loadlin. It consists of a string of comma separated
 116identifiers or integers.  The 6 values in order are:
 117
 118Card status:      Enable      - use that board
 119                  Disable     - don't actually use that board.
 120
 121Card type:        PC/Xi       - the old ones with 64/128/256/512K RAM.
 122                  PC/Xe       - PC/Xe(old ones with 64k mem range).
 123                  PC/Xeve     - PC/Xe(new ones with 8k mem range).
 124
 125Note: This is for documentation only, the type is detected from the board.
 126
 127Altpin setting:   Enable      - swap DCD and DSR for 8-pin RJ-45 with modems.
 128                  Disable     - don't swap DCD and DSR.
 129
 130Number of ports:  1 ... 16    - Number of ports on this card. This is the
 131                                number of devices to assign to this card.
 132
 133I/O port address: eg. 200     - I/O Port address where the card is configured.
 134
 135Memory base addr: eg. 80000   - Memory address where the board's memory starts.
 136
 137This is an example for a line which you can insert into you lilo.conf:
 138
 139   append="digi=Enable,PC/Xi,Disable,4,120,D0000"
 140
 141there is an alternate form, in which you must use decimal values only:
 142
 143   append="digi=1,0,0,16,512,851968"
 144
 145If you don't give a digi= command line, the compiled-in defaults of
 146board 1: io=0x200, membase=0xd0000, altpin=off and numports=16 are used.
 147
 148If you have the resources (io&mem) free for use, configure your board to
 149these settings and you should be set up fine even if yours has not got 16 
 150ports.
 151
 152
 153Sources of Information
 154----------------------
 155
 156Web page: http://private.fuller.edu/clameter/digi.html
 157
 158Mailing list: digiboard@list.fuller.edu
 159
 160(Write e-mail to that address to subscribe. Common ListServ commands work.
 161Archive of messages available)
 162
 163Christoph Lameter (clameter@fuller.edu) 16. April 1996.
 164
 165Supporting Tools
 166----------------
 167
 168Some tools and more detailed information can be found at
 169ftp://ftp.fuller.edu/Linux/digi
 170
 171The "ditty" tool described in the Digiboard Manuals for other Unixes
 172is also available.
 173
 174
 175Device file creation
 176--------------------
 177
 178Currently the Linux MAKEDEV command does not support generating the Digiboard
 179Devices. 
 180
 181The /dev/cud devices behave like the /dev/cua devices
 182and the ttyD devices are like the /dev/ttyS devices.
 183
 184Use the following script to generate the devices:
 185
 186------------------ mkdigidev begin
 187#!/bin/sh
 188#
 189# Script to create Digiboard Devices
 190# Christoph Lameter, April 16, 1996
 191#
 192# Usage:
 193# mkdigidev [<number of devices>]
 194# 
 195
 196DIGI_MAJOR=23
 197DIGICU_MAJOR=22
 198
 199BOARDS=$1
 200
 201if [ "$BOARDS" = "" ]; then
 202BOARDS=1
 203fi
 204
 205boardnum=0
 206while [ $boardnum -lt $BOARDS ];
 207do
 208  for c in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15;
 209  do
 210        name=`expr $boardnum \* 16 + $c`
 211        mknod /dev/cud$name c $DIGICU_MAJOR $name
 212        mknod /dev/ttyD$name c $DIGI_MAJOR $name
 213  done
 214  boardnum=`expr $boardnum + 1`
 215done
 216------------------ mkdigidev end
 217
 218or apply the following patch to /dev/MAKEDEV and do a 
 219sh /dev/MAKEDEV digi
 220
 221----- MAKEDEV Patch
 222--- /dev/MAKEDEV        Sun Aug 13 15:48:23 1995
 223+++ MAKEDEV     Tue Apr 16 17:53:27 1996
 224@@ -120,7 +120,7 @@
 225        while [ $# -ne 0 ]
 226        do
 227                case "$1" in
 228-                       mem|tty|ttyp|cua|cub)   ;;
 229+                       mem|tty|ttyp|cua|cub|cud)       ;;
 230                        hd)     echo hda hdb hdc hdd ;;
 231                        xd)     echo xda xdb ;;
 232                        fd)     echo fd0 fd1 ;;
 233@@ -140,6 +140,7 @@
 234                        dcf)            echo dcf ;;
 235                        pcmcia) ;; # taken care of by its own driver
 236                        ttyC)   echo cyclades ;;
 237+                       ttyD)   echo digi ;;
 238                        *)      echo "$0: don't know what \"$1\" is" >&2 ;;
 239                esac
 240                shift
 241@@ -208,6 +209,15 @@
 242                do
 243                        makedev ttyC$i c $major1 `expr 32 + $i` $tty
 244                        makedev cub$i c $major2 `expr 32 + $i` $dialout
 245+               done
 246+               ;;
 247+       digi)
 248+               major1=`Major ttyD` || continue
 249+               major2=`Major cud` || continue
 250+               for i in 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
 251+               do
 252+                       makedev ttyD$i c $major1 `expr 32 + $i` $tty
 253+                       makedev cud$i c $major2 `expr 32 + $i` $dialout
 254                done
 255                ;;
 256        par[0-2])
 257----- End Makedev patch
 258
 259-----------------------------------------------------------------------------
 260
 261Changes v1.5.5:
 262
 263The ability to use the kernel's command line to pass in the configuration for 
 264boards.  Using LILO's APPEND command, a string of comma separated identifiers 
 265or integers can be used.  The 6 values in order are:
 266
 267   Enable/Disable this card,
 268   Type of card: PC/Xi(0), PC/Xe(1), PC/Xeve(2), PC/Xem(3)
 269   Enable/Disable alternate pin arrangement,
 270   Number of ports on this card,
 271   I/O Port where card is configured (in HEX if using string identifiers),
 272   Base of memory window (in HEX if using string identifiers), 
 273
 274Samples:
 275   append="digi=E,PC/Xi,D,16,200,D0000"
 276   append="digi=1,0,0,16,512,(whatever D0000 is in base 10 :)
 277
 278Drivers' minor device numbers are conserved. This means that instead of
 279each board getting a block of 16 minors pre-assigned, it gets however
 280many it should, with the next card following directly behind it.  A
 281system with 4 2-port PC/Xi boards will use minor numbers 0-7.
 282This conserves some memory, and removes a few hard coded constants.
 283
 284NOTE!! NOTE!! NOTE!!
 285The definition of PC/Xem as a valid board type is the BEGINNING of support
 286for this device.  The driver does not currently recognise the board, nor
 287does it want to initialize it.  At least not the EISA version.
 288
 289Mike McLagan <mike.mclagan@linux.org> 5, April 1996.
 290
lxr.linux.no kindly hosted by Redpill Linpro AS, provider of Linux consulting and operations services since 1995.