1 HiSax is a Linux hardware-level driver for passive ISDN cards with Siemens
2 chipset (ISAC_S 2085/2086/2186, HSCX SAB 82525). It is based on the Teles
3 driver from Jan den Ouden.
4 It is meant to be used with isdn4linux, an ISDN link-level module for Linux
5 written by Fritz Elfert.
6
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20
21
22 Supported cards
23 ---------------
24
25 Teles 8.0/16.0/16.3 and compatible ones
26 Teles 16.3c
27 Teles S0/PCMCIA
28 Teles PCI
29 Teles S0Box
30 Creatix S0Box
31 Creatix PnP S0
32 Compaq ISDN S0 ISA card
33 AVM A1 (Fritz, Teledat 150)
34 AVM Fritz PCMCIA
35 AVM Fritz PnP
36 AVM Fritz PCI
37 ELSA Microlink PCC-16, PCF, PCF-Pro, PCC-8
38 ELSA Quickstep 1000
39 ELSA Quickstep 1000PCI
40 ELSA Quickstep 3000 (same settings as QS1000)
41 ELSA Quickstep 3000PCI
42 ELSA PCMCIA
43 ITK ix1-micro Rev.2
44 Eicon.Diehl Diva 2.0 ISA and PCI (S0 and U interface, no PRO version)
45 Eicon.Diehl Diva 2.01 ISA and PCI
46 Eicon.Diehl Diva Piccola
47 ASUSCOM NETWORK INC. ISDNLink 128K PC adapter (order code I-IN100-ST-D)
48 Dynalink IS64PH (OEM version of ASUSCOM NETWORK INC. ISDNLink 128K adapter)
49 PCBIT-DP (OEM version of ASUSCOM NETWORK INC. ISDNLink)
50 HFC-2BS0 based cards (TeleInt SA1)
51 Sedlbauer Speed Card (Speed Win, Teledat 100, PCI, Fax+)
52 Sedlbauer Speed Star/Speed Star2 (PCMCIA)
53 Sedlbauer ISDN-Controller PC/104
54 USR Sportster internal TA (compatible Stollmann tina-pp V3)
55 ith Kommunikationstechnik GmbH MIC 16 ISA card
56 Traverse Technologie NETjet PCI S0 card and NETspider U card
57 Ovislink ISDN sc100-p card (NETjet driver)
58 Dr. Neuhaus Niccy PnP/PCI
59 Siemens I-Surf 1.0
60 Siemens I-Surf 2.0 (with IPAC, try type 12 asuscom)
61 ACER P10
62 HST Saphir
63 Berkom Telekom A4T
64 Scitel Quadro
65 Gazel ISDN cards
66 HFC-PCI based cards
67 Winbond W6692 based cards
68 HFC-S+, HFC-SP/PCMCIA cards
69
70 Note: PCF, PCF-Pro: up to now, only the ISDN part is supported
71 PCC-8: not tested yet
72 Teles PCMCIA is EXPERIMENTAL
73 Teles 16.3c is EXPERIMENTAL
74 Teles PCI is EXPERIMENTAL
75 Teles S0Box is EXPERIMENTAL
76 Eicon.Diehl Diva U interface not tested
77 HFC-S+, HFC-SP/PCMCIA are experimental
78
79 If you know other passive cards with the Siemens chipset, please let me know.
80 To use the PNP cards you need the isapnptools.
81 You can combine any card, if there is no conflict between the resources
82 (io, mem, irq).
83
84
85 Configuring the driver
86 ----------------------
87
88 The HiSax driver can either be built directly into the kernel or as a module.
89 It can be configured using the command line feature while loading the kernel
90 with LILO or LOADLIN or, if built as a module, using insmod/modprobe with
91 parameters.
92 There is also some config needed before you compile the kernel and/or
93 modules. It is included in the normal "make [menu]config" target at the
94 kernel. Don't forget it, especially to select the right D-channel protocol.
95
96 Please note: All PnP cards need to be configured with isapnp and will work
97 only with the HiSax driver used as a module.
98
99 a) when built as a module
100 -------------------------
101
102 insmod/modprobe hisax.o \
103 io=iobase irq=IRQ mem=membase type=card_type \
104 protocol=D_channel_protocol id=idstring
105
106 or, if several cards are installed:
107
108 insmod/modprobe hisax.o \
109 io=iobase1,iobase2,... irq=IRQ1,IRQ2,... mem=membase1,membase2,... \
110 type=card_type1,card_type2,... \
111 protocol=D_channel_protocol1,D_channel_protocol2,... \
112 id=idstring1%idstring2 ...
113
114 where "iobaseN" represents the I/O base address of the Nth card, "membaseN"
115 the memory base address of the Nth card, etc.
116
117 The reason for the delimiter "%" being used in the idstrings is that ","
118 won't work with the current modules package.
119
120 The parameters may be specified in any order. For example, the "io"
121 parameter may precede the "irq" parameter, or vice versa. If several
122 cards are installed, the ordering within the comma separated parameter
123 lists must of course be consistent.
124
125 Only parameters applicable to the card type need to be specified. For
126 example, the Teles 16.3 card is not memory-mapped, so the "mem"
127 parameter may be omitted for this card. Sometimes it may be necessary
128 to specify a dummy parameter, however. This is the case when there is
129 a card of a different type later in the list that needs a parameter
130 which the preceding card does not. For instance, if a Teles 16.0 card
131 is listed after a Teles 16.3 card, a dummy memory base parameter of 0
132 must be specified for the 16.3. Instead of a dummy value, the parameter
133 can also be skipped by simply omitting the value. For example:
134 mem=,0xd0000. See example 6 below.
135
136 The parameter for the D-Channel protocol may be omitted if you selected the
137 correct one during kernel config. Valid values are "1" for German 1TR6,
138 "2" for EDSS1 (Euro ISDN), "3" for leased lines (no D-Channel) and "4"
139 for US NI1.
140 With US NI1 you have to include your SPID into the MSN setting in the form
141 <MSN>:<SPID> for example (your phonenumber is 1234 your SPID 5678):
142 AT&E1234:5678 on ttyI interfaces
143 isdnctrl eaz ippp0 1234:5678 on network devices
144
145 The Creatix/Teles PnP cards use io1= and io2= instead of io= for specifying
146 the I/O addresses of the ISAC and HSCX chips, respectively.
147
148 Card types:
149
150 Type Required parameters (in addition to type and protocol)
151
152 1 Teles 16.0 irq, mem, io
153 2 Teles 8.0 irq, mem
154 3 Teles 16.3 (non PnP) irq, io
155 4 Creatix/Teles PnP irq, io0 (ISAC), io1 (HSCX)
156 5 AVM A1 (Fritz) irq, io
157 6 ELSA PCC/PCF cards io or nothing for autodetect (the iobase is
158 required only if you have more than one ELSA
159 card in your PC)
160 7 ELSA Quickstep 1000 irq, io (from isapnp setup)
161 8 Teles 16.3 PCMCIA irq, io
162 9 ITK ix1-micro Rev.2 irq, io
163 10 ELSA PCMCIA irq, io (set with card manager)
164 11 Eicon.Diehl Diva ISA PnP irq, io
165 11 Eicon.Diehl Diva PCI no parameter
166 12 ASUS COM ISDNLink irq, io (from isapnp setup)
167 13 HFC-2BS0 based cards irq, io
168 14 Teles 16.3c PnP irq, io
169 15 Sedlbauer Speed Card irq, io
170 15 Sedlbauer PC/104 irq, io
171 15 Sedlbauer Speed PCI no parameter
172 16 USR Sportster internal irq, io
173 17 MIC card irq, io
174 18 ELSA Quickstep 1000PCI no parameter
175 19 Compaq ISDN S0 ISA card irq, io0, io1, io (from isapnp setup io=IO2)
176 20 NETjet PCI card no parameter
177 21 Teles PCI no parameter
178 22 Sedlbauer Speed Star (PCMCIA) irq, io (set with card manager)
179 24 Dr. Neuhaus Niccy PnP irq, io0, io1 (from isapnp setup)
180 24 Dr. Neuhaus Niccy PCI no parameter
181 25 Teles S0Box irq, io (of the used lpt port)
182 26 AVM A1 PCMCIA (Fritz!) irq, io (set with card manager)
183 27 AVM PnP (Fritz!PnP) irq, io (from isapnp setup)
184 27 AVM PCI (Fritz!PCI) no parameter
185 28 Sedlbauer Speed Fax+ irq, io (from isapnp setup)
186 29 Siemens I-Surf 1.0 irq, io, memory (from isapnp setup)
187 30 ACER P10 irq, io (from isapnp setup)
188 31 HST Saphir irq, io
189 32 Telekom A4T none
190 33 Scitel Quadro subcontroller (4*S0, subctrl 1...4)
191 34 Gazel ISDN cards (ISA) irq,io
192 34 Gazel ISDN cards (PCI) none
193 35 HFC 2BDS0 PCI none
194 36 W6692 based PCI cards none
195 37 HFC 2BDS0 S+, SP irq,io
196 38 NETspider U PCI card none
197 39 HFC 2BDS0 SP/PCMCIA irq,io (set with cardmgr)
198
199 At the moment IRQ sharing is only possible with PCI cards. Please make sure
200 that your IRQ is free and enabled for ISA use.
201
202
203 Examples for module loading
204
205 1. Teles 16.3, Euro ISDN, I/O base 280 hex, IRQ 10
206 modprobe hisax type=3 protocol=2 io=0x280 irq=10
207
208 2. Teles 16.0, 1TR6 ISDN, I/O base d80 hex, IRQ 5, Memory d0000 hex
209 modprobe hisax protocol=1 type=1 io=0xd80 mem=0xd0000 irq=5
210
211 3. Fritzcard, Euro ISDN, I/O base 340 hex, IRQ 10 and ELSA PCF, Euro ISDN
212 modprobe hisax type=5,6 protocol=2,2 io=0x340 irq=10 id=Fritz%Elsa
213
214 4. Any ELSA PCC/PCF card, Euro ISDN
215 modprobe hisax type=6 protocol=2
216
217 5. Teles 16.3 PnP, Euro ISDN, with isapnp configured
218 isapnp config: (INT 0 (IRQ 10 (MODE +E)))
219 (IO 0 (BASE 0x0580))
220 (IO 1 (BASE 0x0180))
221 modprobe hisax type=4 protocol=2 irq=10 io0=0x580 io1=0x180
222
223 6. Teles 16.3, Euro ISDN, I/O base 280 hex, IRQ 12 and
224 Teles 16.0, 1TR6, IRQ 5, Memory d0000 hex
225 modprobe hisax type=3,1 protocol=2,1 io=0x280 mem=0,0xd0000
226
227 Please note the dummy 0 memory address for the Teles 16.3, used as a
228 placeholder as described above, in the last example.
229
230 7. Teles PCMCIA, Euro ISDN, I/O base 180 hex, IRQ 15 (default values)
231 modprobe hisax type=8 protocol=2 io=0x180 irq=15
232
233
234 b) using LILO/LOADLIN, with the driver compiled directly into the kernel
235 ------------------------------------------------------------------------
236
237 hisax=typ1,dp1,pa_1,pb_1,pc_1[,typ2,dp2,pa_2 ... \
238 typn,dpn,pa_n,pb_n,pc_n][,idstring1[,idstring2,...,idstringn]]
239
240 where
241 typ1 = type of 1st card (default depends on kernel settings)
242 dp1 = D-Channel protocol of 1st card. 1=1TR6, 2=EDSS1, 3=leased
243 pa_1 = 1st parameter (depending on the type of the card)
244 pb_1 = 2nd parameter ( " " " " " " " )
245 pc_1 = 3rd parameter ( " " " " " " " )
246
247 typ2,dp2,pa_2,pb_2,pc_2 = Parameters of the second card (defaults: none)
248 typn,dpn,pa_n,pb_n,pc_n = Parameters of the n'th card (up to 16 cards are
249 supported)
250
251 idstring = Driver ID for accessing the particular card with utility
252 programs and for identification when using a line monitor
253 (default: "HiSax")
254
255 Note: the ID string must start with an alphabetical character!
256
257 Card types:
258
259 type
260 1 Teles 16.0 pa=irq pb=membase pc=iobase
261 2 Teles 8.0 pa=irq pb=membase
262 3 Teles 16.3 pa=irq pb=iobase
263 4 Creatix/Teles PNP ONLY WORKS AS A MODULE !
264 5 AVM A1 (Fritz) pa=irq pb=iobase
265 6 ELSA PCC/PCF cards pa=iobase or nothing for autodetect
266 7 ELSA Quickstep 1000 ONLY WORKS AS A MODULE !
267 8 Teles S0 PCMCIA pa=irq pb=iobase
268 9 ITK ix1-micro Rev.2 pa=irq pb=iobase
269 10 ELSA PCMCIA pa=irq, pb=io (set with card manager)
270 11 Eicon.Diehl Diva ISAPnP ONLY WORKS AS A MODULE !
271 11 Eicon.Diehl Diva PCI no parameter
272 12 ASUS COM ISDNLink ONLY WORKS AS A MODULE !
273 13 HFC-2BS0 based cards pa=irq pb=io
274 14 Teles 16.3c PnP ONLY WORKS AS A MODULE !
275 15 Sedlbauer Speed Card pa=irq pb=io (Speed Win only as module !)
276 15 Sedlbauer PC/104 pa=irq pb=io
277 15 Sedlbauer Speed PCI no parameter
278 16 USR Sportster internal pa=irq pb=io
279 17 MIC card pa=irq pb=io
280 18 ELSA Quickstep 1000PCI no parameter
281 19 Compaq ISDN S0 ISA card ONLY WORKS AS A MODULE !
282 20 NETjet PCI card no parameter
283 21 Teles PCI no parameter
284 22 Sedlbauer Speed Star (PCMCIA) pa=irq, pb=io (set with card manager)
285 24 Dr. Neuhaus Niccy PnP ONLY WORKS AS A MODULE !
286 24 Dr. Neuhaus Niccy PCI no parameter
287 25 Teles S0Box pa=irq, pb=io (of the used lpt port)
288 26 AVM A1 PCMCIA (Fritz!) pa=irq, pb=io (set with card manager)
289 27 AVM PnP (Fritz!PnP) ONLY WORKS AS A MODULE !
290 27 AVM PCI (Fritz!PCI) no parameter
291 28 Sedlbauer Speed Fax+ ONLY WORKS AS A MODULE !
292 29 Siemens I-Surf 1.0 ONLY WORKS AS A MODULE !
293 30 ACER P10 ONLY WORKS AS A MODULE !
294 31 HST Saphir pa=irq, pb=io
295 32 Telekom A4T no parameter
296 33 Scitel Quadro subcontroller (4*S0, subctrl 1...4)
297 34 Gazel ISDN cards (ISA) pa=irq, pb=io
298 34 Gazel ISDN cards (PCI) no parameter
299 35 HFC 2BDS0 PCI no parameter
300 36 W6692 based PCI cards none
301 37 HFC 2BDS0 S+,SP/PCMCIA ONLY WORKS AS A MODULE !
302 38 NETspider U PCI card none
303
304
305 Running the driver
306 ------------------
307
308 When you insmod isdn.o and hisax.o (or with the in-kernel version, during
309 boot time), a few lines should appear in your syslog. Look for something like:
310
311 Apr 13 21:01:59 kke01 kernel: HiSax: Driver for Siemens chip set ISDN cards
312 Apr 13 21:01:59 kke01 kernel: HiSax: Version 2.9
313 Apr 13 21:01:59 kke01 kernel: HiSax: Revisions 1.14/1.9/1.10/1.25/1.8
314 Apr 13 21:01:59 kke01 kernel: HiSax: Total 1 card defined
315 Apr 13 21:01:59 kke01 kernel: HiSax: Card 1 Protocol EDSS1 Id=HiSax1 (0)
316 Apr 13 21:01:59 kke01 kernel: HiSax: Elsa driver Rev. 1.13
317 ...
318 Apr 13 21:01:59 kke01 kernel: Elsa: PCF-Pro found at 0x360 Rev.:C IRQ 10
319 Apr 13 21:01:59 kke01 kernel: Elsa: timer OK; resetting card
320 Apr 13 21:01:59 kke01 kernel: Elsa: HSCX version A: V2.1 B: V2.1
321 Apr 13 21:01:59 kke01 kernel: Elsa: ISAC 2086/2186 V1.1
322 ...
323 Apr 13 21:01:59 kke01 kernel: HiSax: DSS1 Rev. 1.14
324 Apr 13 21:01:59 kke01 kernel: HiSax: 2 channels added
325
326 This means that the card is ready for use.
327 Cabling problems or line-downs are not detected, and only some ELSA cards can
328 detect the S0 power.
329
330 Remember that, according to the new strategy for accessing low-level drivers
331 from within isdn4linux, you should also define a driver ID while doing
332 insmod: Simply append hisax_id=<SomeString> to the insmod command line. This
333 string MUST NOT start with a digit or a small 'x'!
334
335 At this point you can run a 'cat /dev/isdnctrl0' and view debugging messages.
336
337 At the moment, debugging messages are enabled with the hisaxctrl tool:
338
339 hisaxctrl <DriverId> DebugCmd <debugging_flags>
340
341 <DriverId> default is HiSax, if you didn't specify one.
342
343 DebugCmd is 1 for generic debugging
344 11 for layer 1 development debugging
345 13 for layer 3 development debugging
346
347 where <debugging_flags> is the integer sum of the following debugging
348 options you wish enabled:
349
350 With DebugCmd set to 1:
351
352 0x0001 Link-level <--> hardware-level communication
353 0x0002 Top state machine
354 0x0004 D-Channel Frames for isdnlog
355 0x0008 D-Channel Q.921
356 0x0010 B-Channel X.75
357 0x0020 D-Channel l2
358 0x0040 B-Channel l2
359 0x0080 D-Channel link state debugging
360 0x0100 B-Channel link state debugging
361 0x0200 TEI debug
362 0x0400 LOCK debug in callc.c
363 0x0800 More paranoid debug in callc.c (not for normal use)
364 0x1000 D-Channel l1 state debugging
365 0x2000 B-Channel l1 state debugging
366
367 With DebugCmd set to 11:
368
369 0x0001 Warnings (default: on)
370 0x0002 IRQ status
371 0x0004 ISAC
372 0x0008 ISAC FIFO
373 0x0010 HSCX
374 0x0020 HSCX FIFO (attention: full B-Channel output!)
375 0x0040 D-Channel LAPD frame types
376 0x0080 IPAC debug
377 0x0100 HFC receive debug
378 0x0200 ISAC monitor debug
379 0x0400 D-Channel frames for isdnlog (set with 1 0x4 too)
380 0x0800 D-Channel message verbose
381
382 With DebugCmd set to 13:
383
384 1 Warnings (default: on)
385 2 l3 protocol descriptor errors
386 4 l3 state machine
387 8 charge info debugging (1TR6)
388
389 For example, 'hisaxctrl HiSax 1 0x3ff' enables full generic debugging.
390
391 Because of some obscure problems with some switch equipment, the delay
392 between the CONNECT message and sending the first data on the B-channel is now
393 configurable with
394
395 hisaxctrl <DriverId> 2 <delay>
396 <delay> in ms Value between 50 and 800 ms is recommended.
397
398 Downloading Firmware
399 --------------------
400 At the moment, the Sedlbauer speed fax+ is the only card, which
401 needs to download firmware.
402 The firmware is downloaded with the hisaxctrl tool:
403
404 hisaxctrl <DriverId> 9 <firmware_filename>
405
406 <DriverId> default is HiSax, if you didn't specify one,
407
408 where <firmware_filename> is the filename of the firmware file.
409
410 For example, 'hisaxctrl HiSax 9 ISAR.BIN' downloads the firmware for
411 ISAR based cards (like the Sedlbauer speed fax+).
412
413 Warning
414 -------
415 HiSax is a work in progress and may crash your machine.
416 For certification look at HiSax.cert file.
417
418 Limitations
419 -----------
420 At this time, HiSax only works on Euro ISDN lines and German 1TR6 lines.
421 For leased lines see appendix.
422
423 Bugs
424 ----
425 If you find any, please let me know.
426
427
428 Thanks
429 ------
430 Special thanks to:
431
432 Emil Stephan for the name HiSax which is a mix of HSCX and ISAC.
433
434 Fritz Elfert, Jan den Ouden, Michael Hipp, Michael Wein,
435 Andreas Kool, Pekka Sarnila, Sim Yskes, Johan Myrre'en,
436 Klaus-Peter Nischke (ITK AG), Christof Petig, Werner Fehn (ELSA GmbH),
437 Volker Schmidt
438 Edgar Toernig and Marcus Niemann for the Sedlbauer driver
439 Stephan von Krawczynski
440 Juergen Quade for the Leased Line part
441 Klaus Lichtenwalder (Klaus.Lichtenwalder@WebForum.DE), for ELSA PCMCIA support
442 Enrik Berkhan (enrik@starfleet.inka.de) for S0BOX specific stuff
443 Ton van Rosmalen for Teles PCI
444 Petr Novak <petr.novak@i.cz> for Winbond W6692 support
445 and more people who are hunting bugs. (If I forgot somebody, please
446 send me a mail).
447
448 Firma ELSA GmbH
449 Firma Eicon.Diehl GmbH
450 Firma Dynalink NL
451 Firma ASUSCOM NETWORK INC. Taiwan
452 Firma S.u.S.E
453 Firma ith Kommunikationstechnik GmbH
454 Firma Traverse Technologie Australia
455 Firma Medusa GmbH (www.medusa.de).
456 Firma Quant-X Austria for sponsoring a DEC Alpha board+CPU
457 Firma Cologne Chip Designs GmbH
458
459 My girl friend and partner in life Ute for her patience with me.
460
461
462 Enjoy,
463
464 Karsten Keil
465 keil@isdn4linux.de
466
467
468 Appendix: Teles PCMCIA driver
469 -----------------------------
470
471 See
472 http://www.stud.uni-wuppertal.de/~ea0141/pcmcia.html
473 for instructions.
474
475 Appendix: Linux and ISDN-leased lines
476 -------------------------------------
477
478 Original from Juergen Quade, new version KKe.
479
480 Attention NEW VERSION, the old leased line syntax won't work !!!
481
482 You can use HiSax to connect your Linux-Box via an ISDN leased line
483 to e.g. the Internet:
484
485 1. Build a kernel which includes the HiSax driver either as a module
486 or as part of the kernel.
487 cd /usr/src/linux
488 make menuconfig
489 <ISDN subsystem - ISDN support -- HiSax>
490 make clean; make dep; make zImage; make modules; make modules_install
491 2. Install the new kernel
492 cp /usr/src/linux/arch/i386/boot/zImage /etc/kernel/linux.isdn
493 vi /etc/lilo.conf
494 <add new kernel in the bootable image section>
495 lilo
496 3. in case the hisax driver is a "fixed" part of the kernel, configure
497 the driver with lilo:
498 vi /etc/lilo.conf
499 <add HiSax driver parameter in the global section (see below)>
500 lilo
501 Your lilo.conf _might_ look like the following:
502
503 # LILO configuration-file
504 # global section
505 # teles 16.0 on IRQ=5, MEM=0xd8000, PORT=0xd80
506 append="hisax=1,3,5,0xd8000,0xd80,HiSax"
507 # teles 16.3 (non pnp) on IRQ=15, PORT=0xd80
508 # append="hisax=3,3,5,0xd8000,0xd80,HiSax"
509 boot=/dev/sda
510 compact # faster, but won't work on all systems.
511 linear
512 read-only
513 prompt
514 timeout=100
515 vga = normal # force sane state
516 # Linux bootable partition config begins
517 image = /etc/kernel/linux.isdn
518 root = /dev/sda1
519 label = linux.isdn
520 #
521 image = /etc/kernel/linux-2.0.30
522 root = /dev/sda1
523 label = linux.secure
524
525 In the line starting with "append" you have to adapt the parameters
526 according to your card (see above in this file)
527
528 3. boot the new linux.isdn kernel
529 4. start the ISDN subsystem:
530 a) load - if necessary - the modules (depends, whether you compiled
531 the ISDN driver as module or not)
532 According to the type of card you have to specify the necessary
533 driver parameter (irq, io, mem, type, protocol).
534 For the leased line the protocol is "3". See the table above for
535 the parameters, which you have to specify depending on your card.
536 b) configure i4l
537 /sbin/isdnctrl addif isdn0
538 # EAZ 1 -- B1 channel 2 --B2 channel
539 /sbin/isdnctrl eaz isdn0 1
540 /sbin/isdnctrl secure isdn0 on
541 /sbin/isdnctrl huptimeout isdn0 0
542 /sbin/isdnctrl l2_prot isdn0 hdlc
543 # Attention you must not set an outgoing number !!! This won't work !!!
544 # The incoming number is LEASED0 for the first card, LEASED1 for the
545 # second and so on.
546 /sbin/isdnctrl addphone isdn0 in LEASED0
547 # Here is no need to bind the channel.
548 c) in case the remote partner is a CISCO:
549 /sbin/isdnctrl encap isdn0 cisco-h
550 d) configure the interface
551 /sbin/ifconfig isdn0 ${LOCAL_IP} pointopoint ${REMOTE_IP}
552 e) set the routes
553 /sbin/route add -host ${REMOTE_IP} isdn0
554 /sbin/route add default gw ${REMOTE_IP}
555 f) switch the card into leased mode for each used B-channel
556 /sbin/hisaxctrl HiSax 5 1
557
558 Remarks:
559 a) Use state of the art isdn4k-utils
560
561 Here an example script:
562 #!/bin/sh
563 # Start/Stop ISDN leased line connection
564
565 I4L_AS_MODULE=yes
566 I4L_REMOTE_IS_CISCO=no
567 I4L_MODULE_PARAMS="type=16 io=0x268 irq=7 "
568 I4L_DEBUG=no
569 I4L_LEASED_128K=yes
570 LOCAL_IP=192.168.1.1
571 REMOTE_IP=192.168.2.1
572
573 case "$1" in
574 start)
575 echo "Starting ISDN ..."
576 if [ ${I4L_AS_MODULE} = "yes" ]; then
577 echo "loading modules..."
578 /sbin/modprobe hisax ${I4L_MODULE_PARAMS}
579 fi
580 # configure interface
581 /sbin/isdnctrl addif isdn0
582 /sbin/isdnctrl secure isdn0 on
583 if [ ${I4L_DEBUG} = "yes" ]; then
584 /sbin/isdnctrl verbose 7
585 /sbin/hisaxctrl HiSax 1 0xffff
586 /sbin/hisaxctrl HiSax 11 0xff
587 cat /dev/isdnctrl >/tmp/lea.log &
588 fi
589 if [ ${I4L_REMOTE_IS_CISCO} = "yes" ]; then
590 /sbin/isdnctrl encap isdn0 cisco-h
591 fi
592 /sbin/isdnctrl huptimeout isdn0 0
593 # B-CHANNEL 1
594 /sbin/isdnctrl eaz isdn0 1
595 /sbin/isdnctrl l2_prot isdn0 hdlc
596 # 1. card
597 /sbin/isdnctrl addphone isdn0 in LEASED0
598 if [ ${I4L_LEASED_128K} = "yes" ]; then
599 /sbin/isdnctrl addslave isdn0 isdn0s
600 /sbin/isdnctrl secure isdn0s on
601 /sbin/isdnctrl huptimeout isdn0s 0
602 # B-CHANNEL 2
603 /sbin/isdnctrl eaz isdn0s 2
604 /sbin/isdnctrl l2_prot isdn0s hdlc
605 # 1. card
606 /sbin/isdnctrl addphone isdn0s in LEASED0
607 if [ ${I4L_REMOTE_IS_CISCO} = "yes" ]; then
608 /sbin/isdnctrl encap isdn0s cisco-h
609 fi
610 fi
611 /sbin/isdnctrl dialmode isdn0 manual
612 # configure tcp/ip
613 /sbin/ifconfig isdn0 ${LOCAL_IP} pointopoint ${REMOTE_IP}
614 /sbin/route add -host ${REMOTE_IP} isdn0
615 /sbin/route add default gw ${REMOTE_IP}
616 # switch to leased mode
617 # B-CHANNEL 1
618 /sbin/hisaxctrl HiSax 5 1
619 if [ ${I4L_LEASED_128K} = "yes" ]; then
620 # B-CHANNEL 2
621 sleep 10; /* Wait for master */
622 /sbin/hisaxctrl HiSax 5 2
623 fi
624 ;;
625 stop)
626 /sbin/ifconfig isdn0 down
627 /sbin/isdnctrl delif isdn0
628 if [ ${I4L_DEBUG} = "yes" ]; then
629 killall cat
630 fi
631 if [ ${I4L_AS_MODULE} = "yes" ]; then
632 /sbin/rmmod hisax
633 /sbin/rmmod isdn
634 /sbin/rmmod ppp
635 /sbin/rmmod slhc
636 fi
637 ;;
638 *)
639 echo "Usage: $0 {start|stop}"
640 exit 1
641 esac
642 exit 0
This page was automatically generated by the
LXR engine.
Visit the LXR main site for more
information.