[chirp_devel] Summer Project : transcoding CHIRP (into Java)
Robert Terzi
Wed May 21 10:55:53 PDT 2014
[Attempting to move this discussion to chirp_devel]
On 5/20/2014 11:06 AM, Al Szymanski wrote:
> My thoughts are that by putting the entire application in Java, then
> there would be no platform dependencies at all. ( wishful thinking )
I don't mean to discourage you from doing your project but to set expectations
correctly: it's wishing thinking that a Java port would remove platform
dependencies, especially for an application that requires serial port access.
The majority of problems people run into is getting the correct operating
system (Windows, Mac OX) USB driver installed for their USB serial cable.
This is complicated by the whole cheap counterfeit prolific chip debacle.
Even a Java application still needs the OS level device driver support to
be there like any native application. So none of those problems go away.
Worse, serial support in Java introduces additional complexity as additional
platform specific native code, usually in the form of shared libraries
(.dlls, .so's, etc.) that need to be available to the JVM. So if you want
to reduce installation pain, you need to distribute those platform specific
binaries with your Java app. Now when there are problems with the serial
port, you've added a whole additional layer to debug which helps obfuscate
the process.
Note: For the people on Windows, chirp is distributed as a compiled package
with all of the necessary dependencies using a python compiler. The one
remaining platform dependency is getting Windows to recognize the serial cable
and figuring out which port it is, which you'd still have to tackle with Java.
However you will have added the additional requirement of making sure you've
got a Java run time environment correctly installed that is an acceptable
version for your application and the native serial port code.
Doing a port of the python code to java will certainly be a valuable educational
experience for you, and might lead to something that might be usable on
android some day, but I don't believe you are going to solve any of the
problems you are hoping to.
Alternatively, if you really wanted to run on a JVM, you could look at what
changes to the Python codebase (new GUI, serial interface, etc.) would be
necessary to run under Jython/JPython instead of completely reimplementing
everything. However, I don't know that in the end it would be that useful.
Just my opinion, others will hopefully correct me where I'm wrong.
--Rob
More information about the chirp_devel
mailing list