gnokii-users
[Top][All Lists]
Advanced

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

Re: Feasibility: Java based API access to gnokii


From: Phil Ashby
Subject: Re: Feasibility: Java based API access to gnokii
Date: Wed, 18 Jan 2006 20:35:38 +0000
User-agent: Debian Thunderbird 1.0.2 (X11/20051002)

Harsha Ramesh wrote:
Coming from a pure Java background, I am having a difficult time understanding the source code of gnokii in order to be able to develop any added functionality to the codebase.

I am wondering if it is possible to build the gnokii libraries in Java. I understand that there are a great number of difficulties involved in this, but I would like to know the feasibility of doing the gnokii work in Java.

Hmmn. Interesting question Harsha :)

The majority of libgnokii is bit/byte oriented data processing and state management to implement specific protocols for the phone models it supports. This would be readily portable to Java which has similar capabilities. Some of it however is operating system specific code to interface with serial devices and/or Bluetooth and IrDA protocol stacks, this would be more difficault to port since Java lacks support for communicating directly with devices (no ioctl() support for instance), instead it relies on underlying JNI libraries (including the standard JVM runtime) for this. This means the common/devices/* code would likely have to remain in C, perhaps writing a JNI wrapper around devices.c? It would be a *lot* of work to port all the library code however.

If you are thinking of adding features at a higher layer in the protocol implementation, then all library code can remain in C, and the JNI wrapper could go around the gsm-api.c functions (ie: the entry points to libgnokii). This would allow re-implementation / porting of the gnokii command line tool to Java. Or perhaps the proposed gnokii device manager daemon would be accessible from a pure Java application over DCE/D-BUS whatever? It all depends what you want to change...

Phil.




reply via email to

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