By the way ... a somehow unrelated topic, but you could be interested.
Since it is very difficult to program for the Hanlin device (or the other ebook devices), I started with a port of the LUA (
http://www.lua.org/) virtual machine to the Hanlin device (but also the PocketBook, windows, mac osx and linux).
It's not Java, but a language that (in my view) has proven it's place. Anyway, I don't want to launch yet another language war ...
I did make a 'fat' binary that includes :
- the lua vm
- a binding to GD (
http://www.libgd.org/) using Lua-GD (
http://lua-gd.luaforge.net/) including the freetype font support and PNG support. The screen is represented as a GD image. This way all of the functions supported by Lua-GD can be used to draw onto the screen. (But the 'normal' functions are still supported, so e.g. one can read and write PNG images)
- a binding to key events, mouse events (not very usefull on the Hanlin), timer events, ...
- a binding to sockets using LuaSocket (
http://www.tecgraf.puc-rio.br/~diego...nal/luasocket/) to be able to use networking. Also not very usefull for the Hanlin (but very nice to use on the PocketBook) besides some supporting function in the mime part of LuaSocket (
http://www.tecgraf.puc-rio.br/~diego...cket/mime.html)
Just to make a difference between the normal Lua VM and this 'fat binary', I do call this one "eblua". By now I managed to create a first version of "eblua" for the 5 platforms mentioned above. Lua scripts written against "eblua" run identical on the 5 platforms. That should make it a bit easier to write simple applications that also run on ebook devices.
It's still very early stage. I still need to do a lot of clean-up stuff and unify some things for the multiple platforms (e.g. screen sizes, key-codes, available fonts, ...). But maybe a brave developer (like you) is willing to give it a try.
Just as a try-out I did write a version of 'tetris'. It's not the best application to run on devices with eInk screens, but I needed some application as a test vehicle.
Enclosed is a zip-file that includes three files. 'eblua.exe.fb2' is the fat binary. 'eblua.lua' is an initialization script that is run every time the VM is started. 'app.lua' is the actual application (in this case the tetris application). It's a text-file, so it's freely changeable. This is how 'new' applications can be written.
I'm still contemplating about the actual packaging of applications. For the moment the paths to the multiple files ar hard-coded ("/mnt/eblua/" which is an eblua directory on the SD card). Also the application to run is hard-coded: 'app.lua'. This will most probably change in the future. Hence, to run the application all three files should reside in an 'eblua' directory on the SD card. The application is launched by opening the 'eblua.exe.fb2'.
Feel free to try it out, or to completely neglect it :-)
Good Luck with the Java app,
Wilfried