Summer of Pinephone: Week 6

At long last, my Pinephone has a GUI can receive phone calls! As it turns out, I was wrong about there being no way of retrieving the phone number of the calling party on RING: you just have to set AT+CLIP=1, and the +CLIP URC will contain the phone number whenever the phone rings. Similarly, AT+COLP=1 lets the phone be notified when the other end picks up if I start a call. This means that we no longer have to issue AT+CLCC to get information about all known calls anymore, simplifying atd substantially. It also means that the call handler interface that I described last week is gone, replaced by a simpler one.

Along with atd, we now have a calld, responsible for managing calls and their GUIs. When calld is notified of an incoming call by atd, it launches the answer program, which displays a dialog with the phone number of the caller, along with two buttons to accept or decline the call. The return code of answer is dependent upon whether call is accepted or declined, so calld uses this information to determine whether to launch the call program, which will be the interface for managing active calls. For now, calld supports managing only one call at a time. Also it doesn't manage call audio yet, but I plan to make it do so.

I also finally took the time to write a compositor based on swc. It is pretty simple at the moment, only 79 lines of code. The point, however, is just to have something to build upon as I need more compositor features.

The video demonstration is back this week. I am called (normally the phone number of the callee would be where it says "redacted"), and calld is notified that there is a call incoming by atd, and launches the answer dialog. I accept the call by tapping the green button, which tells the answer dialog to exit with code 0, notifying calld that I accepted the call. calld then launches the call program. The green bar that you saw is where the audio input/output controls will eventually go. I then end the call by tapping the red button. calld is notified that the call program exited by SIGCHLD, and updates its internal state, leaving it ready to accept a new call. I am called again, and I decline the call.