Piaf 1.6 and Dahdi

TomS

Guru
Joined
Oct 18, 2007
Messages
240
Reaction score
6
I have installed PiaF 1.6 on a Dell server.
I could not clear an IRQ conflict that was crashing the system with the Digium AEX800 card.

I removed the AEX800 card and the system stays up.
I installed two (2) Sangoma U100 USBfxo devices and with Sangoma's assistance the connections are working just fine.

Here is the problem:
The 2.2.1 dahdi driver does not recognize the line is available until you call into each line from the outside.
Then the lines work both ways just fine.
The U100 devices seem to be a great replacement for an fxo connection. I have 2 working together as 4 trunks.

Sangoma has a fix for the problem but I have to re-compile the dahdi driver.

I know that the dahdi driver is compiled when you load the Piaf1.6 CD.
I cannot find where to do the make, make clean, make install, etc. to recompile the existing driver(s) on PiaF 1.6.

Any assistance is gladly appreciated!

Thanks
TomS
 
Hi

I would expect to find the source files in /usr/src

Joe
 
What happens if you "amportal stop" then "service dahdi restart" and "amportal start" after PiaF boots up?
 
Solution to Dahdi U100 USBfxo driver fix

DAHDI/Asterisk Problem:
After rebooting the server, all of the outbound trunks are not available for outbound calls.
You can call into the system and the line will answer. If you do, the OnHook/OffHook status is recognized and you can then begin to make outbound calls on the trunks.
The trick is that you must call in on each Analog trunk first.
This is a problem in the Dahdi driver.

Solution:
Sangoma has a fix for the problem that is applied to the DAHDI code.
PER Sangoma:
· We have resolved the issue, it is a Digium/Dahdi-Linux bug. You just need to edit the file below and add "//" in front of the line so it is commented out.
· Then recompile Dahdi to resolve the issue.
File name: drivers/dahdi/dahdi-base.c

// chans[ch.chan]->rxhooksig = DAHDI_RXSIG_INITIAL;

You can check if Asterisk sees the USB devices and channels also:
    • asterisk –rx “dahdi show channel 1” | grep –i hook
    • Output should show either Onhook or Offhook as the state
    • Try the command above for each channel 1-4 (in my case)
SOURCE INSTALLATIONhttp://wiki.sangoma.com/trixbox-install#source-install
In order to apply the above patch/fix, you must download and re-compile the Dahdi driver. To install the driver from source, follow the instructions below:

Find the Dahdi Version:
First find the version of Dahdi by running the command:
#> dahdi_cfg -vvv
DAHDI Tools Version - 2.2.1
DAHDI Version: 2.2.1
Echo Canceller(s):
Configuration
======================

You will notice there are two version statements, insure you note the “Dahdi Version:not the “Dahdi-Tools Version”.
Go to http://downloads.asterisk.org/pub/telephony/dahdi-linux/releases/
Search for your version of dahdi (see RED above).
The file name should be in the format "dahdi-linux-<version>.tar.gz"
Once you find the version then run the command
#> cd /usr/src/
#> "wget <<URL of Dahdi-linux>>"
So for this version it would be the following command:
#> wget http://downloads.asterisk.org/pub/telephony/dahdi-linux/releases/dahdi-linux-2.2.1.tar.gz

You would need to compile the dahdi source in order to install the wanpipe driver:

1. Extract the dahdi-linux-<version>.tar.gz file, by running the command:
#> tar xfz dahdi-linux-2.2.1.tar.gz
2. Commands:
#> cd dahdi-linux-2.2.1
#> vi drivers/dahdi/dahdi-base.c
Edit the like above and save the file
#> make clean; make; make install
#> asterisk –rx “core stop now”
#> wanrouter stop all
#> /etc/init.d/dahdi stop
#> wanrouter start
#> asterisk
3. The compiling is done, contact [email protected]
4. To correct the FOP using the Dahdi information, you edit the file /var/www/html/panel/op_buttons_additional.cfg replacing the
zaptel items with the following dahdi items:

There are 2 Sangoma U100 USBfxo cards with 2 FXO ports per device.

; Trunk buttons
[DAHDI/1]
Position=55
Label="DAHDI 1"
Extension=-1
Icon=3

[DAHDI/2]
Position=56
Label="DAHDI 2"
Extension=-1
Icon=3

[DAHDI/3]
Position=57
Label="DAHDI 3"
Extension=-1
Icon=3

[DAHDI/4]
Position=58
Label="DAHDI 4"
Extension=-1
Icon=3

Make sure the Position= statements do not conflict with others in the same file.
You can place the telephone line number in the label instead of 1,2,3,4.

To restart the FOP 0.30 enter: amportal restart


TomS
 
DAHDI U100 USBfxo Setup

I had to break this into 2 entries - over the max characters.
See entry before this one for Compile/Installation of DAHDI 2.2.1 drivers for use with USBfxo U100 Sangoma cards.
My system is Asterisk 1.6 with 2-U100 USBfxo Sangoma devices installed on a Dell 1850 server with dual dual-core CPUs. The Flash Operator Panel (FOP) setup is also discussed in the previous message in this thread.

Installation of the Sangoma U100 devices:
  • Insert the Sangoma U100 USBfxo card(s)
  • Power up the PiaF 1.6 server
  • Check that your server can see the hardware:
    • wanrouter hwprobe
      • If command is not there, you have not run the installation script from the Sangoma wiki
    • dahdi_cfg –vv
  • If the above commands are not available, you need to run the installation script.
    • You will need the libtool package installed:
    • Commands/Responses:
      • cd /usr/src
      • wget the file wanpipe-3.5.14.tgz
      • tar xvfz wanpipe-3.5.14.tgz
      • cd wanpipe-3.5.14
      • ./Setup install (or ./Setup install –64bit_4GB)
      • TO CONFIGURE THE DEVICE(s): wancfg_zaptel
        • Select “Y”
        • Compilation mode: “TDM Only drivers” (Option #2)
        • 1:/usr/src/dahdi
        • Answer to match your requirements
        • Install the startup scripts
        • Compile/Install the tools
        • Some answers:
          • Generate /etc/asterisk/chan_dahdi.conf YES
          • Configure USB U100 on bus: <one for each device> YES
          • Which codec will be used? 1.MULAW – North America
          • Which Operation Mode will be used? 1.FCC
          • Continue YES
          • The “stop now” will not work so use the option 5 to do it manually:
#> asterisk –rx “core stop now”
#> wanrouter stop all
#> /etc/init.d/dahdi stop
#> wanrouter start
#> asterisk

Don’t forget FOP: amportal restart




TomS
 

Members online

Forum statistics

Threads
26,688
Messages
174,412
Members
20,258
Latest member
RandomPerson
Get 3CX - Absolutely Free!

Link up your team and customers Phone System Live Chat Video Conferencing

Hosted or Self-managed. Up to 10 users free forever. No credit card. Try risk free.

3CX
A 3CX Account with that email already exists. You will be redirected to the Customer Portal to sign in or reset your password if you've forgotten it.
Back
Top