Configuring mISDN
From mISDN.org
Initiating the a mISDN Kernel Module as for example hfcmulti
New Style config (mISDN CVS)
The mISDN Kernel Modules can now be easyly configured with the XML Based configuration file /etc/mISDN.conf, this will be the new version of the /etc/misdn-init.conf file. It is at the moment only accessible when using the CVS Version of mISDN, but will be accessible in the 1.1.0 Release of mISDN.
The configuration is pretty much like in elder days, the new tool is just called "mISDN" instead of misdn-init. You can, like before do an:
mISDN scan
and see which cards are installed in the system. Then it makes a lot of sense to get a default configuration with:
mISDN config
This creates the file /etc/mISDN.conf which you should edit now with your favourite Editor:
vi /etc/mISDN.conf
The file looks more or less like:
<?xml version="1.0"?>
<!--
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Card Type: BN2S0, BN4S0, BN8S0
Card Attributes: ulaw=(yes|no), dtmf=(yes|no), pcm_slave=(yes|no),
ignore_pcm_frameclock=(yes|no), rxclock=(yes|no),
crystalclock=(yes|no), watchdog=(yes|no)
Port Attributes: mode=(te|nt), link=(ptp|ptmp), master-clock=(yes|no),
capi=(yes|no)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Card Type: BN2E1
Card Attributes: ulaw=(yes|no), dtmf=(yes|no), pcm_slave=(yes|no),
ignore_pcm_frameclock=(yes|no), rxclock=(yes|no),
crystalclock=(yes|no), watchdog=(yes|no)
Port Attributes: mode=(te|nt), link=(ptp|ptmp), optical=(yes|no), los=(yes|no),
ais=(yes|no), slip=(yes|no), nocrc4=(yes|no), capi=(yes|no)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Card Type: hfcmulti, avmfritz, w6692pci
Port Attributes: mode=(te|nt), link=(ptp|ptmp), capi=(yes|no)
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Module: hfcmulti
Options: poll=<number>, pcm=<number>, debug=<number>
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Module: mISDN_dsp
Options: debug=<number>, options=<number>, poll=<number>,
dtmfthreshold=<number>
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-->
<mISDNconf>
<module poll="128" debug="0">hfcmulti</module>
<module debug="0" options="0">mISDN_dsp</module>
<devnode user="root" group="root" mode="644">mISDN</devnode>
<card type="BN2S0">
<port mode="te" link="ptmp">1</port>
<port mode="te" link="ptmp">2</port>
</card>
<card type="BN8S0">
<port mode="te" link="ptmp">1</port>
<port mode="te" link="ptmp">2</port>
<port mode="te" link="ptmp">3</port>
<port mode="te" link="ptmp">4</port>
<port mode="te" link="ptmp">5</port>
<port mode="te" link="ptmp">6</port>
<port mode="te" link="ptmp">7</port>
<port mode="te" link="ptmp">8</port>
</card>
<card type="BN2E1">
<port mode="nt" link="ptp">1</port>
<port mode="nt" link="ptp">2</port>
</card>
</mISDNconf>
It is pretty much selfexplainable. Now you can just start mISDN like before with:
mISDN start
and whatch if everything is right with:
misdnportinfo
Old Style config (mISDN-1_0_4)
The misdn kernel module must be loaded to use chan_misdn with Asterisk. In our case, the module is named "hfcmulti". In section 3.1 and section 3.2 you decided on a particular port configuration and set the jumpers accordingly. It is not possible to read the configuration of each card by reading the driver. You must identify the individual ports as either TE or NT when loading the driver. In addition, you must specify which ports use "point-to-multi-point" (multiple device connection) or "point-to-point" (single device connection) mode. There are two ways to configure and load the driver modules. One is to load the modules by hand, the other is to use the "misdn-init” script, which is installed in "/etc/init.d" after installation of chan_misdn. Before we describe how to load the drivers, one more hint: Before you load module "hfcmulti", make sure that no other modules can access mISDN, such as CAPI, or modules that support the same chip set, such as hisax or bristuff ! If you want to use the "misdn-init" script, please execute the following command: /etc/init.d/misdn-init scan All installed misdn cards will be displayed. For example: [OK] found the following devices: card=1,0x4 [ii] run "/etc/init.d/misdn-init config" to store this information to /etc/misdn-init.conf This is a status message only. If you want to create a configuration file for the "misdn-init" startup-script, you have to create a file named "misdn-init.conf". This is done with the following command: /etc/init.d/misdn-init config You now have a new "misdn-init.conf" file in the "/etc/" directory. In our case, the file would look like this: # # Configuration file for your misdn hardware # # Usage: /etc/init.d/misdn-init start|stop|restart|config|scan|help # # # Card Settings # # Syntax: card=<number>,<type>[,<option>...] # # <number> count your cards beginning with 1 # <type> either 0x1,0x4 or 0x8 for your hfcmulti hardware, # or the name of your card driver module. # <option> ulaw - uLaw (instead of aLaw) # dtmf - enable DTMF detection on all B-channels # pcm_slave - set PCM bus into slave mode # card=1,0x4 # # Port settings # # Syntax: <port_type>=<port_number>[,<port_number>...] # # <port_type> te_ptp - TE-Mode, PTP # te_ptmp - TE-Mode, PTMP # nt_ptp - NT-Mode, PTP # nt_ptmp - NT-Mode, PTMP # <port_number> port that should be considered # te_ptmp=1,2,3,4 # # Port Options # # Syntax: option=<port_number>,<option>[,<option>...] # # <option> master_clock - use master clock for this S/T interface # (only once per chip, only for HFC 8/4) # optical - optical (only HFC-E1) # los - report LOS (only HFC-E1) # ais - report AIS (only HFC-E1) # slip - report SLIP (only HFC-E1) # #option=1,master_clock #option=2,ais #option=3,optical,los,ais,slip # # General Options for your hfcmulti hardware # # poll=<number> # # Only one poll value must be given for all cards. # Give the number of samples for each fifo process. Now you can modify this file in accordance with your ISDN cards. Every time you enter: /etc/init.d/misdn-init start mISDN will start, using the configuration in your "/etc/misdn-init.conf". If you start miSDN this way, you will get the following output: ----------------------------------------- Loading module(s) for your misdn-cards: ----------------------------------------- modprobe hfcmulti type=0x4 protocol=0x2,0x2,0x2,0x2 layermask=0xf,0xf,0xf,0xf poll=64 debug=0 Now all the configured modules should be loaded. You can verify your configuration with the command: misdnportinfo This will print out a few infos about your ports and their configuration.
