dect
/
asterisk
Archived
13
0
Fork 0
Commit Graph

216 Commits

Author SHA1 Message Date
tilghman 3bacd4082e Expand codec bitfield from 32 bits to 64 bits.
Reviewboard: https://reviewboard.asterisk.org/r/416/


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@227580 f38db490-d61c-443f-a65b-d21fe96a405b
2009-11-04 14:05:12 +00:00
rmudgett 225f4a7ea1 DAHDI ISDN channel names will not allow device state to work. (Interim solution.)
Since ISDN works like SIP and not analog ports in regard to devices, the
device state based on the ISDN channel number could not work.  This has
not been an issue until the advent of PTMP NT mode.  Previously, ISDN
lines were used as trunks and did not have to keep track of specific
devices.

As an interim solution until device states are properly implemented, the
channel name is being changed to the following format to use the generic
device state support:
DAHDI/i<span>/<number>[:<subaddress>]-<sequence-number>

Dialplan hints would thus be:
exten => xxx,hint,DAHDI/i2/5551212

This will work with the following restrictions:
*  The number of devices/phones cannot exceed the number of B channels.
(i.e., BRI has 2)
*  Each device/phone can only have one number.  No shared MSN's.
*  The phones/devices probably should not use subaddressing.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@226882 f38db490-d61c-443f-a65b-d21fe96a405b
2009-11-02 17:34:22 +00:00
rmudgett d9cdfa12c3 Cleanup some flags on DAHDI PRI channel hangup.
*  Cleanup some flags on DAHDI PRI channel hangup. (sig_pri split)
*  Make sure the outgoing flag is cleared if a new channel fails to get
created for outgoing calls.
*  Remove some unused flags since sig_pri was split.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@226648 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-30 23:26:41 +00:00
rmudgett 119cfd907f Make conditionals create previous code when libpri/ss7 are present.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@225872 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-26 16:07:09 +00:00
tzafrir e3b8c49f5d span numbers in pri debug / error messages
Prefix PRI trace messages with the span number. This makes the trace
readable even when you have a multi-port device.

(closes issue #15054)
Reported by: tzafrir
Patches:
      dahdi_pri_debug_spannum.diff uploaded by tzafrir (license 46)



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@225836 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-26 13:29:54 +00:00
tzafrir 53699afbb7 Re-arange code a bit to build in dev-mode without ss7
No change of functionality here. Just localized a variable and indented
code into blocks.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@225803 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-26 11:34:06 +00:00
tzafrir 7eaa3b83ad Make chan_dahdi build even without PRI / SS7
(Note: still some strange build warnings without SS7 in dev-mode)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@225767 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-26 09:40:49 +00:00
rmudgett 4ad439617d Add to chan_dahdi ISDN HOLD, Call deflection, and keypad facility support.
* Added handling of received HOLD/RETRIEVE messages and the optional ability
  to transfer a held call on disconnect similar to an analog phone.
* Added CallRerouting/CallDeflection support for Q.SIG, ETSI PTP, ETSI PTMP.
  Will reroute/deflect an outgoing call when receive the message.
  Can use the DAHDISendCallreroutingFacility to send the message for the
  supported switches.
* Added ability to send/receive keypad digits in the SETUP message.
  Send keypad digits in SETUP message: Dial(DAHDI/g1[/K<keypad_digits>][/extension])
  Access any received keypad digits in SETUP message by: ${CHANNEL(keypad_digits)}
* Added support for BRI PTMP NT mode.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@225692 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-23 16:57:33 +00:00
mnicholson c246fa7865 Add dynamic range compression support for analog channels.
(closes issue AST-29)


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@224637 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-19 22:02:41 +00:00
jpeeler 92c0c97b67 fix typo, sorry
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@224335 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-17 02:01:36 +00:00
jpeeler f9da7c70a1 Merged revisions 224330 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r224330 | jpeeler | 2009-10-16 20:32:47 -0500 (Fri, 16 Oct 2009) | 13 lines
  
  Fix stale caller id data from being reported in AMI NewChannel event
  
  The problem here is that chan_dahdi is designed in such a way to set
  certain values in the dahdi_pvt only once. One of those such values
  is the configured caller id data in chan_dahdi.conf. For PRI, the
  configured caller id data could be overwritten during a call. Instead
  of saving the data and restoring, it was decided that for all non-analog
  channels it was simply best to not set the configured caller id in the
  first place and also clear it at the end of the call.
  
  (closes issue #15883)
  Reported by: jsmith
........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@224331 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-17 01:36:08 +00:00
jpeeler f1bedb0db3 Change ringt (ring timeout) styles to be consistent across chan_dahdi.
(closes issue #15684)
Reported by: alecdavis
Patches: 
      chan_dahdi.bug15684.diff2.txt uploaded by alecdavis (license 585)
Tested by: alecdavis


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@222652 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-07 20:08:14 +00:00
jpeeler e0fa564f1b Merged revisions 222462 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r222462 | jpeeler | 2009-10-06 18:51:19 -0500 (Tue, 06 Oct 2009) | 8 lines
  
  Add missing unlock(s) in dahdi_read
  
  (two cases in trunk)
  
  (closes issue #15683)
  Reported by: alecdavis
........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@222463 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-06 23:56:01 +00:00
jpeeler 41e7baf28b Fix 222298 (crash during destruction of second channel when variable set with
setvar).

I mistakenly reasoned that setvar would be used on all channels. Since it can
be set per channel, give each dahdi channel a copy of the variable.

(related to #15899)



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@222351 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-06 20:35:19 +00:00
jpeeler 074498cb9b Fix crash during destruction of second channel when variable set with setvar.
The setvar line in chan_dahdi.conf is shared among all the channels, so make
sure to only free the resources only when the last channel is destroyed.

(closes issue #15899)
Reported by: tzafrir



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@222298 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-06 19:24:59 +00:00
tzafrir 1805a24b82 Make sure digit events are not reported as "ERROR"
dahdievent_to_analogevent used a simple switch statement to convert DAHDI
event numbers to "ANALOG_*" event numbers. However "digit" events
(DAHDI_EVENT_PULSEDIGIT, DAHDI_EVENT_DTMFDOWN, DAHDI_EVENT_DTMFUP)
are accompannied by the digit in the low word of the event number.

This fix makes dahdievent_to_analogevent() return the event number as-is
for such an event.

This is also required to fix #15924 (in addition to r222108).  


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@222237 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-06 16:17:30 +00:00
jpeeler 9a43d9b1fc Add a few missing events to analog_handle_event.
The reported bug was actually only for pulsedigit, dtmfup, and dtmfdown
handling. Also added recognition for fax events (just some verbose output) and
fixed handling for the ec_disabled_event. In order to make comparing the analog
version of events to the DAHDI events easier, the ordering has been changed to
follow that of the DAHDI events.

(closes issue #15924)
Reported by: tzafrir



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@222108 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-05 19:20:36 +00:00
rmudgett e5c9046575 Prevent deadlock if chan_dahdi attempts to change PRI channel names.
The PRI channels can no longer change the channel name if a different B
channel is selected during call negotiation.  To prevent using the channel
name to infer what B channel a call is using and to avoid name collisions,
the channel name format is changed.

The new channel naming for PRI channels is:
DAHDI/ISDN-<span>-<sequence-number>


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@221701 f38db490-d61c-443f-a65b-d21fe96a405b
2009-10-01 19:48:58 +00:00
rmudgett df2f3c7fcd Miscellaneous minor changes.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@220792 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-28 21:02:20 +00:00
jpeeler 9e59862a57 Add some changes related to 218430.
* Remove thread_spawned in handle_init_event since it was never used
* Always check handle_init_event in case a channel is destroyed


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@218583 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-15 16:12:49 +00:00
tzafrir 3db1a68fa6 Fix false error message on DAHDI_EVENT_REMOVED (RESULT_SUCCESS == 0)
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@218465 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-15 10:24:55 +00:00
jpeeler de5d26c346 Merged revisions 218401 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r218401 | jpeeler | 2009-09-14 16:47:11 -0500 (Mon, 14 Sep 2009) | 11 lines
  
  Fix handling of DAHDI_EVENT_REMOVED event to prevent crash in do_monitor.
  
  After talking to rmudgett about some of his recent iflist locking changes, it
  was determined that the only place that would destroy a channel without being
  explicitly to do so was in handle_init_event. The loop to walk the interface
  list has been modified to wait to destroy the channel until the dahdi_pvt of
  the channel to be destroyed is no longer needed.
  
  (closes issue #15378)
  Reported by: samy
........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@218430 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-14 22:38:25 +00:00
rmudgett ef7b0cc05f Add support for multiple interface lists.
Also unlink the sig_pri_pri.pvts[] pointer in destroy_dahdi_pvt().


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@218365 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-14 20:08:11 +00:00
moy 8a61c0c034 get rid of mfcr2 monitor thread condition, is problematic
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@218150 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-13 05:51:46 +00:00
jpeeler 2b5aca0054 Cleanup approach in 217804 and don't reach inside the sig_pvt.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217987 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-10 23:49:09 +00:00
jpeeler 5e30f2459e Allow do not disturb to be set on analog channels via the CLI and AMI.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217954 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-10 23:29:14 +00:00
rmudgett 18b1e2db56 Cleaned up chan_dahdi iflist handling and locking.
*  Fixed walking the iflist so it is always done with the iflock locked.
*  Simplified iflist walking routines.
*  Created chan_dahdi iflist insertion and extraction routines.
*  Fixed duplicate_pseudo() malloc fail handling.
*  Fixed infinite loop in action_dahdishowchannels() when showing a single channel.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217912 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-10 22:31:12 +00:00
rmudgett 287a824c96 Miscellaneous minor changes.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217873 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-10 22:11:17 +00:00
jpeeler 15b9bcfd0d Fix crash during attended transfer over PRI.
The owner pointers in the sig_pri_chan structure were not getting updated
in dahdi_fixup. 


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217804 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-10 20:52:57 +00:00
jpeeler 9ede9adeb0 Stop caller id transmission when offhook event detected.
This fixes the problem that would occur if an analog phone was picked up while
the caller id was being sent. The caller id before sent the whole spill even
after pickup and is now corrected.



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217744 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-10 20:18:30 +00:00
rmudgett 614bae94d5 Fix available() for SS7, MFC/R2, and pseudo channels.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217560 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-10 00:35:30 +00:00
moy 09a519d48b ast_log replaced for ast_verbose in MFCR2 event notifications
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217524 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-09 21:48:04 +00:00
rmudgett 7ca87fcab5 Fix memory leak of sig_xxx private structures.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217332 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-08 23:37:57 +00:00
rmudgett 2c3011915a Miscellaneous minor code cleanup in mkintf().
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@217331 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-08 23:31:27 +00:00
rmudgett 28022e8fe3 Lets try not to use C++ keywords for variable names.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@216186 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-03 21:09:46 +00:00
dbailey ab91083f55 Added detection DTMF CID without polarity change alert.
Added detection of DTMF tone energy levels on FXO channels in chan_dahdi
monitoring loop so DTMF CID can be detected without the need of a polarity
change precursor.  

(closes issue #9096)
Reported by: fleed
Patches:
      9096-chan_dahdi-trunk.diff uploaded by dbailey (license 819)
Tested by: cyberplant, sum, maturs


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@216094 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-03 19:40:37 +00:00
rmudgett 9d636a0087 Made chan_dahdi able to ignore incoming calls that are not in a MSN list for ISDN PTMP CPE spans.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@215757 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-02 23:25:33 +00:00
dbailey bfcf648150 Fix issue where DTMF CID detect was placing channels into signed linear mode
made analog_set_linear_mode return back the mode that was being overwritten 
so it could be restored later. 


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@215608 f38db490-d61c-443f-a65b-d21fe96a405b
2009-09-02 19:49:43 +00:00
moy 29f797e02f improve handling of openr2_chan_disconnect_call API failure, unlikely, but happened on openr2 library bug
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@213790 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-24 04:46:28 +00:00
moy 6bb43a8a38 increment the mfcr2 monitor count when clearing the call request
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@213454 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-21 04:09:26 +00:00
moy 5ffb96a556 fixed bug caused by calling ast_request without calling ast_call on an R2 channel, ie, CHANISAVAIL
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@213216 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-20 03:26:59 +00:00
rmudgett 493dabadd3 Merged revisions 212430 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

Fix uninitialized variable causing random MWI indications.

(closes issue #15727)
Reported by: doda
Patches:
      dahdi_changes.patch uploaded by doda (license 853)

........
  r212430 | rmudgett | 2009-08-17 10:36:28 -0500 (Mon, 17 Aug 2009) | 1 line
  
  Fix uninitialized variable.
........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@212431 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-17 15:42:51 +00:00
jpeeler 0b81a31cd6 More code that somehow got left out of sig_analog
* confirmanswer option now respected
* check and set waiting for dialtone timer
* unneeded needcallerid flag removed from analog_subchannel
* ss_astchan does not need to be a void pointer
* swap_channels callback updated to trunk
* analog_hangup now resets channel to default law


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@212287 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-14 22:39:11 +00:00
jpeeler 01b8e52ac3 Fix chan_dahdi option ringtimeout
dahdi_read relies on the dahdi_pvt copy of ringt which was not getting set
in sig_analog. This patch adds a callback to do so.

(closes issue #15288)
Reported by: alecdavis
Patches:
      chan_dahdi.ringtimeout.diff.txt uploaded by alecdavis (license 585)
Tested by: alecdavis



git-svn-id: http://svn.digium.com/svn/asterisk/trunk@211908 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-12 20:47:45 +00:00
rmudgett 593c44bc43 Encapsulate testing for which signaling styles are used by sig_pri.
Created the dahdi_sig_pri_lib_handles() function and
SIG_PRI_LIB_HANDLE_CASES macro to simplify testing for which signaling
styles are handled by sig_pri.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@211675 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-10 23:21:57 +00:00
tilghman d1ec1aa57d AST-2009-005
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@211539 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-10 19:20:57 +00:00
jpeeler baf55cdd42 Fix PRI/BRI channels when in alarm condition to only be marked for hangup if
T309 is not enabled.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@211435 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-10 17:17:06 +00:00
rmudgett 9849a632bb Restoring some code to sig_pri. Not sure if it is really needed.
Putting some DSP code back into sig_pri that was removed by the
chan_dahdi/sig_pri reorganization.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@211392 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-10 15:53:23 +00:00
rmudgett 673ecef518 Fixed some unsafe down cast pointer operations for sig_pri.
You cannot cast the struct dahdi_pvt.sig_pvt pointer to a specific
signaling private pointer without first checking that it is in fact
pointing to the correct signaling private structure.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@211197 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-07 23:30:32 +00:00
rmudgett dbfdc11927 More changes from chan_dahdi that did not make it into sig_pri.
*  Q.SIG channel mapping option.
*  discardremoteholdretrieval option.
*  libPRI debug defines.
*  pri_set_overlapdial() now set correctly.
*  pthread creation of pri_ss_thread now matches.


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@210696 f38db490-d61c-443f-a65b-d21fe96a405b
2009-08-05 22:46:37 +00:00