[Home]

Summary:ASTERISK-01990: [request + patch] Please implement RP-AS : Ring Puls Alert Signal. (CallerID)
Reporter:vmeyer (vmeyer)Labels:
Date Opened:2004-07-11 04:54:09Date Closed:2008-01-15 15:08:26.000-0600
Priority:MajorRegression?No
Status:Closed/CompleteComponents:Core/NewFeature
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) chan_zap.c-1.diff
( 1) zaptel.c-1.diff
Description:Some telephon in France (e.g. Siemens gigaset) need a first short ring called RP-AS to get callerid.

Bug 600 told about it among other things.
ericbart wrote :
 In France (and probably in all Europe), an alerting signal is
 sent just before the CID. A short ring signal may be used for AS.
 This short ring is called Ring Pulse Alert Signal (RP-AS). From a
 document called ETSI EN 300 659-1 V1.3.1 (2001), timings are :
 (1) 200ms < RP-AS duration < 300ms
 (2) 500ms < RP-AS to FSK pulse < 800ms
 (3) 200ms < FSK pulse to second ring < 500ms

 The Asterisk problem is to guarantee these timings.

 (1) The bug comes from the first timing. I tested it with a
 custom ring cadence for the TDM400P. To test it yourself,
 use the Ast patch and use the dial command with resource
Zap/Xr4.

 (2) I first tried to solve the bug by adjusting the second
 timing. Now I don't know wether it's neccessary or not.
 It's implemented in the Ast patch with a simple counter.

 (3) I did not try to deal with the third one.

He's patch consist in modifying ringcadences by inserting a short ring (point (1), I had to discard (2) since it didn't work for me):
(static struct zt_ring_cadence cadences[NUM_CADENCE_MAX] in chan_zap.c)

normal ring cadence in France : { 1500, 3500 }
with RP-AS simulated : { 250, 3000, 1500, 3500 , 1500, 3500, ... }  (this works for me)
CallerID must be sent after the first short ring.

The problem is when it rings too much time and loops to the simulated RP-AS.
Moreover it should be set through a configuration file.
Comments:By: vmeyer (vmeyer) 2004-07-21 09:47:50

[patch]

Normal ringcadence for me is 1500,3500
RP-AS Should result in 200,1500,1500,3500
with 200,1500 played only once at the start and then normal 1500,3500.

I wrote some code to allow that.
- in asterisk/channels/chan_zap.c
 I allowed one negative ring duration to indicate where to loop back at the end of the cadence (as was done with silent duration for cid position).
 That negative duration is left negative.
- in zaptel/zaptel.c
 When getting cadences from asterisk I set a new variable called firstcadencepos with position of the first negitive ring timing. This time is then converted to a positive number.
 At the start of a call, cadencepos is, as before, initialized to 0.
 At the end of the cadence, cadencepos is set to firstcadencepos instead of 0, thus skipping unwanted first part.

 This patch works for me with following configuration in /etc/asterisk/zapata.conf :
cadence=200, -1500, -1500, 3500
        |      |      |     |normal silent duration
        |      |      |normal ring duration, negative -> loop back here
        |      |First silence during which cid is transmitted
        |The so-called Ring Puls Alert Signal

asterisk*CLI> zap show cadences
r1: 200,1500,-1500,3500

I didn't tried to set such a cadence somewhere else (code, indications,...)

Conclusion :
It works for me, feedback welcome to achieve better code.

By: twisted (twisted) 2004-08-24 13:33:15

Update request - last call.  /* Housekeeping */

By: Julien Lesaint (jlesaint) 2004-08-24 14:16:59

Update what ? What kind of update do you think Vincent could put in this case ?

By: Mark Spencer (markster) 2004-08-24 15:05:47

Do we have a disclaimer?

By: twisted (twisted) 2004-08-25 17:58:25

Reminder sent to vmeyer

Please respond at your earliest convienence.

By: vmeyer (vmeyer) 2004-08-26 11:27:08

I simply don't understand what you are waiting for me to do.
I've done this bug report to first ask for an improvment and then suggest a way to do it.
I don't think that I can give you another feedback. I works perfectly there for weeks.
Now you can use that code into asterisk, or ask me to do it better.
I know that it is not perfect but I didn't want to spend much time before knowing if this kind of implementation would be accepted.

By: twisted (twisted) 2004-08-26 12:02:38

we are waiting for a disclaimer to be filed with digium.  The patch will not be accepted without a disclaimer.  Do you have one on file?

By: vmeyer (vmeyer) 2004-08-26 15:16:20

I just have sent a disclaimer by fax as described on this website's main page.

By: Mark Spencer (markster) 2004-09-30 11:23:55

Added to CVS, thanks!

By: Russell Bryant (russell) 2004-09-30 20:42:17

new feature - not included in the 1.0 branch

By: Digium Subversion (svnbot) 2008-01-15 15:08:26.000-0600

Repository: asterisk
Revision: 3856

U   trunk/channels/chan_zap.c

------------------------------------------------------------------------
r3856 | markster | 2008-01-15 15:08:25 -0600 (Tue, 15 Jan 2008) | 2 lines

Merge ring pulse stuff (Bug ASTERISK-1990)

------------------------------------------------------------------------

http://svn.digium.com/view/asterisk?view=rev&revision=3856