Saturday, 14 November 2009

HTC Hero with Android

During summer 2009 I had the chance to compare Apple's iPhone side by side to the then new HTC Hero runing Android. After reading so many positive articles I was curious.

Disappointing at first

The HTC Hero comes with a refurbished Android theme. Compared to the rather clumsy looking original, HTC's Sense theme is looks decent. But this is where my first impression left the enthusiastic path. Compared to the iPhone the HTC was no hero at all. It was slow, text entry was cumbersome and full of recognition errors. So I did not buy it then.

Coverage in the media suggested, this was just a problem with preliminary models.

10.000 apps available .. where?

I read this article comparing AppStore to the Android Market. Apple was supposed to offer well around 100.000 apps. Google claims to have more than 10.000's of apps in it's Market Place.

Let's face it: Neither has Apple any more than say 300+ apps that are worth mentioning nore has Google anything more than around 100. You get easily overwhelmed by round robin lists, betas, free evaluation copies and some me2 development templates. But this is nothing I would call a usefull app (please refrain from flaming me on this, I would hate to censor your comments. I do look forward to discussion though).

Second looks

So, why do I comment on Android, HTC and mobile Phones here?

I do see a huge potential in mobile communication. The iPhone currently is the linea ultima in mobile communication and personal assistance. Windows mobile never was a direct competitor but Google's Android has the potential to be a serious contender.

While Apple uses a strict policy of control, Google offers a more open approach. Developers are encouraged to develope for Android, there are several SDK's, plugins for IDE's (ok, I have my personal opinion about Eclipse) and offers lots of documentation and sample code.

All this makes it an opportunity for innovative solutions and development.

Where we are

While it is easy to geting started, most of this sample code enters Market Place by just being renamed (there are approximately 8 notepad apps derived from Googles Notepad app and only Googles version syncs with GDocs). This is unfortunate and tends to scare people away.

To prevent poor apps to be swamping the market place, Google offers a rating system from 0 to 5 stars. It might sound like a good idea, only the fittest apps will survive. Unfortunately the rating is slightly missleading. Personally I could not relate attributed stars to the quality of the program. I found some apps that were rated 5 stars and the comments suggested that the app crashes (which it did on my phone as well).

True Lies

Here are some myths about the HTC Hero:
  • The HTC Hero has a specially coated touch screen, that makes it look less smeared as other touch screens:
    The HTC Hero will have a special coating after 5 minutes of use. Before that, I can see nothing special about it.
  • The HTC Hero has a scrath proof screen:
    Mine hasn't. Mine had some scratches after 2 days of use (my Motorola RAZR v3 does not have any scratches after 3 years of use)
  • The HTC Hero comes with its own Interface, HTC Sense. It is vastly improved performance-wise:
    HTC Sense is a theme. It improves the looks of the shabby Android Interface a lot. Other than that, it does nothing.
  • The HTC Hero's battery can last more than a week:
    I presume it will if you don't operate it. I have to reload it every other day
Here are some nice features (and immediately remedied):
  • The interface lets you operate the phone with intuitive on screen operations:
    However, not all apps support widget presses to open option menus. Sometimes you have to use the menu key. This might be anoying, because some usefull apps only have keyed menus.
  • Sense has a beatiful, iPhone like date and time selector:
    Well, Sense does, Android does not. I do not know, why some apps have the nice scroll selector, others you have to type + and - signs.
  • I like the Market Place. One can easily purchase apps:
    This was quite a surprise and is a definite positive: I purchased Scan2PDF which I had a free version that embeds watermarks in the PDF. Purchase was straightforward. Entered my credit card, accepted the fee and download started.
    (OK I even found something here: the free version was not removed from the phone, I had to do that manually. There is no security to prevent you from deleting what you just purchased. I also don't know, how to redownload the app in case I reset my phone).
  • The phone comes with headset, a nice box and small power supply.
  • The phone can be charged with a universal USB cable (with micro USB connector at the phone end).
  • The headset jack is a standard jack. One can use any headset they want.
  • ROM 1.6 is significantly faster and more accurate than 1.5. I look forward to 2.0:
    (the original ROM from Google cannot be installed, one is required to get a ROM from HTC).
Do I regret?

Giving the potential that lies within Android, I do not regret having purchased the Hero (speech quality is clear, reception good, quality of mp3 acceptable). Some functionality is still not as one would expect. The phone app cannot be adjusted to personal preferences (which I would actually expect on a mobile phone). Mail services are not integrated (there are seperate apps for GMail, IMAP and SMS).

I still think that the tight integration in Googles online services is something to be aware of (I found my contacts in my Google calendar which I never used before). I still have not decided whether to use Google Docs, calendar and other services more intensly. It would make the phone more versatile.

My recommendation: Have a look, take a test drive and don't believe what most people say about Android (or the Hero). It's pretty beta out there.

Tuesday, 27 October 2009

Ubuntu 9.10 client installation

This refers to Ubuntu 9.10 rc1.

I installed 9.10rc1 on a HP510 (2GHz, 1GB, 1280x800 i945), HPnx8220 (2GHz, 1GB, 1650x1080 ati), HP 8510w (2,4GHz, 2GB, 1920x1200 nvidia).

Installation of the core system went fine. Compiz works on all machines, the Intel chipset being the easiest, NVidia requires proprietary drivers.

Switched from Thunderbird to Evolution.

I don't know why this program gets all the hype. Its buggy (and I mean, it is hardly usable). It's a pain to configure offline synchronization (you have to set this in the Edit -> Preferences -> Mail Account -> Edit -> Receiving Options -> Automatically synchronize remote mail locally and the manually right-click the folder -> Property -> Copy folder content locally for offline operation). It's a pain to configure spam protection (in the above mentioned Account Editor you have to set Check new messages for junk content). It does not read news, it is slow and auto filtering does not work all the time.

Why did I swap: Its default, it has Exchange connectivity (not that I need it) and it syncs my Palm pilot and hopefully my Andriod phone.

Network manager still does not work correctly.

Using a mobile broadband internet connection does not work with wireless access points in reach. If wireless is turned off, the connection works fine the first time, consecutive connections do not adjust the resolver settings.

Used a manual override to fix this.

Another issue is purely annoying: Setting the mobile connection to be available system wide will lock you out of editing the settings. One can delete the connection and set it up afresh. As soon as you set system wide availability, the game starts new. Sometimes I would not even get an error message, the network manager applet would simply terminate.

Canon FB363u still does not work.

It's a shame that this used to work in 6.06 but never after. Several attempts to issue bugs failed. Canonical does not react but still provides drivers for the scanner in it's repositories.

Power management?

In 9.04 the battery on my 8510w lasted nearly 4 hours (3.57). This was ok. I remeber having heard the fan twice.

With 9.10 the battery lasts 2h20mins. Worse, ever since the upgrade the fan spins permanently and really loudly. acpi -t tells me that some device has a temperature of over 75° C. It was never that hot before.

Sound issues.

I installed additional gstreamer libraries (bad and ugly). After that I installed VLC. This seemed to render sound output dead on all my machines. Reinstalling gstreamer bad and ugly libraries solved the problem (don't know why)

VMWare ... the usual ...

I didn't expect VMWare to work out of the box. And VMware did not disappoint me.

Cut a long story short, here is the fix. There is another hint out. I did not find the problems described about mouse grabing problems on any of my machines. As I like simple solutions I followed the one on the vmware community site. It works fine.

CUPSpdf.

I used CUPSpdf a lot to print PDFs out any size. In 9.10 CUPSpdf offers adjustment of the paper size. To the application only A4 or Letter is available. I don't know what the use of bigger paper size is if one can't use it.

So where are the good news?

ext4 works fine. It's fast (boot time about 15 secs, used to be 47 secs with 9.04).
Grub2 is fine. It does what it should and stays out of your way.
firefox 3.5 is snappy.
avant window manager is a pretty add-on that makes my life pleasant and easy.

Pretty little if you ask me.

Worth your while?

If neither Windows nor Mac are an option, then the answer would be: yes.

However the pain and frustration (I still can't connect to my campus network via VPN) accumulates.

Thursday, 16 July 2009

MSI X320 graphics driver update

After upgrading to kernel 2.6.28-14 the graphics driver could not be found. I got an error message that the system does not find the corresponding module and can run only in low res mode. Reinstall or uninstall and install of the poulsbo drivers does not fix the problem.

To fix this, simply install psb-kernel-sources and reboot.
sudo apt-get install psb-kernel-source
sudo shutdown -r now
Reason for this is that the kernel modules are hard coded in a directory:
/lib/modules/2.6.28-13-generic/updates/char/drm (drm.ko and psb.ko).

Installing the psb kernel sources creates a directory:
/lib/modules/`uname -r`/kernel/updates/char/dkms and in there the files drm.ko and psb.ko.

Why the kernel modules were hard coded in the first place is beyond me. Should work in the future.

Monday, 6 July 2009

MSI X320 Wireless installation (obsolete)

This post is obsolete and has been integrated into MSI X320 Installation (revisited).

Wednesday, 24 June 2009

MSI X320 installation (revisited)

(this post has been updated on Sept. 3rd, 2009)

Installing Ubuntu from scratch (unless you want to live with Windows Vista Home Edition) on a MSI X320 is non trivial at best. The notebook comes without any CD-ROM but boots from an external USB CD- or DVD drive.

Installation goes straight forward, the system comes up nicely.

Things to keep in mind

Graphics resolution is 1024x768. The display can run at 1366x768. Here is what you have to do to get it:

Setting the right screen resolution

In Synaptic Package Manager under Settings/Repositories/Third-Party Software add:
deb http://ppa.launchpad.net/ubuntu-mobile/ppa/ubuntu jaunty main
copy the following text to a text file:
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: SKS 1.0.10

mI0ESXQtMgEEAMtSSxV/TSMW1mEnFVc7DJ/g/7UOq+TnlSs68uVbhUoh0BRuVScOb81dsyTg
IB3WQzbvE2r0ELa+L/hYGsRH9XOq5u+qVtBJmDtUWjT0okVlBBIpyWkM61sWCQYkbs4UcF9a
U+zfy4W1rIY81etivlqWQ79XmZ5iUHHMvGzvbZONABEBAAG0JExhdW5jaHBhZCBQUEEgZm9y
IFVidW50dSBNb2JpbGUgVGVhbYi2BBMBAgAgBQJJdC0yAhsDBgsJCAcDAgQVAggDBBYCAwEC
HgECF4AACgkQmdayHMZZijA7ZAP8DBWyjyo8O8hNbpvN/T7kEB4HxcNd6R6HaGQen3jSBrxe
vviVA1h2Md81C6gnvr/XT/kUYLyEK1oIY+jw8nHl7Z6Vf8kDfDACiN4KJXQY8wMOotQhHCZd
UM93u4yTZy+hWHcHU0/7a5EOU2bT7x3CztYJN7PURR89Sto3aXy3aW0=
=0g8f
-----END PGP PUBLIC KEY BLOCK-----
Save it under the name "msi.key" and import in the tab Authentication/Import Key File... (alternatively you can download the key from here).

Reload the repository. You should now find a package:
poulsbo-driver-2d and
poulsbo-driver-3d as well as
psb-kernel-source (will be needed by the wireless network driver as well).
Install it and its depending packages. Further install
compiz-settings-manager
awn-manager
and all depending packages if you want to mimic Apple.

Now edit the file /usr/bin/compiz. Its a wrapper script to launch compiz. Find the line that starts with:
WHITELIST="..."
Add a space and "psb" at the end so that screen composition works with the Poulsbo chipset.

I also installed AUT2 (the Austrian Ubuntu Theme) which has resembles a silvery blueish style. For that, copy AUT2 into /usr/share/themes and UE-icon-set-light into /usr/share/icons.

After rebooting the machine, you will be greeted with an optimized resolution of 1366x768. Choose the AUT2 theme from the Preferences/Appearance control panel.

Wireless LAN

You might find your machine not offering bluetooth and WLAN. Bluetooth can be turned on with the Fn-F9 key combination. WLAN ist toggled with the Fn-F8 key (not very intuitive icon).

Ubuntu does not provide a wireless driver for the RaLink RT3090 pci card built into the MSI X320. In order to get wireless working you need to download the source file. Either go to RaLink directly:
http://www.ralinktech.com/ralink/Home/Support/Linux.html
and download the file "2009_0612_RT3090_Linux_STA_V2.1.0.0_DPO.tar.gz" or download sources for SuSE 11 (which have some handy patches enclosed):
http://download.opensuse.org/repositories/home:/Akoellh/openSUSE_11.0_Update/src/rt3090sta-2.1.0.0-1.2.src.rpm
The driver derives from the RT2860. If you want to adjust the interface name to wlan-x and the driver name to rt3090sta, you need to patch some source files. SuSE delivers 5 patches, 4 of them apply, on is for 64bit versions only (which do not make sense and I could not get the driver to work with this patch).

Install the patch utility and optionally the rpm utility:
sudo apt-get install patch rpm
Sleves up

Extract the sources. If you extract from the RPM you have to extract the tar.gz contained in the directory within rt3090sta-2.1.0.0-1.2.src as well (I renamed the directory to RT3090 for convenience).

In the RPM sources you find 5 patch files, some decriptive text and the original source directory (is the same as the one from RaLink).

Source code preparation

You can either apply the patches or apply changes manually. To apply patches cd into the directory containing the Makefile (2009_0612_RT3090_Linux_STA_V2.1.0.0_DPO). All patches create a backup of the files patched (they have an extension .orig).
patch -b -p0 ---input=../rt3090sta-2.1.0.0-config.patch
This patches the Makefile and the os/linux/config.mk file. In my case I had to revert the changes in the Makefile (I simply copied the Makefile.orig over the Makefile).

You can apply these changes manually by editing ./os/linux/config.mk. Set:
HAS_WPA_SUPPLICANT=y
...
HAS_NATIVE_WPA_SUPPLICANT_SUPPORT=y
This allows the driver to be controlled from the Network Manager applet.

Next apply the WPA-mixed patch. This changes the encryption cypher to TKIP-AES.
patch -b -p0 ---input=../rt3090sta-2.1.0.0-WPA-mixed.patch
You can change the line in ./common/cmm_wpa.c from MIX_CYPHER_NOTUSE to:
WPA_MIX_PAIR_CYPHER FlexibleCipher = WPA_TKIPAES_WPA2_TKIPAES
manually.

If you use the patch utility, you can change the driver name to rt3090. This is cosmetic:
patch -b -p0 ---input=../rt3090sta-2.1.0.0-remove-potential-conflicts-with-rt2860sta.patch
This replaces all appearances of "rt2860" to "rt3090" in the file ./os/linux/pci_main_dev.c and can be done manually using gedit or vi.

We are nearly there. Another cosmetic change is applied by:
patch -b -p0 ---input=../rt3090sta-2.1.0.0-convert-devicename-to-wlanX.patch
This changes the default ra device to wlan device. You can manually replace the "ra" with "wlan" in the define statements of the file ./include/rtmp_def.h.

If you are not there, go back to the directory containing the first Makefile.

Compile

Simply call
make
This will start the compile process. Don't worry about the error messages. I tried to fix them but the results were no better.

After a while the make process will terminate with an error message (it cannot copy files to the /tftpboot directory). Don't worry, we don't need it.

Install

You can call
make install
or manually copy the driver and bind it to the OS:
cp ./os/linux/rt3090sta.ko /lib/modules/`uname -r`/kernel/drivers/net/wireless/.
depmod -a
There is also an install utility that you can use for this purpose.

Configure

You have to copy the file RT2860STA.dat to /etc/Wireless/RT2860STA. Create the directory Wireless and RT2860STA if it does not exist (if you used make install, this is done for you).

If the file is not found there, the wlan interface will not get registered and you will find an error entry in /var/log/syslog:
... RtmpOSFileOpen(): Error 2 opening /etc/Wireless/RT2860STA/RT2860STA.dat
(I found some posts on the internet that suggested fixing paramters in some configuration files. I think the euphoric success messages are due to frustration and not due to solution. Only having a system readable version of the file in the right place makes the driver work).

Edit the file /etc/Wireless/RT2860STA/RT2860STA.dat. Change the settings for:
CountryRegion
CountryRegionABand
CountryCode
WirelessMode
AuthMode=WPA2PSK
EncryptType
WPAPSK
or Keysettings. You can find the correct parameters to use in the template file README_STA_pci. Ignore advice of the rest of the file, it does not work in Ubuntu.

Start the driver

Before you continue, check the Network Manager applet. It should not offer you any wireless networks nor should you be able to Enable wireless either.
sudo modprobe rt3090sta
should work flawlessly. After a while you should be able to connect to the wireless network. Enter the connection information in Network Manager. If you choose auto connect and connection available to all users, connections will be set up automatically.

Reboot the machine. The driver should get loaded automatically after reboot.

Caveats

Some things to keep in mind:
  • The driver is copied into a directory tree of the kernel libs that gets replaced as soon as the kernel gets updated. You have to copy the kernel driver anew to the correct library path. I presume this is an accepable tradeoff until drivers get shipped with the standard image
  • The driver does not connect to SSIDs that are hidden (as was the case with my WLAN). I had to set the router to show my SSID in order to get a connection. This was the reason it took me that long to figure out how to install.
  • The warning messages that you saw during make do mean something. The source leaves some variables uninitialized. This generally is not a sign of good quality code. However, the driver works sufficiently. I hope RaLink people will deal with the warnings.
  • The driver does not correctly deregister for sleep mode.
Disable non-functional SD card driver

The SD card driver does not work on the MSI X320 (as of September 2009). The sdhci kernel mode drivers are notorious for making the machine unresponsive. The device does not release locking bits thus causing permanent timeouts, slowing the machine considerably. To disable kernel mode drivers in Ubuntu
  • goto /etc/modprobe.d/
  • create a file somenameorother.conf (I called it blacklist_sdhci.conf)
  • edit it to:
    blacklist sdhci
    blacklist sdhci_pci
  • restart the machine
You can edit existing blacklists but they might get overwritten in case of OS upgrades.

Other caveats
Neither suspend to RAM nor hibernating works.

I tried Karmic Koala (9.10) but neither the Poulsbo drivers, the SD card nor power savings were fixed.

Conclustion
If you can live with rebooting the machine, the MSI X320 is a slim, leightweight notebook. Here is a screenshot of how my machine looks now:

Monday, 22 June 2009

Webmin 1.480

I run webmin to manage my servers. To upgrade I usually download the latest package from the webmin website and install using dpkg.

Today I saw a notification on the System Information page. Following the link upgrades to 1.480. This is the first time upgrading from within webmin worked on my servers.

If you need web based server administration, I can recommend webmin.

Tuesday, 16 June 2009

Error in Gnome-RDP

Gnome-RDP is a nice client to administer remote computers. It offers RDP protocol as well as VNC and SSH. It has a simple interface that just does it. And it keeps its settings in a SQlite database.

And here the problem starts.

After every major upgrade of Ubuntu, Gnome-RDP does not read the file correctly:
Error in query:
SELECT * FROM version WHERE id=1
Error:file is encrypted or is not a database
This is annoying as connection information and passwords are stored in this database.

Reason for the error is a difference in the SQlite schema. The error message is missleading.

Here is a fix that works on Ubuntu 9.04.
  1. Open a console window
  2. Check if sqlite and sqlite3 are installed (type sqli and tab. If you have installed a fresh copy then sqlite might be missing. Temporarily install it)
    sudo apt-get install sqlite
  3. Make a copy of the gnome config database
    cd
    mv .gnome-rdp.db .gnome-rdp-backup.db
  4. Start Gnome-RDP and quit immediately. This creates an empty config database. Then you dump the old database using sqlite to the new database using the new sqlite3
    gnome-rdp
    sqlite .gnome-rdp-backup.db ".dump session" | fgrep INSERT | sqlite3 .gnome-rdp.db
    Just dump the session table (which will dump CREATE statements as well) and just use the INSERT statements to copy the data into the new file.
  5. Starting Gnome-RDP should now work fine.
  6. Deinstall sqlite (you won't need it)
    sudo apt-get remove sqlite
Hope the developers of gnome-rdp will do a database check in the next release.

Thanks to Mick K for the solution.