Implementing a new codec - First steps?

Hello everybody,

I am building a small telephone museum and especially trying to integrate old ISDN phones into my system. Some of them can do H263 video calling, some use a standard called Datex-J to communicate with a German Videotext system called Btx, etc. I’d like to integrate those via VoIP and send/receive their data in Asterisk, however all gateways I’ve used so far translate those calls into RFC 4040 CLEARMODE and not into their respective SIP counterparts.

It seems Asterisk doesn’t know what to do with this codec and so I’m wanting to add support for it. I know this has come up several times already but has never been implemented.

How would I go about adding another codec? I looked at the existing source and tried some (basically replicating G729) but it still doesn’t get picked up by pjsip.

Is there documentation on this topic?

There is no documentation for this, it’s pretty much finding a recent codec that was added and following what was done.

There are several open-source codecs. However, those are not only pass-through but also transcoding modules. Quite complicated. If you are looking simply for a transcoding module, have a look how H.265 was added … (see the attached patch). Not sure if that fits CLEARMODE.