Diva Server 4BRI-8M 2.0 PCI

Compile Driver for Debian / Ubuntu
apt-get install -y linux-headers-$(uname -r)
apt-get install -y wget build-essential libncurses5-dev

# apt-get install -y linux-ubuntu-modules-$(uname -r)
# apt-get install -y linux-restricted-modules
# apt-get install -y apt-get install isdnactivecards

apt-get install -y capiutils
apt-get install -y asterisk
apt-get install -y asterisk-chan-capi

# fix /bin/sh on ubuntu
# ln -sf /bin/bash /bin/sh

# check for new downloads
ftp://ftp.melware.net/divas/v3/
# URL=ftp://ftp.melware.net/divas/v3/divas4linux-melware-3.1.0-109.42-1.tar.bz2 # Ubuntu intrepid / Debian lenny
# URL=ftp://ftp.melware.net/divas/v3/divas4linux-melware-3.1.5-109.75-1.tar.bz2 # Debian squeeze
URL=ftp://ftp.melware.net/divas/v3/divas4linux-melware-3.1.6-109.75-1.tar.bz2 # Debian wheezy

# download
wget --no-passive ${URL} -P /root
tar xjf /root/divas4linux-melware-*.tar.bz2 -C /root/
cd /root/divas4linux-melware-*/
make

# Do you want to use the Diva optimized CAPI interface?
# Note: if you say 'y' here, the common kernelcapi is not used
# and therefore other CAPI cards than Diva are not usable.
# If you use Diva cards only, you can say 'y'.
# Your selection (y/n)[y]:
# select y

make install

# prepare archive vor external installation
# make DESTDIR=/tmp install
# tar cjf divas.3.1.5-109.75-1.tar.bz2 /tmp/usr/lib/divas/

rm /lib/modules/$(uname -r)/kernel/drivers/isdn/hardware/eicon/*.ko
cp /usr/lib/divas/*.ko /lib/modules/$(uname -r)/kernel/drivers/isdn/hardware/eicon/
depmod -a
# update-initramfs -u -k all

reboot

# get capiinfo
capiinfo

# enable capi in asterisk
sed -i 's|noload => chan_capi.so|load => chan_capi.so|g' /etc/asterisk/modules.conf
/etc/init.d/asterisk restart
cat /var/log/asterisk/messages | grep capi

apt-get install -y pciutils
ln -sf /bin/bash /bin/sh

/usr/lib/divas/Config
apt-get install -y capiutils

cat < /etc/init.d/divas
#!/bin/sh
/usr/lib/divas/divas_cfg.rc
exit 0
EOF

chmod +x /etc/init.d/divas

update-rc.d divas defaults 12

### old

cd /usr/src/
apt-get source linux-image-$(uname -r)
ln -s /usr/src/linux-2.6.24/ /usr/src/linux
cp /usr/src/linux-headers-2.6.24-23-xen/.config /usr/src/linux/

wget ftp://ftp.melware.net/divas/v3/divas4linux-melware-3.1.0-109.42-1.tar.bz2
tar xjf divas4linux-melware-3.1.0-109.42-1.tar.bz2
cd divas4linux-melware-3.1.0-109.42-1
make
make install
ln -sf /bin/bash /bin/sh
rm /lib/modules/2.6.24-23-xen/kernel/drivers/isdn/hardware/eicon/*.ko
cp /usr/lib/divas/*.ko /lib/modules/2.6.24-23-xen/kernel/drivers/isdn/hardware/eicon/
depmod -a
/usr/lib/opendiva/divas/Config
ln -sf /bin/dash /bin/sh

# test
capifax -v YOUR_PHONE /etc/isdn/capi.conf

Configure for Point to Point (Anlagenanschluss)
/usr/lib/divas/Config
"Please configure trunk operation mode"
"(X) 1 - Point to Point (fixed TEI)"

Info
/proc/net/eicon/adapter1/info

Webinterface
Port: 10005
Set password: /usr/lib/opendiva/divas/httpd/login/login

Links
http://www.melware.org/MelwareWiki
http://www.aussievoip.com/wiki/index.php?page=freePBX-EiconDiva
http://www.dialogic.com/products/tdm_boards/system_release_software/Diva_for_Linux.htm?dl=1&regID=26907

Compile TEST (v2)
wget http://www.dialogic.com/download/p/linux/source.9.0/109-62/Diva4Linux_installer_9.0-109-62.bin -P /tmp/
chmod +x /tmp/Diva4Linux_installer_9.0-109-62.bin
bash /tmp/Diva4Linux_installer_9.0-109-62.bin

/usr/lib/opendiva/divas/src/Build
/usr/lib/opendiva/divas/Config

/usr/lib/eicon/divas/src/Build
/usr/lib/eicon/divas/Config

cat < /etc/apt/sources.list.d/hardy-updates.list
deb http://archive.ubuntu.com/ubuntu/ hardy-updates main universe multiverse restricted
deb-src http://archive.ubuntu.com/ubuntu/ hardy-updates main universe multiverse restricted
EOF
apt-get update