Question about the file /etc/asterisk/chan_dahdi.c

hi , i want to ask about the file
/etc/asterisk/chan_dahdi.conf

assume i have dahdi 1 and dhadhi 2

note that if i applied a config in the file /etc/asterisk/chan_dahdi.conf , these configs will be applied to both dahdi 1 & dahdi 2

assume i want to set to dahdi 1 busycount=10 and i want to put on dahdi 2 busycout = 5

how can i do that ??

i cant to it with the file /etc/asterisk/chan_dahdi.conf

is there individual file for each dahdi line ??

regards

You can only have one copy of the dahdi driver loaded. What do you really mean by dahdi 1 and dahdi 2?

busycount applies to the channels defined between setting it and setting a new value for it.

hi daved , thanks fro reply .

my problem is that by using busycount=4 in /etc/asterisk/chan_dahdi.conf , i have a problem of dropping calls when i dial out
if i put it greater than 4 , i will have a hangup problems

so , i thoguth in another solution
i said that i have dahdi 5 ,9 used for out calls and not for inboud calls , and i said i will put to them a busycount = 13 and the problem of dropped calls a is solved .
to achive that i modified the file /etc/asterisk/dahdi-channels.conf

also , in the other side , all the other dahdi should get the default value in the file
/etc/chan_dahdi.conf

but after all of that
i have a problem !!!
it seems that the configs applied on the file /etc/asterisk/dahdi-channels.conf was applied to
dahdi 6,7,8,9,10 !!!

i dont know why !!!
i just edited the dahdi 5 , 9 for vusycount=13 , but why the dahdi 6,7,8,10 was modifed else ??!!!

i dont know why that occured !!!
here is the config files :

===========================================================
[root@lscpbx ~]# cat /etc/asterisk/dahdi-channels.conf
; Autogenerated by /usr/sbin/dahdi_genconf on Thu Nov 29 08:15:23 2012
; If you edit this file and execute /usr/sbin/dahdi_genconf again,
; your manual changes will be LOST.
; Dahdi Channels Configurations (chan_dahdi.conf)
;
; This is not intended to be a complete chan_dahdi.conf. Rather, it is intended
; to be #include-d by /etc/chan_dahdi.conf that will include the global settings
;

; Span 1: ATCOM-1600P/16 “ATCOM AX1600P/800P Board 17” (MASTER)
;;; line="1 ATCOM-1600P/16/0 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 1
callerid=
group=
context=default

;;; line="2 ATCOM-1600P/16/1 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 2
callerid=
group=
context=default

;;; line="3 ATCOM-1600P/16/2 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 3
callerid=
group=
context=default

;;; line="4 ATCOM-1600P/16/3 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 4
callerid=
group=
context=default

;;; line="5 ATCOM-1600P/16/4 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
[color=#FF0000]busycount=13[/color]
channel => 5
callerid=
group=
context=default

;;; line="6 ATCOM-1600P/16/5 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 6
callerid=
group=
context=default

;;; line="7 ATCOM-1600P/16/6 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 7
callerid=
group=
context=default

;;; line="8 ATCOM-1600P/16/7 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 8
callerid=
group=
context=default

;;; line="9 ATCOM-1600P/16/8 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
[color=#FF0000]busycount=13[/color]
channel => 9
callerid=
group=
context=default

;;; line="10 ATCOM-1600P/16/9 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 10
callerid=
group=
context=default

====================
[root@lscpbx ~]# cat /etc/asterisk/chan_dahdi.conf
[trunkgroups]
[channels]
context=from-pstn
signalling=fxs_ks
rxwink=300 ; Atlas seems to use long (250ms) winks
usecallerid=yes
hidecallerid=no
callwaiting=yes
usecallingpres=yes
callwaitingcallerid=yes
threewaycalling=yes
transfer=yes
canpark=yes
cancallforward=yes
callreturn=yes
echocancel=yes
echocancelwhenbridged=no
faxdetect=both
;echotraining=800
;rxgain=0.0
;txgain=0.0
rxgain=1.2
txgain=2.5
callgroup=1
pickupgroup=1

;answeronpolarityswitch=no
;hanguponpolarityswitch=yes

faxbuffers=>6,full
echotraining=no
;Uncomment these lines if you have problems with the disconection of your analog lines
busydetect=yes
;busycount=13
[color=#FF0000]busycount=4[/color]
;busycount=8 ; after using this , it mad an echo ;
;using 4 it no autohangup , but there is interrupt when calling outbound calls
;busypattern=500,500
;hanguponpolarityswitch=no
;cidstart=polarity
;cidstart=ring
;when using cidstart=dtmf , the calls are no longer being recived on server
;hanguponpolarityswitch=no
immediate=yes
;ringtimeout=5000
;cidsignalling=dtmf
;cidstart=ring
;cidstart=ring
;cidsignalling=fsk
;callwait=yes

;callprogress=yes
;progzone=us
#include dahdi-channels.conf
#include chan_dahdi_additional.conf

You meant dahdi channel n, not dahdi n.

As I said, the setting applies to all channels defined until the next setting.

You can either move all the channels with special settings to the end, or you must repeat the standard value of busycount between the channel => line with the special value and the next channel => line.

Incidentally, there are a lot of redundant lines. This would probably be enough:

[code]; Span 1: ATCOM-1600P/16 “ATCOM AX1600P/800P Board 17” (MASTER)
;;; line="1 ATCOM-1600P/16/0 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 1

;;; line="2 ATCOM-1600P/16/1 FXSKS"
channel => 2

;;; line="3 ATCOM-1600P/16/2 FXSKS"
channel => 3

;;; line="4 ATCOM-1600P/16/3 FXSKS"
channel => 4

;;; line="5 ATCOM-1600P/16/4 FXSKS"
busycount=13
channel => 5
busycount=

;;; line="6 ATCOM-1600P/16/5 FXSKS"
channel => 6
[/code]

hi advid ,

thanks very much
i modified and set a static values for all dahdi channels and it succeed :smile:
:smile: :smile:
have a look here
[root@lscpbx ~]# ca t /etc/asterisk/dahdi-channels.conf
-bash: ca: command not found
[root@lscpbx ~]# cat /etc/asterisk/dahdi-channels.conf
; Autogenerated by /usr/sbin/dahdi_genconf on Thu Nov 29 08:15:23 2012
; If you edit this file and execute /usr/sbin/dahdi_genconf again,
; your manual changes will be LOST.
; Dahdi Channels Configurations (chan_dahdi.conf)
;
; This is not intended to be a complete chan_dahdi.conf. Rather, it is intended
; to be #include-d by /etc/chan_dahdi.conf that will include the global settings
;

; Span 1: ATCOM-1600P/16 “ATCOM AX1600P/800P Board 17” (MASTER)
;;; line="1 ATCOM-1600P/16/0 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=4
channel => 1
callerid=
group=
context=default

;;; line="2 ATCOM-1600P/16/1 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=4
channel => 2
callerid=
group=
context=default

;;; line="3 ATCOM-1600P/16/2 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=4
channel => 3
callerid=
group=
context=default

;;; line="4 ATCOM-1600P/16/3 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=4
channel => 4
callerid=
group=
context=default

;;; line="5 ATCOM-1600P/16/4 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=13
channel => 5
callerid=
group=
context=default

;;; line="6 ATCOM-1600P/16/5 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=4
channel => 6
callerid=
group=
context=default

;;; line="7 ATCOM-1600P/16/6 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=4
channel => 7
callerid=
group=
context=default

;;; line="8 ATCOM-1600P/16/7 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=4
channel => 8
callerid=
group=
context=default

;;; line="9 ATCOM-1600P/16/8 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
busycount=13
channel => 9
callerid=
group=
context=default

;;; line="10 ATCOM-1600P/16/9 FXSKS"
signalling=fxs_ks
callerid=asreceived
group=0
context=from-zaptel
channel => 10
callerid=
group=
context=default