Adventures in “A…” September 29, 2006Posted by Florian in GPE, Source, World.
I always wondered why cellphone manufacturers using Linux for their devices do not release the kernel sources like they are expected to do. Yes there are actually quite some of them – just check linuxdevices.com. Now i found a good reason for this strange (and not really legal) behaviour:
The story began with the idea to find a device to start developing cellphone specific applications on. Of course it needs to be one running Linux. I have several smartphones laying around, but it turned out that it seems to be impossible to get the kernel sources for the Linux running ones and Linux support for the non-native Linux ones is not yet ready for cellphone use. After spending hours searching for a device that is acually available including kernel sources i end up in getting a Motorola A780. There is a quite active community around this device and even better: There is a project to create a complete free software stack for this device including an up to date Linux 2.6 already. (see http://www.openezx.org).
Because the port of the new kernel is in a quite early stage i decided to start with the original Motorola 2.4.20 one released at opensource.motorola.com. The idea was just to build a kernel image that uses a partition on the SD card as root filesystem and run this via boot_usb. In this way you can have a development filesystem without installing anything to the internal flash. Sounds easy, eh?
I knew the this kernel was a Montavista hacked one… these are known to be ugly, but it can’t be that bad, i thought…. they are a big and successful company. It didn’t take long to find out that the sources were incomplete. I applied a small patch… created a missing link to a header file, removed some drivers from the configuration and wondered what had happened to all the documentation that can be usually found in a kernel source tree. The resulting kernel image crashed instantly… did you read ‘Snow Crash’? – Then you know how it looked like.
A pile of slightly differen kernel images with the same result and several (successful!) tests by other developers i gave up on boot_usb and flashed the kernel to the device. It started – before that i couldn’t imagine that i would be happy to see the Montavista logo on a screen. ;-) Well the fun was over when i noticed that the kernel just freezed after initializing the RTC. Five compilers and some hacking around i found out the reason for this odd behaviour: I had disabled the camera driver because of some lacking files… after i found these in the older 2.4.17 source tree i enabled the camera again and the kernel booted until mounting of the root filesystem should happen.
Of course this didn’t work… same like NFS root using the USBD driver. The USBD sources didn’t offer a way to switch away from cdc_acm to cdc_ethernet but when i tried to get rid of USBD at all and use the upstream cdc_ethernet driver it turned out that some functions of it were used in a completely different place in the kernel. Yes, some developer must have loved “extern” :-( The module using these functions was used to change the USB mode – i felt lucky and so did the kernel – networking started to work after using the correct command line switch.
Unluckily “init” did not like the kernel and died very fast. After i managed to convince the kernel to wait for the SD card appear i was able to reproduce the same behaviour with the root filesystem on SD. Note that the filesystem is fine – with 2.6 it starts up and even X works fine. I’m not sure how this story continues… oh right, one more nice thing: In both published original kernels ‘menuconfig’ is broken. It starts with an error message and the menu is not updated if Config.in fils are changed. I really love to see things like
Preparing scripts: functions, parsing../MCmenu0: line 133: syntax error near unexpected token `}’
… not speaking about the ugly warnings during build.
Maybe they should have asked someone who knows about Linux?
IpaqZaurus July 19, 2006Posted by Florian in GPE, World.
Sometimes i am really happy what OpenEmbedded can do for us… after adding some iPAQ specific bits to the OpenZaurus 354x branch i was able to build a GPE based OpenZaurus 126.96.36.199 filesystem image for the iPAQ h3900 platform. It is expected to work on all h39xx and h5xxx iPAQ models. I tested it successfully on a h5550. There are some rough edges but for for just moving a distribution to a new platform its quite impressive. Compared to Familiar it feels a little bit faster and its more up to date even if some of the latest GPE bits didn’t make it into the relase.
If someone is interested in trying it – i uploaded a slightly modified image and a (finally) working OZ (softfloat) toolchain to this location:
If more people are interested in this it might be worth to keep the iPAQ support in OZ up to date. Feedbacks really welcome – for chats you can catch me in #gpe and #linuxtogo at freenode.net.
Linux-To-Go July 14, 2006Posted by Florian in GPE, Maemo, Source, World.
add a comment
Linux-To-Go – our new development and community platform is ready to use. It is a community driven and administrated site to provide services for Linux related and other Open Source projects on mobile devices.
The basic idea of Linux-To-Go is to create a transparent and independent platform for Open Source software development and easy information exchange for users, developers and everyone else interested in Open Source on mobile devices.
So far the amount of content is quite low, but we are hosting some interesting projects like OpenEmbedded, Angstroem and Gomunicator. We really appreciate any feedback – comments, suggestions or flames.
Of course you can start to use the LTG services NOW! :-)
Lua Update May 31, 2006Posted by Florian in GPE, Maemo, World.
add a comment
Finally i managed to publish this here too…
I converted the book "Programming in Lua" which is available online to plucker format. The file is available here: http://www.kernelconcepts.de/~fuchs/files/pil.pdb
If you need FBReader to read it you can find packages (for Familiar Linux) including some dependencies in the same directory.)
To find out more about Lua and how the GTK bindings work i started to write a small backup tool. Fo far it isn't functional but it shows that the performance is good even with more than three widgets in a window.
Now back to some waiting important projects…
Is this what people get paid for…? April 9, 2006Posted by Florian in GPE, Maemo, Source, World.
I just read Lorn Potter’s article here and wondered what he gets paid for. I’m not surprised that he didn’t publish my comment to his blog. In fact it is possible to make all GTK based applications on a SL-5000d terribly slow using a kernel with a fixed size ramdisk, but that’s the missing detail in his text. If you have 32MB of physical memory and use a more common setup, GTK based applications are much faster than in this comparison. Suddenly the startup time for gpe-todo decreases from 13 seconds to 1 second.
However… independent from the technical issue i really wonder why things like this are necessary. Are these guys afraid of GTK that much?