Yenya's World

Mon, 22 Sep 2008

Numpty Physics

Probably the craziest toy/game I have seen in several years is Numpty Physics. They have PC and Maemo version (with stylus, the playing experience is much better). I have seen something similar as a demo at the conference in Barcelona in June, but this one is absolutely gorgeous :-)

Section: /computers (RSS feed) | Permanent link | 0 writebacks

Tue, 16 Sep 2008

Kernel Summit, Day 1

The first day of the Kernel Summit was pretty interesting, altough against my expectations it was much more development process orineted than technically oriented.

Probably the most interesting was Linus' remark to the discusssion about storage, especially SSD: he said something like "Forget the erase block sizes and whatnot, and treat the SSD just as a really fast HDD. It is not optimal for the current hardware, but it will be for the upcoming one".

I wonder what has changed in the last year or so, because from previous discussions on this topic it seemed that HW manufacturers were even willing to remove even the wear-levelling controllers from SSDs, provided that the OS could handle wear levelling on its own (which Linux does, via the MTD stack). But I guess there are still plenty of use cases which for compatibility reasons essentially require the FAT filesystem (cameras, etc.), and that in turn require at least the wear levelling in HW. So probably the development will go exactly the opposite direction than was anticipated a year ago.

Another interesting presentation was Rafal Wysocki's statistics on regression discovery and fix times, from which he even predicted the optimal release time of the next stable version.

Spent the evening with Evgeniy Polyakov and Herbert Xu discussing things from Russian politics in Georgia through motor boats to the X11 architecture shortcomings. Ah, BTW: Linus' car has an interesting registration number :-)

Section: /computers (RSS feed) | Permanent link | 3 writebacks

Sun, 14 Sep 2008

Intel HDA: Headphones versus Speakers

I have solved an interesting driver problem yesterday: I have a new laptop (more on it later) with an Intel HDA sound device. The problem was that it did not detect when the headphone jack was plugged in, and did not switch the built-in speakers off in that case. After reading many web forums, I have finally managed to get it working. I will try to summarize the steps required, in case somebody in the future will have a similar problem on a different hardware:

  1. It is necessary to find out which codec chip do you have. It is written in the first line of the /proc/asound/card0/codec#0 file, and also displayed in the line labeled Chip: in alsamixer -D hw:0.
  2. Find out valid "model" options for this chip. Look at the file /usr/src/linux*/Documentation/sound/alsa/ALSA-Configuration.txt, find the section "Module snd-hda-intel", and in this section find a subsection for your codec chip. Mine was "Realtek ALC660-VD", described in subsection "ALC861VD/660VD".
  3. Now run the command "rmmod snd-hda-intel; modprobe snd-hda-intel model=XXXX" for each model valid for your chip. Try to plug the headphones in, play some sound (like "aplay -D hw:0 /usr/share/sounds/generic.wav), and determine whether the built-in speaker were switched off or not. Warning, the trickiest part ahead: it is necessary to re-plug the headphone jack after each "modprobe" command. It detects only the event of plugging a jack, not the state of it being plugged in. It took me an hour to discover this, when none of the available models seemed to work.
  4. Finally, to use the "model=" option you have just selected (mine was "model=lenovo", how strange it may look for the ASUS laptop ;-), use the following command: echo 'options snd-hda-intel model=XXXX' > /etc/modprobe.d/snd-hda-intel (of course substituting XXXX by the correct model name).

Hope this mini-HOWTO will help somebody.

Section: /computers (RSS feed) | Permanent link | 4 writebacks

About:

Yenya's World: Linux and beyond - Yenya's blog.

Links:

RSS feed

Jan "Yenya" Kasprzak

The main page of this blog

Categories:

Archive:

Blog roll:

alphabetically :-)