odeviced: Progress report
Sudharshan S
sudharsh at gmail.com
Wed May 28 10:44:17 CEST 2008
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Guillaume Chereau wrote:
> Hello Sudharshan !
>
> Great project. It is cool to use Vala instead of C, specially when using
> DBus.
> I really like to see this in your code :
>
Thanks! :D
> [DBus (name = "org.freesmartphone.Device")]
> public class Service: Object {
> ...
> }
> And then think about all the code it would need to express the same
> thing in C !
Indeed! Many thanks to mickeyl for that. He suggested Vala as an
implementation language.
> I like the plug-in architecture as well. Very promising !
>
> Do we already have the org.freesmartphone.Device specification ?
> Can we start to generate this and put it online ? (maybe with the
> automatic script we discussed before on this list)
Not yet, need to discuss with mickeyl and the fso community on that. I
looked at python-odeviced code to see how it works. Some of the methods
on the "org.freesmartphone.Device" that I can think of right now include,
load(string plugin_name) returns bool
unload(string plugin_name) returns bool
get_dependencies(string plugin_name) returns string[]
get_device_name(void) returns string
is_loaded(plugin_name) returns bool
As per my understanding, using vala removes the need for
dbus-binding-tool to process interface xml files. So there isn't any
org.freesmartphone.Device.xml.
Isn't an xml interface file required to generate the docs?.
As for the plugins, the service just looks if they have <plugin>_init in
their sources. The DBus interface (or even lack of) which they export
are upto the plugin writers. I would like to have comments on this.
The current logic is pretty simple but at the cost of looking like a
hack IMHO.
Using GTypeModules in the code brings in a cozy dynamic typing mechanism
for the plugins. But it means more boilerplate code for the plugins.
Something which I find to be less appealing. Most Gnome apps use
GTypeModule to wrap up GModule instances. Something similar to the
plugin class present in plugin.vala.
What do you guys think? To GTypeModule or not to GTypeModule?
> Another thing : I don't know how difficult it should be, but would it be
> possible to add a "simulated" option to some of the devices, so that we
> can test the software on any computer ?
>
Cool. For things like wifi plugins you could run odeviced as it is. But
yes, since FreeRunner has special devices adding a simulated option
makes sense. Especially for GPS and friends.
Maybe add a --simulate=<plugin> or even --simulate command line argument?
> I would also be interested to compare the speed and memory usage with
> the python implementation. Was the python code too slow ?
>
I am not aware of the performance of python-odeviced on FreeRunner.
Maybe someone here can enlighten us.
Regards
Sudharshan S
Blog : http://www.sudharsh.wordpress.com
IRC : Sup3rkiddo @ freenode
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkg9G2EACgkQSsRjJNRMc4lImwCcDqxu/n6epf/iFS0CPXMfceo9
0y4An0wbsyH6pmvldgKPMcHMyXhn0al8
=QNjK
-----END PGP SIGNATURE-----
More information about the smartphones-standards
mailing list