OpenVox A2410P Zaptel en

From Wiki

Jump to: navigation, search

Contents

1. HardwareSetting

To set the A2410P/AE2410P, user MUST go through these steps:
1) Check power supply: Board must be provided power, please plug the power supply cable into power supply connector.

2) Split the RJ45 to RJ11: By using a splitter to split RJ45 interface to four RJ11 normal telephone line. 
And please connect PSTN line with FXO port and telephone with FXS port.

2. Software Installation and Configuration

A2410P/AE2410P supports zaptel software device driver on Linux. To use A2410P/AE2410P, user must download, compile, 
install and configure zaptel and asterisk.

2.1 Download asterisk, zaptel, driver and firmware

1. Asterisk can be downloaded from:
   http://downloads.asterisk.org/pub/telephony/asterisk/releases/

2. Zaptel can be downloaded from:
   1)  http://downloads.openvox.cn/pub/drivers/zaptel/openvox_zaptel-1.4.12.1.tar.gz
     If you download zaptel from link 1, please skip to 2.3 directly.

   2) http://downloads.asterisk.org/pub/telephony/
     If you download zaptel from link 2, please follow steps below.

3. Download A2410P/AE2410P driver from:
   http://downloads.openvox.cn/pub/drivers/zaptel/patches/a2410p_ae2410p/opvxa24xx_zaptel.tar.gz

   copy the driver uncompress file to /zaptel-xx/kernel/

4. If the board is AE2410P, user should download firmware from:
   http://downloads.openvox.cn/pub/firmwares/opvx-zaptel-fw-oct6114-032-1.07.01.tar.gz
   then execute commands:
   tar –xzvf opvx-zaptel-fw-oct6114-032-1.07.01.tar.gz
   cp zaptel-fw-oct6114-032.bin /lib/firmware/
   mkdir /usr/lib/hotplug/firmware
   mv zaptel-fw-oct6114-032.bin /usr/lib/hotplug/firmware

2.2 Edit the configuration file

   To edit the configuration file, follow these steps please:

1. Add opvxa24xx in /usr/src/zaptel-xx/Makefile
---------------------------------------------------------------------------
TOPDIR_MODULES:=pciradiotor2 torisa wcfxo wct1xxp wctdm wcte11xp wcusb zaptel ztd-eth ztd-loc ztdummyztdynamic zttranscode
SUBDIR_MODULES:=wct4xxp wctc4xxp xpp wctdm24xxp wcte12xp opvxa24xx
---------------------------------------------------------------------------

2. Add opvxa24xx in /usr/src/zaptel-xx/zaptel.sysconfig
---------------------------------------------------------------------------
#MODULES="$MODULESztdummy"
# Zaptel Timing OnlyInterface

MODULES="$MODULESxpp_usb"
# Xorcom Astribank Device

MODULES="$MODULESopvxa24xx"    # OpenVox A2410P -Modular FXS/FXO interface (1-24 ports)
---------------------------------------------------------------------------

3. Add opvxa24xx in /usr/src/zaptel-xx/kernel/xpp/utils/genzaptel.conf
---------------------------------------------------------------------------
# The rest of thelines are per-channel lines
sed -e 1,2d$procfile | \
while read line
do 

# in case this is a real channel. 

chan_num=`echo $line |awk '{print $1}'`

case "$line" in

*WCTDM/* | *\ WRTDM/* | *OPVXA1200/* |*OPVXA24XX/*) 

# TDM400P/2400P and similar cards(Sangoma A200, OpenVox A1200)

# this can be either FXS or FXO
---------------------------------------------------------------------------

2.3 Installation

Note that if there is no kernel source in the system, you should install it by command "yum install kernel-devel".
Before installing zaptel and asterisk, please make sure that some supporting packages have been installed.It is 
time to check for the availability of some supporting packages:

rpm -q bison
rpm -q bison-devel
rpm -q ncurses
rpm -q ncurses-devel
rpm -q zlib
rpm -q zlib-devel
rpm -q openssl
rpm -q openssl-devel
rpm -q gnutls-devel
rpm -q gcc         // make sure GCC version is above 4.0
rpm -q gcc-c++

If any of those packages is not installed, please perform yum like this: 
yum install bison
yum install bison-devel
yum install ncurses
yum install ncurses-devel
yum install zlib
yum install zlib-devel
yum install openssl
yum install openssl-devel
yum install gnutls-devel
yum install gcc   // make sure GCC version is above 4.0
yum install gcc-c++

User can install the driver via the following steps (assuming user has the source code of zaptel device driver installed 
under the directory of /usr/src/zaptel-XX ):

1. Check the A2410P/AE2410P hardware by command: lspci –vvvvv
After that,user can see there is a device called communication controller interface be found. 
---------------------------------------------------------------------------
01:01.0Communication controller: Unknown device 1b74:2410 (rev 01)

Subsystem: Unknown device 1b74:0001

Control: I/O+ Mem+ BusMaster+SpecCycle- MemWINV+ VGASnoop- ParErr- Stepping- SERR- FastB2B-

Status: Cap- 66MHz- UDF- FastB2B-ParErr- DEVSEL=slow >TAbort- <TAbort- <MAbort- >SERR- <PERR-

Latency: 64, Cache Line Size: 16 bytes

Interrupt: pin A routed to IRQ 50

Region 0: Memory at dcd00000 (32-bit,non-prefetchable) [size=1M]
---------------------------------------------------------------------------

2. Compilation
1) Install zaptel via executing commands:
cd /usr/src/zaptel-XX
./configure
make
make install 
make config


2) Install asterisk
cd /usr/src/asterisk-XX
./configure
make
make install
make samples

2.4 Configuration

1. Load modules for opvxa24xx:
modprobe zaptel
modprobe opvxa24xx opermode=YOUR COUNTRY 
genzaptelconf –sdvM
ztcfg –vvvv
Then run command "dmesg" to check whether EC module has been detected. The outputs below means EC module has been found.
---------------------------------------------------------------------------
OpenVox A2410P version: 1.0
Module 0: Installed -- AUTO FXO (FCC mode)
Module 1: Installed -- AUTO FXO (FCC mode)
Module 2: Installed -- AUTO FXO (FCC mode)
Module 3: Installed -- AUTO FXO (FCC mode)
Module 4: Installed -- AUTO FXS/DPO
Module 5: Installed -- AUTO FXS/DPO
Module 6: Installed -- AUTO FXS/DPO
Module 7: Installed -- AUTO FXS/DPO
Module 8: Installed -- AUTO FXO (FCC mode)
Module 9: Installed -- AUTO FXO (FCC mode)
Module 10: Installed -- AUTO FXO (FCC mode)
Module 11: Installed -- AUTO FXO (FCC mode)
Module 12: Installed -- AUTO FXS/DPO
Module 13: Installed -- AUTO FXS/DPO
Module 14: Installed -- AUTO FXS/DPO
Module 15: Installed -- AUTO FXS/DPO
Module 16: Installed -- AUTO FXO (FCC mode)
Module 17: Installed -- AUTO FXO (FCC mode)
Module 18: Installed -- AUTO FXO (FCC mode)
Module 19: Installed -- AUTO FXO (FCC mode)
Module 20: Installed -- AUTO FXS/DPO
Module 21: Installed -- AUTO FXS/DPO
Module 22: Installed -- AUTO FXS/DPO
Module 23: Installed -- AUTO FXS/DPO
Openvox VPM: echo cancellation supports 32 channels
Openvox VPM: echo cancellation for 32 channels
Openvox VPM: hardware DTMF disabled.
Openvox VPM: Present and operational servicing 1 span(s)
---------------------------------------------------------------------------
           
2. Check and modify the configuration files
The command "genzaptelconf" will automatically generate the zaptel.conf under /etc and zapata-channels.conf 
under /etc/asterisk respestively. Please check the settings of zaptel.conf, it looks like the following:
---------------------------------------------------------------------------
# Autogenerated by /usr/sbin/genzaptelconf -- do not hand edit
# Zaptel Configuration File
#
# This file is parsed by the Zaptel Configurator, ztcfg
#

# It must be in the module loading order


# Span 1: ZTDUMMY/1 "ZTDUMMY/1 (source: RTC) 1" (MASTER)

# Span 2: OPVXA24XX/0 "OpenVox A2410 Board 1"
fxsks=1
fxsks=2
fxsks=3
fxsks=4
fxoks=5
fxoks=6
fxoks=7
fxoks=8
fxsks=9
fxsks=10
fxsks=11
fxsks=12
fxoks=13
fxoks=14
fxoks=15
fxoks=16
fxsks=17
fxsks=18
fxsks=19
fxsks=20
fxoks=21
fxoks=22
fxoks=23
fxoks=24

# Global data

loadzone        = us     ;Please change to your country
defaultzone     = us     ;Please change to your country
---------------------------------------------------------------------------

Edit /etc/asterisk/indications.conf
---------------------------------------------------------------------------
country = us     ;Please change to your country
---------------------------------------------------------------------------

    After loading zaptel and opvxa24xx driver, user should confirm the zapata.conf and zapata-channels.conf under /etc/asterisk. 
Please make sure  zapata-channels.conf is included in zapata.conf. If not, run command: 
echo "#include zapata-channels.conf" >> /etc/asterisk/zapata.conf
Make sure that the context in zapata-channels.conf exist in extensions.conf. File zapata-channels.conf should look like 
the following:
FXO ports use FXS signaling, the configuration file looks like this: 
---------------------------------------------------------------------------
; Autogenerated by /usr/sbin/genzaptelconf -- do not hand edit
; Zaptel Channels Configurations (zapata.conf)
;
; This is not intended to be a complete zapata.conf. Rather, it is intended
; to be #include-d by /etc/zapata.conf that will include the global settings
;

; Span 1: ZTDUMMY/1 "ZTDUMMY/1 (source: RTC) 1" (MASTER)

; Span 2: OPVXA24XX/0 "OpenVox A2410 Board 1"
;;; line="1 OPVXA24XX/0/0 RED"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-pstn
channel => 1
context=default

;;; line="2 OPVXA24XX/0/1 RED"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-pstn
channel => 2
context=default
---------------------------------------------------------------------------

FXS ports use FXO signalling, the configuration file looks like this:
---------------------------------------------------------------------------
;;; line="5 OPVXA24XX0/4"
signalling=fxo_ks
callerid="Channel 5" <6005>
mailbox=6005
group=5
context=from-internal
channel => 5
callerid=
mailbox=
group=
context=default

;;; line="6 OPVXA24XX/0/5"
signalling=fxo_ks
callerid="Channel 6" <6006>
mailbox=6006
group=5
context=from-internal
channel => 6
callerid=
mailbox=
group=
context=default
---------------------------------------------------------------------------

3. Start asterisk and test calls
Check the zaptel channels by loading asterisk console:
asterisk –vvvvvvvgc
After entering asterisk console, run command "zap show channels". If zaptel channels can be shown, it means the them have been 
loaded into asterisk. 
---------------------------------------------------------------------------
*CLI> zap show channels
  Chan Extension  Context    Language   MOH Interpret   
Pseudeo          default               default                 
        1          from-pstn             default                 
        2          from-pstn             default                 
        3          from-pstn             default                 
        4          from-pstn             default                 
        5          from-internal         default                 
        6          from-internal         default                 
        7          from-internal         default                 
        8          from-internal         default                 
        9          from-pstn             default                 
        10         from-pstn             default                 
        11         from-pstn             default                 
        12         from-pstn             default                 
        13         from-internal         default                 
        14         from-internal         default                 
        15         from-internal         default                 
        16         from-internal         default                 
        17         from-pstn             default                 
        18         from-pstn             default                 
        19         from-pstn             default                 
        20         from-pstn             default                 
        21         from-internal         default                 
        22         from-internal         default                 
        23         from-internal         default                 
        24         from-internal         default                 
---------------------------------------------------------------------------

When you make an inbound call, CLI will show as the following: 
---------------------------------------------------------------------------
-- Starting simple switch on 'Zap/4-1'
-- Executing [s@from-pstn:1] Answer("Zap/4-1", "") in new stack
    -- Executing [s@from-pstn:2] BackGround("Zap/4-1", "demo-congrats") in new stack
    --  Playing 'demo-congrats.gsm' (language 'en')
    -- Executing [s@from-pstn:3] Hangup("Zap/4-1", "") in new stack
  == Spawn extension (from-pstn, s, 3) exited non-zero on 'Zap/4-1'
Hungup 'Zap/4-1'
---------------------------------------------------------------------------

When you make an outbound call, CLI will show as the following: 
---------------------------------------------------------------------------
-- Starting simple switch on 'Zap/5-1'
    -- Executing [910000@from-internal:1] Dial("Zap/5-1", "zap/4/910000") in new stack
    -- Called 4/910000
    -- Zap/4-1 answered Zap/5-1
    -- Native bridging Zap/5-1 and Zap/4-1
    -- Hungup 'Zap/4-1'
  == Spawn extension (from-internal, 910000, 1) exited non-zero on 'Zap/5-1'
-- Hungup 'Zap/5-1'
---------------------------------------------------------------------------

The status of channel looks like the following. If the board is AE2410P, EC Status of active channel should be ON; 
otherwise it be OFF.
---------------------------------------------------------------------------
*CLI> zap show channel 4
Channel: 4
File Descriptor: 16
Span: 2
Extension:
Dialing: no
Context: from-pstn
Caller ID:
Calling TON: 0
Caller ID name:
Destroy: 0
InAlarm: 0
Signalling Type: FXS Kewlstart
Radio: 0
Owner: Zap/4-1
Real: Zap/4-1
Callwait: 
Threeway: 
Confno: -1
Propagated Conference: -1
Real in conference: 0
DSP: yes
Relax DTMF: no
Dialing/CallwaitCAS: 0/0
Default law: ulaw
Fax Handled: no
Pulse phone: no
Echo Cancellation: 128 taps, currently ON
Master Channel: 5
Actual Confinfo: Num/5, Mode/0x0009
Actual Confmute: No
Hookstate (FXS only): Offhook
---------------------------------------------------------------------------

Notes:

Test environments are:
CentOS-5.5
Kernel version: 2.6.18-194.el5 
Zaptel: zaptel-1.4.12
Asterisk: 1.4.20
Hardware: OpenVox A2410P/AE2410P
Personal tools