Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Asterisk + BRI
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
hlx2june
n00b
n00b


Joined: 03 Jan 2007
Posts: 11
Location: 52°31'N/13°20'E

PostPosted: Sat Oct 03, 2009 2:09 pm    Post subject: Asterisk + BRI Reply with quote

Hi,

could it be possible, that there is actually no way to get asterisk running with BRI Cards like Digium's B410PF or other hfc(multi) based chipsets in general and the Beronet's BNXS0 in special? The last one is very popular in the center of Old Europe. Without leaving the official portage tree I run into several traps.

According to Bug 265581 it's impossible to compile misdn with a recent kernel >=2.6.27. :roll: But net-misc/asterisk-chan_misdn depends on net-dialup/misdn-1*, so there ist no chan_misdn way without compiling sys-kernel/gentoo-sources-2.6.26-r4.

The alternative net-misc/zaptel may work fine with any Digium or junghanns.net BRI card, but not with a Beronet BN4S0. The card only differs by device ID.
Code:
lspci -vnnd 1397:*

Quote:
01:00.0 ISDN controller [0204]: Cologne Chip Designs GmbH ISDN network Controller [HFC-4S] [1397:08b4] (rev 01)
Subsystem: Cologne Chip Designs GmbH Device [1397:b560]
Flags: medium devsel, IRQ 21
I/O ports at 9480 [size=8]
Memory at fb9bb000 (32-bit, non-prefetchable) [size=4K]
Capabilities: [40] Power Management version 2
Kernel modules: hfcmulti


Without patching net-misc/zaptel I got:
Quote:
Oct 2 21:17:52 bishop Zapata Telephony Interface Registered on major 196
Oct 2 21:17:52 bishop Zaptel Version: 1.2.27
Oct 2 21:17:52 bishop Zaptel Echo Canceller: MG2
Oct 2 21:17:52 bishop pci 0000:01:00.0: PCI INT A -> GSI 21 (level, low) -> IRQ 21
Oct 2 21:17:52 bishop qozap: S/T ports: 4 [ TE TE TE TE ]
Oct 2 21:17:52 bishop qozap: 1 multiBRI card(s) in this box, 0 BRI ports total, bloop 0, pcmslave 0, dacs 1.

Applying this patch from http://blog.eth0.cc/zaptel-patchwork/ I got:
Quote:
Oct 3 03:55:22 bishop Zapata Telephony Interface Registered on major 196
Oct 3 03:55:22 bishop Zaptel Version: 1.2.27
Oct 3 03:55:22 bishop Zaptel Echo Canceller: MG2
Oct 3 03:55:22 bishop pci 0000:01:00.0: enabling device (0000 -> 0003)
Oct 3 03:55:22 bishop pci 0000:01:00.0: PCI INT A -> GSI 21 (level, low) -> IRQ 21
Oct 3 03:55:22 bishop qozap: BeroNet BN4S0 card configured at io port 0x9480 IRQ 21 HZ 250 CardID 0
Oct 3 03:55:22 bishop qozap: S/T ports: 4 [ TE TE NT NT ]
Oct 3 03:55:22 bishop qozap: 1 multiBRI card(s) in this box, 4 BRI ports total, bloop 0, pcmslave 0, dacs 1.

A brave piece of code. The card is detected as well as the position of the TE/NT DIP switches and the backside LEDs are flashing as expected. And thanks to asterisk for flexibility.

Now to the asterisk part. Euphoric about my success I run
Code:
asterisk -vvvc

and got
Quote:
== Parsing '/etc/asterisk/zapata.conf': Found
Oct 3 15:41:26 ERROR[28114]: chan_zap.c:10798 setup_zap: Unknown signalling method 'bri_cpe_ptmp'
Oct 3 15:41:26 ERROR[28114]: chan_zap.c:10415 setup_zap: Signalling must be specified before any channels are.
Oct 3 15:41:26 WARNING[28114]: loader.c:415 __load_resource: chan_zap.so: load_module failed, returning -1
Oct 3 15:41:26 WARNING[28114]: loader.c:555 load_modules: Loading module chan_zap.so failed!


I was not able to investigate if this bug is related to gentoo or asterisk. The USE flags for the installed packages are:
Code:
net-misc/asterisk-1.2.35  USE="alsa curl speex sqlite ssl zaptel -debug -doc -gtk -h323 -hardened -lowmem (-mmx) -nosamples -odbc (-osp) -postgres -pri"
net-misc/zaptel-1.2.27-r1  USE="bri florz -astribank -ecaggressive -eckb1 -ecmark -ecmark2 -ecmark3 -ecmg2 -ecsteve -ecsteve2 -rtc -watchdog -zapnet -zapras"

In opposite the 'pri_*' signalling methods work well if net-libs/libpri (without BRI support) is installed.

All the other hardmasked net-misc/dahdi-2.x and net-misc/asterisk-1.6.x stuff is too hot for me. Please tell me that I made a mistake. Otherwise I'm in dead end, isn't it?
Back to top
View user's profile Send private message
hlx2june
n00b
n00b


Joined: 03 Jan 2007
Posts: 11
Location: 52°31'N/13°20'E

PostPosted: Sun Oct 04, 2009 11:58 am    Post subject: Reply with quote

Nobody who needs to use that environment?! BRI is for Basic Rate Interface, the small sister of PRI. Nobody who's running:

I can't believe it!
Back to top
View user's profile Send private message
mnagl
n00b
n00b


Joined: 05 Jul 2003
Posts: 25

PostPosted: Sun Oct 04, 2009 6:09 pm    Post subject: Reply with quote

Actually there is a well working method as you can also read in my reply to bug 265581!
However you have to compile two packages on your own, namly mISDNuser v2 (http://misdn.org/index.php/MISDN_v2_Download) and LCR/chan_lcr (http://www.linux-call-router.de/). After that you can use the new mISDN drivers contained in the standard kernel :)
Back to top
View user's profile Send private message
hlx2june
n00b
n00b


Joined: 03 Jan 2007
Posts: 11
Location: 52°31'N/13°20'E

PostPosted: Mon Oct 05, 2009 1:07 pm    Post subject: Reply with quote

mnagl wrote:
However you have to compile two packages on your own, namly mISDNuser v2 (http://misdn.org/index.php/MISDN_v2_Download) and LCR/chan_lcr (http://www.linux-call-router.de/). After that you can use the new mISDN drivers contained in the standard kernel :)


Thanks deeply for your response!

I got lcr running. But only standalone. I figured out, that asterisk has to be installed first. I took an actual source asterisk package of the 1.6 branch and afterwards I was able to compile lcr and the chan_lcr module. Then I remerged asterisk from the stable branch of gentoo (1.2*) and want to start asterisk, but with no success:
Quote:
Oct 5 14:46:08 VERBOSE[28699] logger.c: [chan_lcr.so]Oct 5 14:46:08 WARNING[28699] loader.c: /usr/lib/asterisk/modules/chan_lcr.so: undefined symbol: ast_null_frame
Oct 5 14:46:08 WARNING[28699] loader.c: Loading module chan_lcr.so failed!


I think lcr needs to be compiled against the asterisk version I want to run. Is there any chance to get a lcr version that fits with asterisk 1.2?


Last edited by hlx2june on Tue Oct 06, 2009 11:37 pm; edited 1 time in total
Back to top
View user's profile Send private message
Imp.Avgvstvs
n00b
n00b


Joined: 18 Jan 2006
Posts: 20
Location: Turin, Italy

PostPosted: Tue Oct 06, 2009 4:31 pm    Post subject: Reply with quote

I'm in the same condition more or less, but with asterisk 1.6.1.6
I tryed to build by hand mISDN 1.2.0 with succes, basically i think it's only needed an ebuild for this version, older version does not compile with kernel 2.6.29 or later i guess.
Back to top
View user's profile Send private message
GD
Tux's lil' helper
Tux's lil' helper


Joined: 11 May 2005
Posts: 138
Location: Greece

PostPosted: Thu Jan 14, 2010 10:06 pm    Post subject: Reply with quote

Any news on this? This is what I've done but I can't get asterisk 1.6.2.0 to emerge with the misdn USE flag (or is this not needed when using lcr to interface with misdn2?)

Compiled hfcmulti as module when making gentoo-sources-2.6.32-r1
git cloned misdnuser from the git repository and did make && make install
downloaded and untarred lcr-1.6 and ran ./.configure && make && make install

I don't think I came across any errors so far

then I tried to emerge asterisk-1.6.2.0 from portage but I get errors during configure:

Code:
checking for mandatory modules:  ALSA CAP DAHDI GSM ICONV IKSEMEL ISDNNET MISDN NETSNMP OGG POPT PRI PRI_INBANDDISCONNECT SPANDSP SPEEX SPEEX_PREPROCESS SPEEXDSP SQLITE3 SUPPSERV FREETDS TONEZONE VORBIS ZLIB... fail                     

configure: ***
configure: *** The ISDNNET installation appears to be missing or broken.
configure: *** Either correct the installation, or run configure       
configure: *** including --without-isdnnet.                             

configure: ***
configure: *** The MISDN installation appears to be missing or broken.
configure: *** Either correct the installation, or run configure     
configure: *** including --without-misdn.                             

configure: ***
configure: *** The SUPPSERV installation appears to be missing or broken.
configure: *** Either correct the installation, or run configure         
configure: *** including --without-suppserv.


Is this normal? Why isn't it able to locate misdn installation? Am I supposed to disable the mISDN use flag?
Back to top
View user's profile Send private message
GD
Tux's lil' helper
Tux's lil' helper


Joined: 11 May 2005
Posts: 138
Location: Greece

PostPosted: Fri Jan 15, 2010 3:10 pm    Post subject: Reply with quote

Yeap, it's confirmed... I should use lcr to interface with mISDN2 so the misdn use flag should be disabled for asterisk...

The only issue is LCR creates /var/tmp/LCR.socket as owned by root:root and I have to manually change it to asterisk:asterisk. Oh and there is no init script for LCR so I have to add it to local.start with the fork option...
Back to top
View user's profile Send private message
hazza
n00b
n00b


Joined: 30 Dec 2002
Posts: 68
Location: Burton on Trent

PostPosted: Mon Aug 23, 2010 7:45 pm    Post subject: Reply with quote

Not wanting to duplicate work (i.e. I'm being a bit lazy at the moment!) has anyone written a howto on this?

I've just run into exactly the problem described above, with the added twist I'm building stuff on an ARM box :-P I've got the kernel behaving as best as I can tell:
Code:
# uname -a
Linux armful 2.6.33-rc8-00099-g31a2de0-dirty #12 Mon Aug 23 20:15:36 BST 2010 armv5tel Feroceon 88FR131 rev 1 (v5l) Marvell OpenRD Ultimate Board GNU/Linux

Aug 23 20:31:50 armful kernel: usb 1-1.2: new full speed USB device using orion-ehci and address 6
Aug 23 20:31:51 armful kernel: Modular ISDN core version 1.1.21
Aug 23 20:31:51 armful kernel: NET: Registered protocol family 34
Aug 23 20:31:51 armful kernel: HFC-S_USB driver Rev. Revision: 0.3.3 (socket), 2008-11-05 debug(0x0) poll(128)
Aug 23 20:31:51 armful kernel: hfcsusb_probe: interface(0) actalt(0) minor(0) vend_idx(10)
Aug 23 20:31:51 armful kernel: HFC-S_USB: hfcsusb_probe: detected "Eicon DIVA USB 4.0" (4 Isochron IN + 3 Isochron OUT, if=0 alt=1)
Aug 23 20:31:51 armful kernel: HFC-S_USB: registered as 'HFC-S_USB.1'
Aug 23 20:31:51 armful kernel: usbcore: registered new interface driver HFC-S_USB
but getting misdn_user, asterisk, chan_lcr etc. to build could be entertaining... I've got "vanilla" asterisk running OK, but haven't looked at the ins and outs of building all of the required toys yet. Anyone have any recommendations?

Cheers,
Harry
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum