The MADGECS utility for replacing Card Services
===============================================
                                              CSS 1.0(0), January 1997 
                                              ------------------------
Summary
-------

MADGECS is a Card Services  emulator  for  Madge  CardBus  and  PCMCIA 
adapters.   It  is  a  replacement  for  Card  Services  and,  on some 
computers, it can also replace Socket Services.

This file has the following sections: 
   
   1) Introduction
   2) Installing Madge Card Services for DOS 
   3) Installing Madge Card Services for OS/2


1) Introduction 
--------------- 
Card Services is a software layer  which  allows  driver  software  to 
configure  and  communicate  with  CardBus  or  PCMCIA  cards inside a 
computer.  Card Services accesses the  computer's  CardBus  or  PCMCIA 
controller  through  another  a software layer called Socket Services. 
Socket  Services  is  specific  to  the  type  of  CardBus  or  PCMCIA 
controller in the machine.

You can only load one instance of Card Services onto a computer.  This 
instance of Card Services then controls all of the CardBus  or  PCMCIA 
cards  installed  in  the  PC.  Also, most computers use only a single 
instance of Socket Services, although computers that contain more than 
one CardBus or PCMCIA controller can have more than  one  instance  of 
Socket Services running.

Most  portable  computers  are supplied with Card and Socket Services. 
These are generally two separate device drivers which are loaded  from 
CONFIG.SYS. If the computer you are using does not have Card Services, 
contact your PC supplier, or use the Madge Card Services software.


**********************************************************************
Note: The Madge Card Services interface is  designed  exclusively  for 
      the  Madge  16/4 CardBus Adapter and the Madge Smart 16/4 PCMCIA 
      Ringnode. You  cannot  use  it  with  any  other  manufacturers' 
      CardBus or PCMCIA adapters.
**********************************************************************
     
*  The Madge Card Services interface for DOS is called MADGECS.EXE. By 
   default MADGECS for DOS only emulates Card  Services;  it  requires 
   you  to  load  the  Socket  Services  supplied  with your computer. 
   However, if your computer has a CardBus or PCMCIA  controller  that 
   MADGECS  can  communicate  with (see below), then you can configure 
   MADGECS to emulate Socket Services as well (see Section 2.5).

*  The  Madge  Card Services interface for OS/2 is called MADGECS.SYS. 
   MADGECS for OS/2 emulates both Card and Socket Services - it cannot 
   work with the Socket Services  supplied  with  your  computer.  For 
   MADGECS  to  work  in  your  computer,  you  must have an Intel (or 
   compatible) PCMCIA controller, or  one  of  the  following  CardBus 
   controllers inside the PC:

   *  The Texas Instruments PCI1130 or PCI1131 CardBus controller.
   *  The Toshiba ToPIC95 CardBus controller.
   *  The Cirrus Logic CL-PD6832 CardBus controller.

   
Since  MADGECS only provides Card Services for Madge adapter software, 
MADGECS is smaller  and  uses  less  DOS  memory  than  standard  Card 
Services.  If you use MADGECS to emulate Socket Services, you can save 
even more memory.  However, to use MADGECS to emulate Socket Services, 
you  must have either an Intel (or Intel-compatible) PCMCIA controller 
or one of the following CardBus controllers:

   *  The Texas Instruments PCI1130 or PCI1131 CardBus controller.
   *  The Toshiba ToPIC95 CardBus controller.
   *  The Cirrus Logic CL-PD6832 CardBus controller.
      
***********************************************************************
Note: A  standard Card Services for DOS that uses DPMS and is resident 
      mostly  in  extended  memory  will  use  less  DOS  memory  than 
      MADGECS.EXE. MADGECS.EXE does not take advantage of DPMS.
***********************************************************************

      
      
2) Installing Madge Card Services for DOS 
-----------------------------------------

2.1 Socket Services
-------------------

To use CardBus Adapters, your Socket Services must conform to version 
5.00 (or above) of the PCMCIA specification for Socket Services. This 
specification includes support for 16-bit PCMCIA cards.
      
By default, MADGECS.EXE requires you to have Socket  Services  loaded.  
However,  the  porgram includes an EMULATE_SOCKET-SERVICES option that 
enables you to run it without  Socket  Services  already  loaded  (see 
Section 1). 

********************************************************************** 
Note: If   you  are  not using the EMULATE_SOCKET_SERVICES option, you 
      must run MADGECS after loading Socket Services.
**********************************************************************

You  can configure MADGECS from the command line or from a script file 
called MADGECS.CFG (see Section 2.5).



2.2 Loading MADGECS.EXE from CONFIG.SYS or AUTOEXEC.BAT
-------------------------------------------------------
Perform one of the following:

*  Load  MADGECS  from  the CONFIG.SYS file by including the following 
   statement before any statements that load network drivers:

   DEVICE=<path>MADGECS.EXE   
 
*  Load MADGECS from the AUTOEXEC.BAT file by  including the following 
   command before any commands that load network drivers:
   
   <path>MADGECS
      
2.3 Using MADGECS.EXE with Memory Managers or with  Microsoft  Windows 
----------------------------------------------------------------------
      
**********************************************************************      
Note: This release of the  Card  Support  Software  does  not  support 
      Novell Client 32.
**********************************************************************

MADGECS  needs an 8Kb region of upper memory (memory between 640Kb and 
1Mb) to be  available.   If  you  are  using  any  Smart  16/4  PCMCIA 
Ringnodes  in  MMIO  transfer mode, then you need an additional 4Kb of 
upper memory for each adapter.

The upper memory area is reserved for use by ROMs and expansion  cards 
and  does  not  normally  contain  any  RAM.  However, on 386 or later 
processors memory manager software (such as EMM386) can be used to map 
RAM from above  1Mb  into  upper  memory.  This  mapped  RAM  is  then 
available  to  DOS  programs.   If you are using a memory manager, you 
must make sure that the areas of upper memory that the memory  manager 
uses do not clash with the areas that MADGECS uses.

By default, MADGECS tries to find 12Kbytes of upper memory tha is  not 
being  used  by  a  memory manager. It will use the range CC00-CDFF if 
this is available. You can configure it  to  use  a  different  memory 
range by editing the MADGECS configuration file (see Section 2.5).

The following are examples of how to prevent  the  memory  range  that 
MADGECS  uses by default from being used by different memory managers. 

For:

*  Windows,  add  the  command  EMMExclude=C800-CAFF to the SYSTEM.INI 
   file.
  
*  EMM386, add the parameter X=C800-CAFF to the device line in the 
   CONFIG.SYS file. 
  
*  386MAX, add the parameter RAM=C800-CAFF to the device line in the 
   CONFIG.SYS file. 

For  more  information,  refer to the documentation supplied with your 
Microsoft Windows or memory management software.
   

2.4  Command line options for MADGECS.EXE
-----------------------------------------
To  specify  MADGECS  configuration  options  on  the  device  line in 
CONFIG.SYS, use the following syntax:   

DEVICE=<path>MADGECS.EXE [options]

To specify MADGECS  configuration  options  on  the  command  line  in 
AUTOEXEC.BAT, use the following syntax:

MADGECS [options]

Note that some options can be specified either on the command line  or 
in  the MADGECS configuration file (see Section 2.5). We recommend you 
to use one or the other method, but not both.

The  available  command-line  options  are   described   below   (with 
abbreviations in brackets):

HELP (?)                                Display help information

UNLOAD (U)                              Unload MADGECS

BRIEF (BR)                              Do not  display  configuration 
                                        information.

CONFIGURATION_FILE=<filename>
(CFG=<filename>)                        Name  (including  location) of 
                                        the  CFG  file.  The   default 
                                        location is the directory that 
                                        contains    MADGECS.EXE.   The 
                                        default      filename       is 
                                        MADGECS.CFG.  
                                        
                                        Example: 
                                        MADGECS CFG=C:\PCM\MADGECS.CFG

SILENT (SI)                             Turn   off   card   insertion/
                                        ejection sounds.

EMULATE_SOCKET_SERVICES (ESS)           Emulate Socket   Services.  If 
                                        you specify this option,  make 
                                        sure you do not load any other 
                                        type  of  Socket  Services  in 
                                        your PC. Only use this  option 
                                        if   your   PC   contains  the 
                                        correct  PCMCIA   or   CardBus 
                                        controller (see Section 1). 

AUTOMATIC_CONFIGURATION=ONLY_ON_LOAD
(ACONF=OOL)                             Configure any Madge PCMCIA  or 
                                        CardBus adapters automatically 
                                        when   MADGECS   loads.   (See 
                                        Section 2.6).

AUTOMATIC_CONFIGURATION=ALWAYS
(ACONF=ALWAYS)                          Configure any Madge PCMCIA  or 
                                        CardBus adapters automatically 
                                        (including    any   that   are 
                                        installed  after  MADGECS  has 
                                        loaded). (See Section 2.6.)

CLIENT_32                               Enable   support   for  Novell 
                                        Client32. (See Section 2.6).


2.5 Configuration-file options for MADGECS
------------------------------------------
By  default,  MADGECS   looks  for   a   configuration   file   called 
MADGECS.CFG.  However, you do not have to use a configuration file if
your requirements can be specified on the command line.

A sample MADGECS.CFG is provided with MADGECS. It contains much of the 
following information in  the  form  of  comments,  and  is  a  useful 
starting point for creating a MADGECS.CFG of your own.

********************************************************************** 
Note: If you are using a MADGECS.CFG file, put the file  in  the  same 
      directory  as  MADGECS.EXE, or use the /CFG=<filename> parameter 
      when you run the program (see Section 2.4). 
**********************************************************************

You can use spaces and tab characters within the  configuration  file. 
Comments need to be preceded by a semi-colon.

                                        
EMULATE_SOCKET_SERVICES=YES
(ESS=Y)                                 Emulate Socket  Services.   If 
                                        you  specify this option, make 
                                        sure you do not load any other 
                                        type  of  Socket  Services  in 
                                        your  PC. Only use this option 
                                        if  your   PC   contains   the 
                                        correct   PCMCIA   or  CardBus 
                                        controller (see Section 1). 
                                        
ONLY_CARDBUS=YES                        Only support CardBus adapters.
(CBUS=Y)                                This reduces the resident size
                                        of MADGECS.

ONLY_PCMCIA=YES                         Only support PCMCIA Ringnodes.
(PCMC=Y)                                This reduces the resident size
                                        of MADGECS.
                                        


You  can  use  the  following options to adjust the lists that MADGECS 
keeps of the I/O locations, interrupt lines, and  memory  ranges  that 
are  available for Madge adapters. When MADGECS loads, it displays the 
lists it will use.

MADGECS tries to choose safe deafults for all three lists. Because the 
program creates its lists of safe defaults by examining  the  computer 
it  is  running in, the lists will vary from computer to computer.  
                                        

DEFAULT_MEMORY = NO                     Use  this  option   to   force 
                                        MADGECS.CFG  to  use  only the 
                                        memory ranges that you specify 
                                        in MADGECS.CFG.

DEFAULT_IO = NO                         Use  this  option   to   force 
                                        MADGECS  to  use  only the I/O 
                                        ranges that you   specify    in 
                                        MADGECS.CFG.

DEFAULT_INTERRUPTS = NO                 Use  this  option   to   force 
                                        MADGECS   to   use   only  the 
                                        interrupts that you specify in 
                                        MADGECS.CFG.  

USE_MEMORY=xxxx-yyyy, ... 
(MEM=xxxx-yyyy, ...)                    Use this option to add an area 
                                        of memory to MADGECS's list of 
                                        available memory.   Make  sure 
                                        that  the  new  area  area you 
                                        specify  starts  at  an   xx00 
                                        address.
										 
					Make  sure  also that the area 
					you specify is at least 8Kb in 
					length,  and  that  it  is   a 
					multiple  of  4Kb  in  length.  
					(MADGECS needs  an  additional 
					4Kb for each Smart 16/4 PCMCIA 
					Ringnode  that  is  running in 
					MMIO mode.) To add  more  than 
					one  area  of  memory  to  the 
					list,  use  a  comma-separated 
					list.
            
                                        You must prevent the  area  of 
                                        memory  that MADGECS uses from 
                                        being  mapped  by  Windows  or 
                                        memory  managers. For example, 
                                        if        you        specified 
                                        USE_MEMORY=D000-D0FF,D800-D9FF 
                                        in  MADGECS.CFG, then you must 
                                        put  the  following   on   the 
                                        EMM386 command line: 
                                        
                                        X=D000-D0FF X=D800-D9FF
                                         
                                        
EXCLUDE_MEMORY=xxxx-yyyy,  ... 
(XMEM=xxxx-yyyy,  ...)                  Use   this  option  to  remove 
                                        areas of memory from MADGECS's 
                                        list of available memory.   To 
                                        remove  more  than one area of 
                                        memory from  the  list  use  a 
                                        comma-separated list.

**********************************************************************
NOTE: MADGECS  follows the convention used by memory managers, such as 
      EMM386, for specifying memory ranges.  This means that you  need 
      to specify memory addresses in hexadecimal, with the last (least 
      significant) digit removed.  The memory ranges need to be ranges 
      of  upper  memory.  Upper memory is memory from 640Kbytes (A000) 
      to just under 1Mbyte (FFFF).  The lower end  of  this  range  is 
      normally  used  for  video controllers, and the upper end of the 
      range is normally used for the BIOS. This leaves  C000  to  DFFF 
      free.  You will not need more than 12Kbytes (that is, 3000 bytes 
      in   hexadecimal).    A  typical  12Kbyte  range  is  D000-D2FF.  
      (Remember that the you need to remove the last digit,  and  that 
      the range is inclusive. For example, do not specify D000-D2FF as 
      D000-D300.   To  do  so  is  to include the first byte after the 
      range that you require.)      
**********************************************************************

                                        
USE_IO=xxxx-yyyy, ...           
(IO=xxxx-yyyy, ...)     		Use this  option  to  add  I/O 
					ranges  to  MADGECS's  list of 
					available  ranges.   You  must 
					specify  them  in hexadecimal.  
					To specify more than one,  use 
					a comma-separated list.

EXCLUDE_IO=xxxx-yyyy, ...   
(XIO=xxxx-yyyy, ...)                    Use  this option to remove I/O 
                                        locations from MADGECS's  list 
                                        of available I/O locations. To 
                                        remove  more  than  one, use a 
                                        comma-separated list.
      
**********************************************************************
NOTE: You need to specify I/O ranges  in  hexadecimal  notation.   The 
      ranges  are inclusive. A Madge PCMCIA Ringnode requires 32 bytes 
      (20h bytes) of I/O space. A Madge CardBus Adapter  requires  256 
      bytes (100h bytes) of I/O space. The start of an I/O range needs 
      to  be  a  multiple  of  the  size  of  the range.  For example, 
      9000-90FF would be a suitable I/O range for a CardBus card,  but 
      9010-910F would not. 
**********************************************************************
        
USE_INTERRUPT=n, ...   
(INT=n, ...)                            Use   this   option   to   add 
                                        interrupts to  MADGECS's  list 
                                        of    available    interrupts.  
                                        Specify interrupt  numbers  in 
                                        decimal  format.   To  specify 
                                        more than  one,  use  a  comma 
                                        separated list.

EXCLUDE_INTERRUPT=n, ...      
(XINT=n, ...)                           Use  this  option  to   remove 
                                        interrupts from MADGECS's list 
                                        of  available  interrupts.  To 
                                        remove more than  one,  use  a 
                                        comma-separated list.


**********************************************************************                                  
NOTE: The  interrupt  that  the  Madge  16/4  CardBus  Adapter uses is 
      normally determined by the CardBus slot that the adapter is  in. 
      If the CardBus slot has a fixed interrupt, MADGECS displays this 
      interrupt  when  it  loads.  On some computers, CardBus adapters 
      share interrupts with adapters in other CardBus slots.   If  you 
      are  using  a PCMCIA Ringnode, then MADGECS assigns an interrupt 
      to the Ringnode from its list of available interrupts.  This  is 
      true  even  if  you  have  inserted  the  PCMCIA Ringnode into a 
      CardBus slot. If your computer's CardBus slot does  not  have  a 
      fixed  interrupt  number, MADGECS will assign the interrupt from 
      its list of available interrupts.      
**********************************************************************

EXCLUDE_SLOT=n, ...                     Use  this  option  to  prevent 
                                        MADGECS   from   accessing  an 
                                        adapter at a  partiulcar slot.  
                                        For  example,  you  could  use 
                                        this   parameter   to  prevent 
                                        MADGECS  from   accessing   an 
                                        adapter      from      another 
                                        manufacturer  which  has  been 
                                        configured   by   means  of  a 
                                        "Point Enabler".

BRIEF=YES  
(BR=Y)                                  Use  this  option  to  prevent 
                                        MADGECS     from    displaying 
                                        configuration  information  on 
                                        the screen.
                                        
SILENT=YES
(SI=Y)                                  Use  this  option  to turn off 
                                        card        insertion/ejection 
                                        sounds.

AUTOMATIC_CONFIGURATION=ONLY_ON_LOAD
(ACONF=OOL)                             Use  this  option to configure 
                                        any Madge  PCMCIA  or  CardBus 
                                        adapters   automatically  when 
                                        MADGECS loads.   (See  Section 
                                        2.6).

                                        
AUTOMATIC_CONFIGURATION=ALWAYS
(ACONF=ALWAYS)                          Use  this option  to configure 
                                        any Madge  PCMCIA  or  CardBus 
                                        adapters         automatically 
                                        (including   any   that    are 
                                        installed  after  MADGECS  has 
                                        loaded). (See Section 2.6.)
                                        
                                                                                                               
AUTOMATICALLY_CONFIGURED_SLOT=n, ...
(ACSLOT=n, ...)                         Use  this  option  to restrict 
					autoconfiguration of  adapters 
					to specific slots. By default, 
					adapters   in  all  slots  are 
					configured automatically. This 
					option only has effect if  you 
					specify  any  of the following 
					parameters:
					 
					AUTOMATIC_CONFIGURATION=ALWAYS 
					
					or:
					
					AUTOMATIC_CONFIGURATION=ONLY_ON_LOAD
					
					or:
					
					CLIENT_32=YES	
					
                                                                                
CLIENT_32=YES                           Enable   support   for  Novell 
                                        Client32. (See Section 2.6).

                                        
                                          
The following is a sample MADGECS.CFG file:

----------------------------------------------------------------------
| ; Configuration file for use with MADGECS                          |
| EMULATE_SOCKET_SERVICES=YES                                        |
| EXCLUDE_IO=8000-8080           ; Do not use these I/O locations.   |
| EXCLUDE_INT=3,5                ; Do not use these interrupts.      |
| USE_INT=10,11                  ; Use these interrupts.             |
| EXCLUDE_MEMORY=CC00-CDFF       ; Do not use 8Kb memory range CC00- |
|                                  CDFF.                             |
| USE_MEMORY=D000-D1FF           ; Use 8Kb memory range D000-D1FF.   |
----------------------------------------------------------------------


2.6  PCMCIA Ringnode Auto-Configuration and Novell Client32
----------------------------------------------------------------------

**********************************************************************
Note: This release of the CardBus Support Software  does  not  support 
      Novell Client 32.
**********************************************************************
The interrupt number, I/O location, and memory window resources of the 
adapter need to be configured by Card Services before the  driver  can 
use the adapter.

There  are  two ways for this to happen:

(1) The driver itself can ask Card Services to configure the  adapter. 
    In this case, the driver is said to be Card Services aware.
    
(2) A separate utility can ask Card Services to configure the adapter. 
    Once  the  adapter  has  been  configured,  the driver can use it. 
    Since, in this case, the  driver  does  not  interface  with  Card 
    Services, it is not Card Services aware.

All  Madge  PCMCIA Ringnode drivers, with the exception of CMDGODI.LAN 
(the driver for Novell Client32) are Card Services aware and are  able 
to  configure  PCMCIA  Ringnodes  themselves.  Madge drivers, with the 
exception of CMDGODI.LAN, therefore, do  not  require  you  to  use  a 
separate  utility  to  configure the adapters.  Most DOS Card Services 
are provided with an auto-configuration/card management utility  which 
has  the  ability  to configure certain cards upon detection.  MADGECS 
can also do this, so a separate utility is not needed.

If you need MADGECS  to  auto-configure  the  adapter,  then  set  the 
AUTOMATIC_CONFIGURATION parameter (see Sections 2.4 and 2.5).

* Specifying  AUTOMATIC_CONFIGURATION=ONLY_ON_LOAD  will cause MADGECS 
  to auto-configure those PCMCIA adapters that are in the computer  at 
  the time MADGECS loads.  Any adapters subsequently inserted will not 
  be configured.

* Specifying  AUTOMATIC_CONFIGURATION=ALWAYS  will  cause  MADGECS  to 
  auto-configure Madge PCMCIA adapters when they are inserted (as well 
  as those in the computer when MADGECS loads).  Only use this if  you 
  wish  to  hot  swap  adapters  (less  memory is used if adapters are 
  configured "only on load").


If  you  are running MADGECS in a Novell Client32 for DOS environment, 
you must specify CLIENT_32 on the command line or in the configuration 
file, and you must use one of the auto-configure options. In fact,  if 
you   use   the  CLIENT_32  option,  MADGECS  defaults  to  performing 
auto-configuration "only on load".


3) Installing Madge Card Services for OS/2
------------------------------------------

3.1 Socket Services
-------------------
If you are installing Madge Card Services for OS/2, ensure that you do 
not  have  any third party Socket Services software installed. MADGECS 
for OS/2 will always emulate Socket Services  and  therefore  requires 
that the computer contain an Intel (or compatible) PCMCIA controller 
or one of the following CardBus controllers:

   *  The Texas Instruments PCI1130 or PCI1131 CardBus controller.
   *  The Toshiba ToPIC95 CardBus controller.
   *  The Cirrus Logic CL-PD6832 CardBus controller.


3.2 Loading MADGECS.SYS from CONFIG.SYS
---------------------------------------
To  replace  Card  and  Socket  Services  on an OS/2 workstation, load 
MADGECS.SYS by adding the following line to CONFIG.SYS:

DEVICE=<path>MADGECS.SYS


3.3 Command-line options for MADGECS.SYS
----------------------------------------
The command-line  options  for  MADGECS.SYS  are  the  same  as  those 
described in Section 2.4 with the following exceptions:

*  MADGECS.SYS cannot be unloaded (the /U option is not available).

*  EMULATE_SOCKET_SERVICES is not required.

*  The   AUTOMATIC_CONFIGURATION  and  CLIENT_32  parameters  are  not
   available.


3.4 Configuration file options for MADGECS.SYS
----------------------------------------------
You  can  configure MADGECS.SYS from a MADGECS.CFG file in exactly the 
same way as is described in Section  2.5.   If  you  do  not  want  to 
configure MADGECS.SYS, you do not need to create a MADGECS.CFG file.





                 ****** End of MADGECS.TXT *******