0

I have Asterisk 1.6 with a analogic card X100p that work properly. I want to detect if the card is in use or not (the status of the card).

Please any one get the problem before ?

1
  • this the output of the command "core show channels": > Channel Location State Application(Data) > 0 active channels 0 active calls 26 calls processed you think this is normal?
    – dectroo
    Aug 18, 2011 at 10:01

3 Answers 3

1

You can use "show channels" command

voip*CLI> show channels
Channel              Location             State   Application(Data)             
DAHDI/3-1            s@ivr-3:12           Up      BackGround(someexample)
1 active channel
1 active call

You can differentiate a DAHDI device by the channel name.

4
  • this the output of the command "core show channels": Channel Location State Application(Data) 0 active channels 0 active calls 26 calls processed you think this is normal?
    – dectroo
    Aug 18, 2011 at 9:58
  • You mean about 0 Active Channels, 0 active calls? It means nobody is calling right now, if you can be sure there is a call running, then it's not normal.
    – ghm1014
    Aug 18, 2011 at 13:59
  • it's work, i made a call and send the cmd "core show channels" and it's work.
    – dectroo
    Aug 18, 2011 at 15:17
  • Good, shouldn't you mark the answer as correct?
    – ghm1014
    Aug 19, 2011 at 14:07
0

asterisk -rx "dahdi show channel 1" |grep Onhook >/dev/null || echo "In Use"

-1
dahdi show channels

in the asterisk console to show what channels managed by dahdi are in use. Also there's dahdi show status, but I'm not sure of the output.

4
  • "dahdi show status" show the status of the card, "dahdi show channel _ " dont give any information about the channel; if it's in use, busy,...
    – dectroo
    Aug 16, 2011 at 13:19
  • Are you sure you have configured your card to provide channels FXO's to asterisk? (usually it's /etc/asterisk/chan_dahdi.conf)
    – O G
    Aug 16, 2011 at 13:56
  • Yes it's work perfectly, i can make call through PTSN.
    – dectroo
    Aug 16, 2011 at 18:58
  • freepbx.org/forum/freepbx/users/x100p-channel-not-working - seems there are some complains concerning this card model, hence the recommended method does not provide the needed output.
    – O G
    Aug 17, 2011 at 16:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .