← Back to team overview

rohc team mailing list archive

Re: Bidirectional mode in ROHC

 

Hi,

> I am a beginner with ROHC liberary. I have successfully used the ROHC
> liberary with the unidirection mode but I have some ambiguities
> regarding the use of bidirectional mode. I am using two different
> machines as a client and server and therefore my decompressor will not
> have any clue of the associated compressor at the other machine. How
> should I proceed with the bidirectiona mode.

For bidirectional mode, you have to setup two couples of ROHC
compressors and decompressors. Compressor A and Decompressor B are
located on host #1. Compressor B and Decompressor A are located on host
#2. Decompressor A sends feedback data to Compressor A through
Compressor B and Decompressor B. See the figure below:

    Host #1             Network              Host #2

  Compressor A    ---- ROHC packets ---->  Decompressor A
    /\                                              |
     |                                              |
     | feedback from                  feedback from |
     | Decompressor A                Decompressor A |
     |                                              |
     |                                             \/
  Decompressor B  <---- ROHC packets ----  Compressor B
                      + feedback of A


> My concerns are:
> 1-Which function in the liberary allows the decompressor to send an
> ACK or NACK after decompressing the packet and how this function can
> be used here?

You just have to link Decompressor A / Compressor B on host #2 and
Decompressor B / Compressor A on host #1. It can be done by specifying
the Compressor B structure as first argument when creating the
Decompressor A with the rohc_alloc_decompressor() function and by
specifying the Compressor A structure as first argument when creating
the Decompressor B with the rohc_alloc_decompressor() function.

See the complete documentation about the rohc_alloc_decompressor()
function:
http://www.tech.viveris.com/docs/rohc/group__rohc__decomp.html#g5848bedb63470ce0675033796f6de95a


> 2-How can the compressor be forced to change its states when using the
> bidirectional mode?

Once you associated a compressor to a decompressor, the decompressor
will automatically start using it to send feedback. When a compressor
receives a positive feedback from its compressor, it automatically
transits from U-Mode to O-Mode. So, you have nothing to do to force the
transition except associating compressors and decompressors together.

The non-regression application configures 2 ROHC couples to work
together in order to test the Bidirectional Optimistic mode (O-Mode).
Looking at its code (and comments in it) might help you. See
http://bazaar.launchpad.net/~didier-barvaux/rohc/main/annotate/head:/test/test_non_regression.c

If you got additional questions, do not hesitate to contact the list
again.

Regards,
Didier Barvaux

Attachment: signature.asc
Description: PGP signature


References