Fighting with computers

Computers are not always friendly.

Friday, April 24, 2009

Buildroot: What for?


Programming when your target system is not based on x86 architecture and you use a PC for development can be done using a cross-compiler. There is a GNU cross-compiler for many different platforms.

What if you'd like to test the code without using the target system. There are good news too, as you can use qemu emulator to get a system with a non-x86 architecture emulated on your x86 system.

But you might want to get a development system running on your same target hardware. This is interesting if you have a way of accessing the target computer filesystem. It can also be interesting if you want to be able to fine tune the set of versions and libraries to be used by your development system. Here is when buildroot comes in handy.

Buildroot allows you to create a development environment for your embedded system around uClibc (which is a scaled-down version of glibc used for many Linux-based embedded systems). With this tool you select the architecture, kernel, compilers and libraries versions to match the system of your choice (you're planning developing on).

Buildroot output is a filesystem you can mount on the target system and chroot it that contains a full development system. With it you can edit, compile and make your programs on the target system, as far as you're able to mount that filesystem.

However, my experience with Buildroot is a mixed bag as sometimes the process of making an image stopped with an error. Given that each attempt requires more than 20 minutes (of compile time on my system) it is understandable I am not trying to explore all the possible combinations.

Wednesday, April 15, 2009

Remote control your computer


Some people are keen on the idea of using cellphones as a remote control. After all they are usually around, have a small size, a nice display and even some of them have an illuminated keyboard.

Among the choices for interfacing with another equipment, Bluetooth seems to best choice: more standard than infrared and lower power requirements than wifi (besides not many phones have IR or wifi).

Around this concept of using your Bluetooth cellphone as a remote was created AnyRemote project. I've tried lately for a home project and I'm very happy with this suite. Yes, it is actually a more complex system than I expected: You cellphone needs a special program to act as a remote, this program in written in Java and you need to download it to your phone. Then server software is installed in your computer and a set of configuration scripts tell your computer what to do when each key is pressed. On the other hand, user menu is provided on cellphone display (there is even a midnight commander file manager). Brilliant!!

Sunday, April 12, 2009

Ambient Light Sensor problem

Hardly more than 90 days old, our MacBook 2.4 was already featured here as it has already caused me some trouble. Not a good thing I have to talk about it again: Yesterday it stated to make fan noise when idle, and the display backlight was changing for no apparent reason. After several unsuccessful attempts, I've found this article about resetting SMC as somewhere else I was suggested it might help.

Unfortunately though the SMC reset did help with the fan noise it left my system with no ambient light sensor. Whether it was related or not I do not know, but now I cannot use F5/F6 to change the keyboard backlit which remains off. I get a forbidden sign as if the ambient light was very high so as not to require any keyboard backlit. Unfortunately this seems not to be the case in my dark room and it still refuses to allow me to switch the backlit on.

The next exercise on the list was to perform a PRAM reset, that did not fix anything either. And, according to Apple support, the next step is to go to the technical service.

At least I've found a nice application that allows me to select the desired level of keyboard backlit: Lab Tick.

I'm still uncertain on this issue as it might be a firmware problem or a hardware problem. At any rate I'm stopping to recommend Apple as a trouble-free brand (two issues in three months with a system is not good).

Update: MacBook was serviced by Apple and the whole display replaced (apparently the change the whole screen to fix this problem).