Baresip DTMFIO module

The main thing that I will be using the URIx-Util lib for once it is "finished" is to control a radio's push to talk signal while it is being fed audio from some form of VoIP program. Historically, this has been SIP since, prior to the URIx-Util library being written, the only program that we have been able to find that will control the URIx is the extremely out of date chan_usbradio Asterisk module. In this setup, the radio had to be connected to the Asterisk server. This means, if you have radios in multiple places you had to have (and administer, and secure) multiple Asterisk servers and deal with trunking.

Yesterday, I came across the baresip program: an extremely basic, command line, SIP client. After messing around a bit with the program, I found that it had major potential to be the client that served the radios. I set up a test which utilized the URIx-Util lib and snagging the stderr of the baresip program. After much cringing at how gross this code was, but proving the concept worked, I was very happy and began to plan how to better get the DTMF events out of the SIP client.

Thus, I began the process of learning a C based module API that has no (real) documentation associated with it (at least that I could find).

After a few hours of poking at it, giving up, realizing a better way to do it, more poking at it, etc., this pull request was born.

Here is the info from the pull request:



Writes received dtmf button presses to a FIFO located at /tmp/dtmf.out.
Also, will write an 'E' when a call is established and an 'F' when the call is finished.

To Do

  • Proper error handling
  • Using a dtmf.in file, be able to send DTMF signals
  • Use a filename specified by the user in the config file
  • Clean up build output so there aren't errors regarding unused vars

No comments:

Post a Comment