Saturday, December 19, 2009

Tooling around

I'm still working on getting the project in a format that Eclipse will read, and it's tedious enough that I'm starting to wonder if I ought to just forgo this exercise and live life outside the IDE.  Eclipse is a great tool for Java, but its scala plugin is nowhere near as useful in terms of features, and worse still it's constantly crashing.  I've managed to get decent syntax highlighting to work in a number of lightweight Windows editors, and sbt basically works in terms of compiling and deploying an .apk file; furthermore I enjoy it's Maven style directory layout.

The one thing I'm worried about missing by ditching Eclipse is the Android SDK tools (that is, the ADT).  Some of the visual tools for editing layout and so on look like they're pretty slick, and I'm certain they'll only get better with time.  I suppose for now I'll keep plugging away - hopefully by the end I will at least have a useful project setup that other people can use.

Thursday, December 17, 2009

axr update

Just as a quick update on axr, Jan Berkel has merged in my changes to make android-plugin workable on Windows, so downloading the forked version from from my github repository is not necessary. (Now that I'm thinking about it, though, I don't know whether he's published the changes to whatever Ivy main repository sbt looks at, so it still may be necessary to build from source based on his repository.)

Meanwhile I'm trying to get axr into a state where its directory layout is more like the one the Android tools use.

Tuesday, December 15, 2009

axr ho

In lieu of posting edifying thoughts about Android here, I've elected to develop a simple app and use this blog to talk about that process. (I reserve the right to pontificate in the future, however.)

I am calling the app "axr," short for "Android XBMC Remote control."  I'm hoping this project will ultimately result in a simple app which is able to act as a remote control for XBMC by hitting its web services (or however the heck you do that, I'm hoping I can start with very straightforward HTTP calls hooked up to simple buttons).

The purpose of this project is really not so much to develop an awesome remote so much as it is to learn how to code a Scala application for Android. I'm hoping to use simple-build-tool for building it, because sbt looks awesome and there's already a good Android plugin which builds apk files from it.

I am a big fan of XBMC, though, and I'll use the app myself, if only because the notion of all the complex layers of software and network transport that need to be traversed in order for a single command to reach the moving image on my TV from an android app rather tickles me, especially compared to the situation with an old TV and an IR remote.

The source for axr is available, of course, on bitbucket.  It currently consists of little besides a skeleton hello, world project which can be built and installed by sbt.  Note that in order to build this on Windows, you'll presently* need to download my forked copy of the sbt Android plugin (on github, sorry) and then run sbt publish-local in its top-level folder so you wind up with the changes in your local sbt's Ivy repository. (In fact, I haven't built it on anything else, so that might be the only way it works.)

Once that's done, and you've set up an emulator as described towards the bottom of this Google page, you should be able to install and run it by running sbt install-emulator (while there's an emulator running, obviously).

* UPDATE: these changes have been merged in jberkel's repository, so there's no need to use my fork.