Tag Archives: android

Doris: Lobster mapping

A new project, coming from Borrowed Scenery’s Zizim project, converted into a scientific research tool in collaboration with the College of Life and Environmental Sciences at Exeter University and Helsinki University. Doris is named after the sea nymph from Greek mythology, and will be used for mapping Lobster catches on fishing boats so researchers working at the National Lobster Hatchery in Padstow can easily build up a picture of how the animal’s condition relates to location, sea conditions and tide.

Here is an initial plan for how the thing will work:

The main complexities include locating open data sources for sea states and tides and creating an interface that works easily enough on a small fishing boat under various weather conditions – for example touch screens aren’t much use if you’re wearing gloves. Approaches to try include using the physical buttons, shaking, or voice input. As with previous FoAM projects Boskoi and Zizim, this will be built on the Ushahidi platform. Source repo location to follow…

Touchscreen programming

As more and more people use touchscreens, it still irks me that we lack good ways of programming “on” devices reliant on them (i.e. native feeling – rather than modified text editors). As a result they seem designed entirely around consumption of software (see also the “The coming war on general-purpose computing”).

So lets make them programmable. Recent steps in this direction are based on Jellyfish – an idea to create a kind of locative livecoding virus game (more on that as it unfolds), starting with fluxus on android (now called nomadic) and a good dose of Betablocker DS, mixed with some procedural 3D rendering inspired by the Playstation2’s mad hardware, and icons previously seen on the Supercollider 2012 flier!

This is a screenshot of it’s current early state, with the Linux/Android versions side by side (spot the inconsistency in wireframe colour due to differences in colour material in OpenGL ES). Main additions to the previous android fluxus are texturing and text rendering primitive support. I’m glad to say that pinch-to-zoom and panning are already working on the code interface, but it’s not making too much sense yet to look at.

Shaving yaks on android

fluxus installed on the emulator

Mostly my android experience has been good so far, it’s been very quick to get things running and be fairly productive. It doesn’t come without it’s share of yak shaving though. I’ve spent quite a lot of time trying to get remote debugging of native code working with my phone (a HTC desire) with little success. This seems to be a fairly well documented problem, the symptoms are messages like this when running ndk-gdb:

ERROR: Could not setup network redirection to gdbserver?
Maybe using –port=
to use a different TCP port might help?

When run with –verbose it seems something a little different is wrong:

run-as: Package ‘am.fo.nebogeo.fluxus’ has corrupt installation

Which looks like some result of having a rooted phone (which I do) as ndk-debug is a possible attack vector for doing nasty things and is therefore very critical of the permissions of the directories on the system. In order to fix this I installed ROM Manager from the market which contains a script to fix permissions. This didn’t work at first by pressing the button in the app so after some poking around I found the shell script in: /data/data/com.koushikdutta.rommanager/files/fix_permissions

It turned out that this script depended on an interesting utility called busybox, which provides tiny versions of GNU programs for phones. The easiest way to install this was to install TitaniumBackup and click on it’s “Problems” button which would download it, then copy it from /data/data/com.keramidas.TitaniumBackup/files into /system/bin/ and run busybox –install -s /system/bin/

Then the script could run, and additionally I needed to run chmod 774 /data/data/* to get make sure everything was in the correct state, but still no luck with gdb. At this point I decided my time would be better spent on making a linux version of the android app for debugging purposes and get it running in the software emulator. More on this soon.

I’m also documenting bits and pieces of my android development notes on FoAM’s wiki here.