[sip-comm-dev] GSoc 09 : DTMF progress report

Romain filirom1 at gmail.com
Wed Jul 29 16:50:36 CEST 2009


Hi

Today is a good day for DTMF.
It is working using Transformers.
But there is some refactoring to do :)

I created a new transformer called DTMF.

There is a dtmfTransformerEngine, I add it in the list of Transformer
in order to allow both DTMF and ZRTP transformation.
In CallSessionImpl :
    private void initializeRtpManager(RTPManager rtpManager,
                                      SessionAddress bindAddress)
....
            if (rtpManager.equals(audioRtpManager))
            {
                dtmfEngine = new DtmfTransformEngine();

transformConnector.addEngine(TransformManager.DtmfKey,dtmfEngine);
            }

When the user press DTMF digits,
CallSession#startSendingDtmf(digit) is called.
Packet transformation start !

When the user release DTMF digit,
CallSession#stopSendingDtmf() is called.
Packet transformation stop.

A timeout is implemented in case there is is a bug when the user press
the digit, but no release event happen.

If the user release the digit too quickly, some digits could be
missing. I implemented a functioon called quickStopAvoidance which
take care of avoiding this.

In the transformers, only RTP outcoming packet are transformed.

So transfomation happens in DtmfRTPPacketTransformer, in transform function.

There is several different DTMF packets to send in DTMF. To do it I
used a state machine with 4 states :
START_SENDING (1x) -> SENDING_UPDATE (a lot)-> STOP_SENDING (1x) ->
STOP_SENDING_REPEATING (2x).

 - START_SENDING add RTP marker flas
 - STOP_SENDING freeze the timestamp and the duration
 - STOP_SENDING_REPEATING add End Flag


The class DtmfRawPacket is creating a Raw DTMF Packet, that will be
send via the DtmfRTPPacketTransformer

I added every patch I created from now that are important for DTMF :
 - DTMF.patch is used to add every DTMF functions
 - DTMF_CallSessionImpl is a patch that need to be aplied after
transformer_new patch. It is for DTMF integration in CallSessionImpl.
 - transformer_new is used for refactoring Transformers. We could now
use a list of engine.
 - dispatcher is creating a new way of sending DTMF using OperationSetDTMF
 - Configuration_GUI for the user to control how SC send DTMF (Sip INFO or RTP)

Cheers

Romain
-------------- next part --------------
A non-text attachment was scrubbed...
Name: transformer_new.patch
Type: application/octet-stream
Size: 45324 bytes
Desc: not available
URL: <http://lists.jitsi.org/pipermail/dev/attachments/20090729/e9ade5e0/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: DTMF.patch
Type: application/octet-stream
Size: 32029 bytes
Desc: not available
URL: <http://lists.jitsi.org/pipermail/dev/attachments/20090729/e9ade5e0/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: DTMF_CallSessionImpl.patch
Type: application/octet-stream
Size: 2294 bytes
Desc: not available
URL: <http://lists.jitsi.org/pipermail/dev/attachments/20090729/e9ade5e0/attachment-0002.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dispatcher.patch
Type: application/octet-stream
Size: 39506 bytes
Desc: not available
URL: <http://lists.jitsi.org/pipermail/dev/attachments/20090729/e9ade5e0/attachment-0003.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Configuration_GUI.patch
Type: application/octet-stream
Size: 8879 bytes
Desc: not available
URL: <http://lists.jitsi.org/pipermail/dev/attachments/20090729/e9ade5e0/attachment-0004.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: screenshot.png
Type: image/png
Size: 251672 bytes
Desc: not available
URL: <http://lists.jitsi.org/pipermail/dev/attachments/20090729/e9ade5e0/attachment.png>
-------------- next part --------------
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe at sip-communicator.dev.java.net
For additional commands, e-mail: dev-help at sip-communicator.dev.java.net


More information about the dev mailing list