Difference between revisions of "Dahdi dummy"

From "PTTLink Wiki"
Jump to navigation Jump to search
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
 
[[Category:How to]]
 
[[Category:How to]]
 +
[[Category:Software]]
 
[[Category:Node Configuration]]
 
[[Category:Node Configuration]]
 
[[Category:Administration]]
 
[[Category:Administration]]
Line 24: Line 25:
 
  # echo -e "#needed for rpi timing \ndahdi_dummy" >>/etc/modules  # add it to modules.conf
 
  # echo -e "#needed for rpi timing \ndahdi_dummy" >>/etc/modules  # add it to modules.conf
 
  # modprobe dahdi_dummy
 
  # modprobe dahdi_dummy
  # service restart asterisk
+
  # service asterisk restart  
  
 
=== Others ===
 
=== Others ===

Latest revision as of 17:09, 5 February 2022

DAHDI Dummy

Or how to fix my PTTLink node from stuttering when I use it.

Credit: Information taken from W9CR's wiki [1]

Compiling

Raspberry PI PTTLink 1.01 systems

For PTTLink 1.01 systems PTTLink 1.01 system.

  1. ensure your system is up and going, with the kernel pinned per the readme
# apt-mark hold raspberrypi-kernel-headers raspberrypi-kernel

Now run the following commands:

# apt-get install gcc raspberrypi-kernel-headers make vim git  
# vim /usr/src/asl-dahdi-linux-2.11.1/linux/drivers/dahdi/Kbuild remove the # from the dummy file
# cd /usr/src/asl-dahdi-linux-2.11.1
# make 
# make install
# echo -e "#needed for rpi timing \ndahdi_dummy" >>/etc/modules  # add it to modules.conf
# modprobe dahdi_dummy
# service asterisk restart 

Others

To build as root:

# cd /usr/src/asl-dahdi-linux-2.11.1/linux
# export MODULES_EXTRA='dahdi_dummy'
# make

Loading module

Now you need to load the module into the Linux kernel for use.

# insmod /usr/src/asl-dahdi-linux-2.11.1/linux/drivers/dahdi/dahdi_dummy.ko

Verify the module is loaded along with other DAHDI dependencies

# lsmod |grep dahdi
dahdi_dummy             3432  0
dahdi                 229561  35 dahdi_dummy
crc_ccitt               1771  1 dahdi

Configuring DAHDI

You will need to do dahdi_genconf and then dahdi_cfg. PTTLink1.01 is missing this in the service script that starts asterisk. It needs to be added.

Restart asterisk

# service asterisk restart

Run dahdi_scan to view results:

# dahdi_scan
[1]
active=yes
alarms=UNCONFIGURED
description=DAHDI_DUMMY/1 (source: HRtimer) 1
name=DAHDI_DUMMY/1
manufacturer=
devicetype=DAHDI Dummy Timing
location=
basechan=1
totchans=0
irq=0

Verification

StPeteRpt*CLI> dahdi show status
Description                              Alarms     IRQ        bpviol     CRC4
DAHDI_DUMMY/1 (source: HRtimer) 1        UNCONFIGUR 0          0          0

Testing

  • Before DAHDI dummy module is installed
bryan@StPeteRpt:~ $ sudo dahdi_test
 [sudo] password for bryan:
 Opened pseudo dahdi interface, measuring accuracy...
 99.614% 99.594% 99.608% 99.608% 98.476% 99.638% 99.599% 99.601%
 99.600% 98.450% 99.602% 99.600% 99.601% 99.600% 98.445% 99.581%
 99.621% 99.605% 99.597% 98.478% 99.630% 99.579% 99.626% 99.601%
 98.478% 99.630% 99.602% 99.600% 99.601% 98.446% 99.601% 99.580% ^C
 --- Results after 32 passes ---
 Best: 99.638% -- Worst: 98.445% -- Average: 99.390271%
 Cumulative Accuracy (not per pass): 99.967
 
  • After insmod of DAHDI dummy module.
 bryan@StPeteRpt:~ $ sudo dahdi_test
 Opened pseudo dahdi interface, measuring accuracy...
 99.990% 99.967% 99.991% 99.992% 99.991% 99.992% 99.991% 99.991%
 99.991% 99.988% 99.992% 99.991% 99.991% 99.992% 99.991% 99.991%
 99.991% 99.990% 99.992% 99.991% 99.991% 99.991% 99.991% 99.991%
 99.992% 99.991% 99.991% 99.992% 99.991% 99.991% 99.991% 99.991%
 99.991% 99.990% 99.991% 99.992% 99.991% 99.991% 99.991% 99.991% ^C
 --- Results after 40 passes ---
 Best: 99.992% -- Worst: 99.967% -- Average: 99.990443%
 Cumulative Accuracy (not per pass): 99.990
  • Here it is on an intel server running a pci_radio card:
 root@Itchy:/home/bryan# dahdi_test
 Opened pseudo dahdi interface, measuring accuracy...
 99.993% 99.986% 99.995% 99.992% 99.984% 99.971% 99.993% 99.990%
 99.992% 99.992% 99.991% 99.990% 99.996% 99.990% 99.971% 99.954%
 99.994% 99.992% 99.991% 99.995% 99.983% 99.993% 99.992% 99.992%
 99.997% 99.990% 99.985% 99.995% 99.990% 99.996% 99.989% 99.993%
 99.993% 99.989% 99.997% 99.989% 99.994% 99.996% 99.988% 99.993% ^C
 --- Results after 40 passes ---
 Best: 99.997% -- Worst: 99.954% -- Average: 99.989596%
 Cummulative Accuracy (not per pass): 99.992
  • Results are identical.

External Links

  1. W9CR's Wiki - Dahdi dummy[1]