Stuff that I have been up to

December turned out to be a pretty busy month for me – here are some of the stuff I have been involved in/working on:

  • FOSS.in: As always FOSS.in ‘09 turned out to be an amazing affair. Being someone who works remotely, this event is probably one of the best opportunities for me to have “real” interactions. It’s a place where I can simply sit down, have long face to face conversations, come up with new ideas, be inspired, and most importantly, have fun. My heartfelt thanks goes out to the people behind the event for making this possible. I have some photos in this Flickr photoset.
  • Book reader: This month’s priority has been stabilizing the Sugarlabs/OLPC book-reader code, and a large number of important bugfixes landed during the last few weeks. More in this status report.
  • Arduino: At FOSS.IN, thanks to the efforts of the ever enthusiastic Kushal Das, I managed to get hold of an Arduino clone board (it is terribly difficult to get hold of one in Kolkata). I had heard of Arduino before and wanted to get one, and the session on it at FOSS.in by Russell Nelson finally served as the “kick” which made Kushal and me call up the local distributor and get a couple of boards for ourselves. I have been playing around with sensors support in Sugar for sometime (I helped make the Measure activity work on XO 1.5 hardware), and realized that this would be yet another interesting way to connect Sugar with the “real” world. So after a couple of weekends worth of work, I got Arduino support in Turtle Art.


    Turtle Art with Arduino

  • XO keyboards: There may be a new AZERTY keyboard for the XO laptops very soon. See this wikipage for details.
  • Pootle: The Pootle developers have released version 2.0, which is a vastly improved edition compared to the previous releases. I have been testing it out with plans to upgrade the Sugarlabs/OLPC translation server soon. While testing, I added a quick (and ugly) hack to implement msgfmt –check style syntax checking in Pootle. This would definitely make the process of integrating the translations with the upstream code much less painful – and here’s a screenshot (click on it for a larger version):


    Gettext syntax check in Pootle

Updates..

This blog has not seen much activity in a while, so here goes:

  • Bought a HCL touch-screen based netbook. It’s somewhat ancient hardware, but most of the stuff works out of the box (except for the webcam, which does not even show up in lshal or lsusb). The touchscreen required a binary driver – but a Free/Open Source version seems to exist, though I could not get to calibrate the screen with the FOSS driver variant
    [Update: The webcam works - I had to press Fn-F5 to enable it. It is turned off by default to conserve battery.]
  • Taught myself (this was long overdue – but at least now I can admit that I did not know what I used not to know) how to properly write Python extensions in C. I started out with bindings for Hunspell (I’m reading up a bit on morphology nowadays, and finding it to be tremendously entertaining). There was a Python extension for Hunspell already, but it did not compile for me, and that pushed me to decide to figure out how to do this myself. One thing led to another, and so, as of now, there is (in progress) extensions for handling:
    • Hunspell. Usage instructions here
    • libgettext-po. This should be faster than the existing pure Python based PO file parsers out there. (maybe at some point, I could make Pootle/Translate Toolkit use this, and make the work of OLPC/Sugarlabs translation team members somewhat less frustrating.
    • XKB. I must admit that I took a shortcut for this, and this extension is actually based on the awesome libxklavier. The final plan is to develop a Sugar extension for managing the keyboard options and layouts using this extension. The code in the main git repository, though fairly complete in terms of what is required for Sugar at the moment, is not implemented via (py)gobject. Implementing the pygobject-based wrapper is turning out to be a bit more complicated than I initially thought, but some code for that is also available in this repository (it is somewhat easier now, since I know (at least most of of) what is happening under the hood).
  • Released a newer version of the FBReader activity, which is much more improved in terms of usability (eg: response to the game keys keys while the XO-1 is in tablet mode is much more smoother, and all the keys do something useful). People seem to be happy with the new release.
  • Coming back to the present, right now, among other things, I’m working on a few interesting (and important) enhancements for the book-reader(s). Some of them include support for long keypresses (eg: pressing the “square” game key for two seconds will show the table of contents), notification of critical power events (I realized to my horror during dogfooding, that in tablet mode, while the book reader is open in full screen, there is no way to tell how much battery-charge is left), etc. The bookmark support feature that I came up with a few months back needs a bit of polish, but I think I can make this show up in the next release of Read.

Weekend hacks

Over the past few weekends, I have been working on a few (semi)hobby projects.

  • Conversion of XKB data to M17N tables
    I discovered pyparsing while working on this. The tool I wrote is supposed to extract the data out of XKB symbol files, and convert them into a format which can be easily modified into M17N db files. In fact, for some keyboard layouts, the output was directly usable in m17n (via SCIM), without any kind of direct modification at all.
    The only problem with the script is that the parsing of the XKB symbol files take a significant amount of time, but in the end, it does provide something useful. [Gitweb]
  • An image viewer activity for Sugar
    Sugar did not have a nice Image Viewer activity which I liked, so over the weekend, I hacked together a small activity which would perform the basic stuff expected of an image viewer (zoom, rotation, etc). [Gitweb]