Monthly archives: July, 2007

A week configuring Ubuntu with 2 screens on an Acer Travelmate laptop

[Disclaimer: This is not a normal post in my usual style. It’s just a technical reference text. I’ve spent the whole week trying to figure out how configure my laptop and an external screen. Eventually, I got it running! So I’d like to share my config here and in some ubuntu forums]

I installed Ubuntu Feisty in my Acer Travelmate 3000 (actually 3004). The first problem I faced was the panoramic resolution of the laptop screen, 1280×800. Ubuntu tried to display 1280×1024 and the aspect ratio was squeezed. Then I looked at internet and found a recipe with 915resolution (something like “915resolution 49 1280 800 24″). Later I tried to tweak the X server configuration file, xorg.conf, to get 2 screens running (the laptop one, and an external flat panel with 1280×1024). I read on Internet several posts about people trying to configure similar hardware, and all the problems they got: nothing running at all, some screen clipping, etc. Actually I had the same problems… but finally I realized where the problem was, and I got it working! Some details as follows:

Restarting gnome and checking log
First at all, you should go to tty1 with Control+Alt+F1 and do all the editing with the root user (in this case, the best option is using “sudo -s”). To restart the gnome, the command is “/etc/init.d/gdm restart”. I ran this several times, with different configurations, and then read carefully the log file (“/var/log/Xorg.0.log”) to try to understand the errors.

This program hacks the Bios, showing different resolutions to the X server. The most common recipe seen on Internet is to overwrite mode 49 with 1280×800 and 24 bits (normally editing the /etc/default/915resolution). But this just desconfigure some modes that (in my case) are needed for the second screen!! Don’t blindy follow Internet recipes!! So, you have to choose carefully which is the best option. Look at the original options (with “915resolution -l”), and try to overwrite an unused mode, and look at the results again with “915resolution -l”. Be sure you get all the resolutions that you need. Moreover, verify in the Xorg.0.log that the needed resolutions are operative.
In my case, I’ve chosen mode 45, 1280×800 and 32 bits. This leaves the other resolution that I need (1280×1024) unchanged. So, my /etc/default/915resolution is:

If you get the previous step working, you just need minor tweak on the X server configuration file. Just add another Device (with Screen 1), another Monitor, and another Screen. Attention: X server considers pipe A (or Screen 0) as the external one, and pipe B (Screen 1) as the built-in screen. That confused me firstly. Another thing you should add is the horizontal and vertical refresh rate for both monitors… it didn’t work if I left it empty. So finally, the interesting part of this file is:

I hope this helps people to enjoy 2 screens!!

Helping your online reading

Recently I was asked about different issues regarding NLP, due to my PhD studies in that field, and I’ve started reading again about this…

Natural Language Processing is a part of the Artificial Intelligence which studies how a computer could understand natural human languages, like English. There are a lot of subjects in NLP, but in my personal case I used syntactic analyzers to detect the parts of the phrases and the relations between them. For example, to discover if a noun is modified with the surrounding words (“the blue car in the parking lot“). This information were used in a Information Retrieval system (which is something like Google or Yahoo search), to help the system to “understand” what the user is asking for. It was an interesting application of syntactic analyzers.

Visual FormattingAnother amazing use for syntactic analyzers is Visual Text Formatting.

I found an interesting article about “Visual-Syntactic Text Formatting” and a commercial website with some examples. Basically the idea is to use the syntactic information (obtained from NLP tools) to format the text in a way that is easier to read. The result seems quite effective. Surprising idea!