[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Status of the multiple phone support

From: BORBELY Zoltan
Subject: Status of the multiple phone support
Date: Fri, 14 Nov 2003 00:31:01 +0100
User-agent: Mutt/1.4.1i


As someone noticed the multiple phone support item was removed from the
TODO file. The multiple phone support is almost ready. This mail explains
what have been done.

If you want to support multiple phones in one process you have to use
multithreading. The whole architecture and phone drivers are too complex,
so implementing it without threads should be much harder. Maybe we
can do it in the future, but eliminating threads usually isn't an
important requirement. The best arcitecture is to assign a dedicated
thread for each phone. If there are no user request, the thread can
issue a keepalive like command (e.g. GN_OP_GetNetworkInfo) to keep
the link busy. Each thread have to use a different state structure.
In the 0.4.x -> 0.5.0 transition all global variables was eliminated
and moved into the state structure, so you can use libgnokii in
MT application if you won't share this structure.

If you want to use gnokiirc in your application you can do it. Just
fill the first parameter of the gn_cfg_phone_load() function. If
you specify NULL or empty string, it will use the settings in the
[global] block.  If you specify "foo", it will load the settings
specified in [global] and [phone_foo] section ([global] section
treated as a template).

I think the multiple phone support is ready, but we have no time to
test it. There are applications which can benefit from it (e.g. smsd)
and there are some which cannot (e.g. gnokii or xgnokii). I think
gnokii and xgnokii can support only one phone at a time, but we
have to provide some selection mechanism in the future (e.g. a
command line option or an environment variable).


reply via email to

[Prev in Thread] Current Thread [Next in Thread]