xnux.eu - site map - news

Voice calling app

Making a calling app from scratch is surprisingly simple on Linux, so I intend to make one for myself. It comes down mostly to configuring a bunch of controls in ALSA, and talking to a modem via AT interface, using a small set of commands, like A to answer a call, D to dial a number, or H to hangup. You don't need any libraries really to do that, and it can be done with a few hundreds lines of C code without any dependencies.

In total, the basics of controlling the modem and the audio come down to using about 10 different ioctls on four different devices. Math object in JavaScript has more complicated API surface than this.

Implementing the UI will be slightly harder, but I can simplify things and not try to push everything to the UI interface and leave more complicated stuff to be configurable via some text files and scripts. It will be much more flexible and easier to manage too (for me ;)).


I intend my voice calling app to have these features at the very least:


At the moment I have the core functionality of making and taking the calls and configuring the audio codec working in an interactive command line app, that can be also seen in this video:

Next step is to make the code more re-usable, and add a way to read/write audio streams via the PCM device and start implementing a touch UI for my app.