2009-12-27

Update on Sansa Fuze

Just to quickly update on the developments regarding the Sansa Fuze in the last year. Most importantly, the problems with video have been pretty much solved (at least for me) with video4fuze. Secondly, new firmware update has improved id tag handling significantly, among other things. There is even newer firmware available, but it's buggy and offers no real improvements, so I'm skipping it.

2008-12-26

More on Sansa Fuze's video format

Sansa Fuze MP3 player only supports a very specific version of the AVI file format for it's video output. This format is not documented anywhere and can only be, as far as I know, produced with Sansa Media Converter (SMC) Windows program. I have spent some time familiarising myself with the video files produced by SMC. This blog post was written to document some of the aspects I have learnt so far.

I hope at least someone finds some interesting information here and perhaps we can come closer to a working video conversion. This is still very much a Work in Progress. I intend to update this entry if any new information pops up. I'm also happy to answer any questions I can in the comment section. See also my previous entry on this subject.

AVI files

AVI files consist of chunks. For a recent general discussion of AVI files, see this pdf file. If you use Python, AVI chunks can be read, for example, with Python's chunk module. See Python's reference page for a nice explanation of chunks in general.

AVI file is actually a RIFF file. A standard RIFF files have 3 types of chunks. First comes the "RIFF Form Header". Then there are normal chunks and list chunks.

A chunk has a 4 byte identifier, a 4 byte chunk size, followed by the actual data. A list chunk has identifier 'LIST', a 4 byte chunk size, a 4 byte list identifier, followed by data. RIFF Form header has identifier 'RIFF', a 4 byte file size, a 4 byte form identifier (in this case, 'AVI '), followed by the actual data, in this case the other chunks.

File Structure

Fuze's video format is, in essence, a standard AVI, but the requirements for a working file are specific. I analysed a very short example file generated with SMC. In this example file, the file structure was as follows:

  • 'RIFF' form header

  • 'hdrl' LIST chunk, header information

  • 'avih' chunk (56), avi file headers


    • 'strl' LIST chunk, which describes the video stream


      • 'strh' chunk, stream header

      • 'strf' chunk, further stream description

      • 'indx' chunk, odml stream indexing


    • 'strl' LIST chunk, which describes the audio stream


      • 'strh' chunk, stream header

      • 'strf' chunk, further stream description

      • 'indx' chunk, odml stream indexing

      • 'JUNK' chunk, which is just filler

    • 'odml' LIST chunk, OpenDML header list


      • 'dmlh' chunk (248), OpenDML header chunk


    • 'INFO' LIST chunk


      • In this case, this list chunk has just one subchunk called 'ISFT' (software), with the string 'InterVideo\x00\x00'.


    • 'movi' LIST chunk, containing the actual video and audio data as subchunks


      • In our example, this list chunk has just 4 subchunks called, ix00, ix01, 00dc, 01wb. The first two are odml index chunks, the third one is video, the last one is audio.


    • 'idx1' chunk. Legacy index chunk that is actually not required by Sansa Fuze.



Some observations

Here are a few random observations about Sansa Fuze's video files.

  • Wrong ulFlags in the avih header do not affect playback. It seems that the player just ignores this and in fact much of the headers.
  • idx1 chunk is not required. Apparently it is not even read before playback reaches the end.
  • Fuze uses OpenDML (AVI2) indexing. 'odml' chunk is absolutely required. So are 'indx' subchunks under 'strl' chunks, and ix## subchunks under movi chunk. Mencoder unfortunately only creates odml compatible files if file size is greater than 1 GB. I have tried modifying the sources so that odml index is created every time, but these files do not seem to work any better. It is probable that Fuze doesn't like Mencoder's method of starting a new RIFF chunk whenever odml index is used. Perhaps there is another encoder somewhere that can create the odml chunk every time. I understand that Windows program VirtualDubMod creates OpenDML compatible files, but I haven't had the time to find out how well it works.

Further information

A few sources of information about AVI files in general:

2008-12-06

HP Laserjet 1020 and Casio EX-Z80 on Ubuntu 8.10

A few notes on two devices I tried today.

The printer, HP LaserJet 1020, was a bit odd. Once I plugged it in, Ubuntu 8.10 (Intrepid Ibex) seemed to recognize it and installed drivers. But when I sent a test page it was never printed. There were no error messages or anything, though. This thread on Ubuntu Forums helped. The relevant part:
  1. sudo apt-get install hplip-gui
  2. Delete earlier printer setup in System->Administration->Printing
  3. sudo hp-setup, next->next->next
  4. System->Administration->Printing, right-click on the printer icon, make sure that it's enabled
Once again, my thanks to those who provided this information on the forums. You saved me a lot of hassle.

The camera, Casio EX-Z80, worked without problems. It was instantly recognised by Ubuntu and data transfer worked nicely.

2008-10-11

New Sansa Fuze firmware with Ogg support

There is a new firmware update available for Sansa Fuze. It updates the firmware to version 01.01.15. Most notable improvement, long awaited one even, is support for ogg and flac files. The first ogg file I tried froze up my player and I had to reboot it, but after that I haven't encountered problems. Not yet at least.

Firmware update on Linux was easy following the instructions provided and involved just unpacking the new firmware file to the root of the device. And using the Sansa Fuze is easier now on Ubuntu also because the new Ubuntu 8.10 Beta seems to recognize the player without any command line magic required previously.

Playlist seem to work somewhat better too. Now if only the huge problems with video conversion were fixed. Perhaps after that I could actually recommend this player to others.

Ubuntu 8.10 (Beta)

I had some extra time so I decided to upgrade my Ubuntu 8.04 to Ubuntu 8.10 Beta (codenamed Intrepid Ibex, would you believe it). My earlier pursuits with Ubuntu and my Acer 2920Z are detailed here for 7.10 and here for 8.04.

My first try to upgrade failed miserably. The reason was probably that I had selected a country specific server from program sources. I switched to the main server and tried again. This time everything seemed to go fine, but apparently it did not, as Gnome wouldn't load after reboot. My first try had probably messed something up. So, from console, I used apt-get to redo parts of the upgrade (I tried several commands, such as sudo apt-get update, upgrade, dist-upgrade, install, autoclean). After this Gnome loaded and everything seemed to be fine.

Everything, that is, except wlan. Madwifi drivers wouldn't work anymore. I had a look at the madwifi ticket for this chipset and learned that it was no longer necessary to use the hack I had been using earlier. The patch had been integrated to a madwifi branch. Unfortunately, this branch was not yet available from Ubuntu repositories, so it had to be installed manually. So I downloaded the new madwifi HAL, compiled and installed it (make, make install). After reboot wlan was working again.

It seems that after the upgrade the random problems with sound seem to be gone and, finally, the internal microphones are working. Incredibly, even TV-out works now. It was a struggle finding the correct settings for the displays, though. When mirroring screens the main laptop display was forced into a suboptimal resolution. Through trial and error, reboots, and turning mirroring off, I finally found a configuration which enabled me to watch video clips on my TV while surfing the net.

So, again, some minor problems with the upgrade, but nothing major. I'll update this entry if anything interesting happens.

2008-08-02

Video on SanDisk Sansa Fuze

I recently wrote a post about my SanDisk Sansa Fuze mp3 player, especially on getting it to work on Linux. This post is about a specific issue with it, namely video. (Executive summary: it doesn't work.)

The Problem

Getting video working on the Sansa is ridiculously difficult if you are not able to use their archaic Sansa Media Converter Windows software, regardless of your own OS. The Sansa Fuze is in theory a pretty nice media player, which (again in theory) can play mpeg videos in an avi container. In practise, the Sansa expects this video to be in a absurdly specific format. For everything else it displays an error message. To get video into the correct format you must use the converter they have provided.

Sansa Media Converter

Sansa Media Converter is a horrible little video converting program, a true nightmare to use, and the only supported way of getting video to play on the player. It seems to be a rebranded Intervision product, which converts some common video formats to the format used by the Sansa Fuze. It is naturally Windows only and even on Windows it requires the player to be plugged in for conversion to be possible. It doesn't even load on Wine. On a virtual Windows machine it starts but refuses to convert as it can't see the player even if it's plugged in. Also on my old Windows machine it refuses to see the player. Sansa Media Converter represents everything that is wrong in today's computing, and does that faithfully. The pox on the people who wrote it.

Working Example

On the Sansa there is a preloaded video file, which can be used to investigate the format accepted by the player. Also, I have converted some other examples with the Sansa converter on a machine it actually accepted. I have loaded the files into a Windows program abcAvi Tag Editor (works under Wine), which displays a lot of information on avi files. Here's what it has to say about the preloaded example:

[RIFF AVI 20988512]: Audio/Video Interleaved File
[LIST hdrl 64638]: Format Definition Chunk
[avih 56]: Main AVI Header
[dwMicroSecPerFrame]: Microseconds Per Frame: 50000
[dwMaxBytesPerSec]: Maximum Bytes Per Second: 101885
[dwPaddingGranularity]: Padding Granularity (bytes): 1
[dwFlags]: Flags 0x00000810
[AVIF_HASINDEX]: AVI file has 'idx1' chunk
[AVIF_TRUSTCKTYPE]: use chunk type to find key frames
[dwTotalFrames]: Number Of Frames: 4137
[dwInitialFrames]: Numer Of Initial Frames: 0
[dwStreams]: Number Of Streams: 2
[dwSuggestedBufferSize]: Suggested Buffer Size (bytes): 15237
[dwWidth]: Image Width (pixels): 224
[dwHeight]: Image Height (pixels): 176
[LIST strl 32148]: Stream Format Definition Chunk
[strh 56]: Stream Header
[fccType]: Type: vids (Video Data)
[fccHandler]: Handler: 0x00000000 (No Compression <0x00000000>)
[dwFlags]: Flags 0x00000000
[wPriority]: Stream Priority: 0
[wLanguage]: Language: 0 (Undefined)
[dwInitialFrames]: Numer Of Initial Frames: 0
[dwScale]: Stream Scale: 500000
[dwRate]: Stream Rate: 10000000
[dwStart]: Stream Start: 0
[dwLength]: Stream Duration: 4137
[dwSuggestedBufferSize]: Suggested Buffer Size (bytes): 15237
[dwQuality]: Stream Quality (1-10000): 0
[dwSampleSize]: Sample Size: 0
[rcFrame]: Frame Size Of Stream
[wX1]: Top: 0
[wY1]: Bottom: 0
[wX2]: Left: 0
[wY2]: Right: 0
[strf 40]: Video Stream Format
[biSize]: Header Size (bytes): 40
[biWidth]: Image Width (pixels): 224
[biHeight]: Image Height (pixels): 176
[biPlanes]: Number Of Planes: 1
[biBitCount]: Number Of Bits Per Pixel: 32
[biCompression]: Compression Algorithm: DX50 (DivX 5.0 codec 'DX50' <0x30355844>)
[biSizeImage]: Image Size (bytes, 0 = uncompressed): 230400
[biXPelsPerMeter]: Horizontal resolution of target device: 0
[biYPelsPerMeter]: Vertical resolution of target device: 0
[biClrUsed]: Number of colors used (0 = maximum): 0
[biClrImportant]: Number of important colors (0 = all): 0
[indx 32024]: AVI2 (OpenDML) Super Index Chunk
[LIST strl 32138]: Stream Format Definition Chunk
[strh 56]: Stream Header
[fccType]: Type: auds (Audio Data)
[fccHandler]: Handler: 0x00000000 (No Compression <0x00000000>)
[dwFlags]: Flags 0x00000000
[wPriority]: Stream Priority: 0
[wLanguage]: Language: 0 (Undefined)
[dwInitialFrames]: Numer Of Initial Frames: 0
[dwScale]: Stream Scale: 1
[dwRate]: Stream Rate: 16000
[dwStart]: Stream Start: 417
[dwLength]: Stream Duration: 3309595
[dwSuggestedBufferSize]: Suggested Buffer Size (bytes): 2008
[dwQuality]: Stream Quality (1-10000): 0
[dwSampleSize]: Sample Size: 1
[rcFrame]: Frame Size Of Stream
[wX1]: Top: 0
[wY1]: Bottom: 0
[wX2]: Left: 0
[wY2]: Right: 0
[strf 30]: Audio Stream Format
[wFormatTag]: Audio Format: 0x0055 (MPEG-1 Layer 3 (MP3) <0x0055>)
[nChannels]: Number of channels: 2
[nSamplesPerSec]: Frequency of the sample rate (Hz): 44100
[nAvgBytesPerSec]: Average data rate (byte/s): 16000
[nBlockAlign]: Block alignment of the data (bytes): 1
[wBitsPerSample]: Number of bits per sample (0 = undefined): 0
[cbSize]: Size of extra information (bytes): 12
[wID]: Type: 0x0002 (Constant frame size)
[fwFlags]: Flags: 0x0000 (ISO Padding)
[nBlockSize]: Block size (bytes): 417
[nFramesPerBlock]: Number of frames per block: 1
[nCodecDelay]: Codec delay (ms): 0
[indx 32024]: AVI2 (OpenDML) Super Index Chunk
[LIST odml 260]: AVI2 (OpenDML) Format Definition Chunk
[dmlh 248]: Total Number Of Frames AVI2 (OpenDML) 4137
[JUNK 34]: Padding
[LIST movi 20824326]: Audio/Video Data
Skipped
[idx1 99312]: AVI Index Chunk
[LIST INFO 92]: RIFF Textual Informative Details
[ILNG 10]: Language: Undefined
[IRTD 8]: Rating: Unrated
[INAM 12]: Title: sansatesti
[IPRD 6]: Product: Movie
[ISFT 12]: Software Used: IntraAudio
[LIST MID 58]: Movie IDentifier Tags
[TITL 12]: Title: sansatesti
[AGES 8]: Rating: Unrated
[LANG 10]: Language: Undefined
[IDVX 128]: Unknown Tag
[LIST DIVXTAG 128]: IDivX tags
[Movie 32]: Title: sansatest
[Author 28]: Director:
[Year 4]: Creation Date Of Subject:
[Comment 48]: Comments:
[Genre 00000003]: IDivX Genre: 017 (Movie)
[Rated 00000001]: IDivX Rating: 0 (Unrated)


My attempts

I attempted to reproduce a working file with mencoder. I used the following command on the example file. The command does not produce a file acceptable to Sansa.
mencoder -ofps 20 -vf scale=224:176 -ni -noidx -nocache -ovc copy -oac copy -ffourcc DX50 -of avi infile.avi -o outfile.avi

The command does nothing to the audio and video streams, it just copies them to a new file. Only thing that changes is the container part of the file. I manually set the resolution, frame rate and FourCC code for this file. (The noidx option is actually not actually needed, as the example file has an index. That's just something I forgot there.) This resulted in a file described below

[RIFF AVI 20719086]: Audio/Video Interleaved File
[LIST hdrl 306]: Format Definition Chunk
[avih 56]: Main AVI Header
[dwMicroSecPerFrame]: Microseconds Per Frame: 50000
[dwMaxBytesPerSec]: Maximum Bytes Per Second: 0
[dwPaddingGranularity]: Padding Granularity (bytes): 0
[dwFlags]: Flags 0x00000900
[AVIF_ISINTERLEAVED]: AVI file is interleaved
[AVIF_TRUSTCKTYPE]: use chunk type to find key frames
[dwTotalFrames]: Number Of Frames: 0
[dwInitialFrames]: Numer Of Initial Frames: 0
[dwStreams]: Number Of Streams: 2
[dwSuggestedBufferSize]: Suggested Buffer Size (bytes): 0
[dwWidth]: Image Width (pixels): 224
[dwHeight]: Image Height (pixels): 176
[LIST strl 116]: Stream Format Definition Chunk
[strh 56]: Stream Header
[fccType]: Type: vids (Video Data)
[fccHandler]: Handler: DX50 (DivX 5.0 codec 'DX50' <0x30355844>)
[dwFlags]: Flags 0x00000000
[wPriority]: Stream Priority: 0
[wLanguage]: Language: 0 (Undefined)
[dwInitialFrames]: Numer Of Initial Frames: 0
[dwScale]: Stream Scale: 1
[dwRate]: Stream Rate: 20
[dwStart]: Stream Start: 0
[dwLength]: Stream Duration: 4137
[dwSuggestedBufferSize]: Suggested Buffer Size (bytes): 15229
[dwQuality]: Stream Quality (1-10000): 0
[dwSampleSize]: Sample Size: 0
[rcFrame]: Frame Size Of Stream
[wX1]: Top: 0
[wY1]: Bottom: 0
[wX2]: Left: 224
[wY2]: Right: 176
[strf 40]: Video Stream Format
[biSize]: Header Size (bytes): 40
[biWidth]: Image Width (pixels): 224
[biHeight]: Image Height (pixels): 176
[biPlanes]: Number Of Planes: 1
[biBitCount]: Number Of Bits Per Pixel: 32
[biCompression]: Compression Algorithm: DX50 (DivX 5.0 codec 'DX50' <0x30355844>)
[biSizeImage]: Image Size (bytes, 0 = uncompressed): 230400
[biXPelsPerMeter]: Horizontal resolution of target device: 0
[biYPelsPerMeter]: Vertical resolution of target device: 0
[biClrUsed]: Number of colors used (0 = maximum): 0
[biClrImportant]: Number of important colors (0 = all): 0
[LIST strl 106]: Stream Format Definition Chunk
[strh 56]: Stream Header
[fccType]: Type: auds (Audio Data)
[fccHandler]: Handler: U (Unknown Four Character Code 'U' <0x00000055>)
[dwFlags]: Flags 0x00000000
[wPriority]: Stream Priority: 0
[wLanguage]: Language: 0 (Undefined)
[dwInitialFrames]: Numer Of Initial Frames: 0
[dwScale]: Stream Scale: 1
[dwRate]: Stream Rate: 16000
[dwStart]: Stream Start: 417
[dwLength]: Stream Duration: 3309595
[dwSuggestedBufferSize]: Suggested Buffer Size (bytes): 8000
[dwQuality]: Stream Quality (1-10000): 0
[dwSampleSize]: Sample Size: 1
[rcFrame]: Frame Size Of Stream
[wX1]: Top: 0
[wY1]: Bottom: 0
[wX2]: Left: 0
[wY2]: Right: 0
[strf 30]: Audio Stream Format
[wFormatTag]: Audio Format: 0x0055 (MPEG-1 Layer 3 (MP3) <0x0055>)
[nChannels]: Number of channels: 2
[nSamplesPerSec]: Frequency of the sample rate (Hz): 44100
[nAvgBytesPerSec]: Average data rate (byte/s): 16000
[nBlockAlign]: Block alignment of the data (bytes): 1
[wBitsPerSample]: Number of bits per sample (0 = undefined): 0
[cbSize]: Size of extra information (bytes): 12
[wID]: Type: 0x0002 (Constant frame size)
[fwFlags]: Flags: 0x0000 (ISO Padding)
[nBlockSize]: Block size (bytes): 417
[nFramesPerBlock]: Number of frames per block: 1
[nCodecDelay]: Codec delay (ms): 0
[LIST INFO 42]: RIFF Textual Informative Details
[ISFT 30]: Software Used: MEncoder 2:1.0~rc2-0ubuntu13
[JUNK 3712]: Padding
[LIST movi 20714990]: Audio/Video Data
Skipped


There are some notable differences to the working example file. I suspect the most important one is "AVIF_ISINTERLEAVED" flag, which means that this avi file has interleaved video and audio. It is possible that this may be too much for the Sansa Fuze to handle.

Mencoder/Mplayer has, by the way, an option called -ni, which forces non-interleaved mode for reading files. Unfortunately it doesn's seem to affect decoding.

It is worth mentioning that the Sansa isn't picky about every little detail. I changed the FourCC code, for instance, on the preloaded clip to some false value and the clip still played.

VirtualDub

There is this Windows program called VirtualDub, which has an option for turning of interleaving avi files. I tried it under Wine. The program worked, but unfortunately, the file it produced had other differences to the examples. I haven't found options to fix those differences in the program

Possible Solutions

I'm no expert when it comes to video encoding, so currently I have no ideas how to move forward. I guess there might be some program somewhere that can reproduce Sansa's format, or perhaps it could be possible to make a non-interleaved version of avi codecs and try those.

For reference you might want to see further information on the video clip and this discussion.

Any help with this would be appreciated.

2008-08-01

SanDisk Sansa Fuze 8GB on Ubuntu 8.04

(Update: see also my posts about the video problems and about the new firmware with Ogg Vorbis support.)

I've recently purchased a SanDisk Sansa Fuze MP3 player. My old player has served me well for a very long time, but it's age is showing and I thought it was finally time to retire it. These are my notes on getting the Sansa Fuze working with my Acer laptop and Ubuntu Linux.

I selected SanDisk player after googling revealed encouraging reports about it's Linux compatibility and, especially, after I discovered that SanDisk explicitly mentions Linux in it's product specs. It also had some very nice features when compared to some of it's competitors, FM radio and voice recording for example. Also, I had seen some rumours about upcoming Ogg Vorbis support. Now, rumours are rumours and I believe when I see it, but ogg support would be absolutely fantastic.

Connecting

MP3 players in general use two different protocols to communicate with the computer. The older MSC protocol tends to work well with different operating system as the device shows up as a mass storage drive for the computer. Microsoft's newer MTP protocol, designed to implement DRM restrictions to players, usually requires special software. Then, of course, there are some variations of the two. For example, Microsoft apparently uses protocol called MTPZ for Zunes for some reason. Go figure.

Anyway, Sansa Fuze claims to support both of the aforementioned protocols, but only MSC for OSX and Linux. So I wanted to try that protocol first. I connected my player to my Acer 2970Z's USB port and waited. Nothing happened on the computer. The Sansa Fuze claimed it was "connected", but lsusb didn't show anything new. Oh well, I expected this much. So I tried this tip for another SanDisk player (removing kernel USB 2.0 driver with "sudo rmmod ehci-hcd", see also this post) and sure enough the player mounted immediately. At least now I knew my player could be mounted, even if at suboptimal speed. Fortunately I found out that the speed could be improved easily by reloading the kernel module after Fuze has been mounted ("sudo modprobe ehci-hcd"). This remounts the player and copying is much faster. Later I also discovered that if I use a passive USB hub the player seems to mount with no mod-magic from time to time, although not consistently.

Here's the command I use to get the player recognised. The sleep command gives the player some time to mount and increases the chances of this working slightly, I find:
sudo rmmod ehci-hcd; sleep 1s; sudo modprobe ehci-hcd

(Update: apparently, it at least sometimes suffices to use "lsusb".)

I copied a few mp3's and an ogg file to the root folder of the player. Mp3's worked, the ogg didn't (as expected, of course). I then copied much of my music library to the device. After doing this I discovered that m3u playlists showed up on the player, but they didn't work. More about this below.

MTP

Unfortunately, MSC mode does not show the content that had been preloaded to the player. So next, I tested the MTP support with MTPFS, which is supposed to enable drag'n'drop copy to MTP players from Linux. Apparently, it also has playlist support. So I disconnected the player, typed sudo apt-get install mtpfs, and set the player to MTP mode. I also reloaded the USB 2 kernel module just to see if it matters. Then I reconnected player. Nothing happened.

Mtpfs actually uses libmtp to connect to the player, so next I installed libmtp's mtp-tools with "sudo apt-get install mtp-tools" and ran mtp-detect, which promptly informed me that "No Devices have been found".

I proceeded to install the latest libmtp and mtp-tools from source (version 0.3.0). I found a helpful post at the Sandisk forums and followed it as far as it was applicable. The installation required some tweaking, as it apparently installed some files to non-standard locations and this left me for example with two versions of tool executables. Now I finally got mtp-detect to see my device. Amarok, Rhythmbox or mtpfs didn't see it, though. But I was still able to download the preloaded content from the player with mtp-tools.

Here is the one-liner I used to generate a command line for getting all the MTP mode tracks from the player:
(mtp-tracks | egrep -w '(Track ID|Origfilename)' |sed 's/[ \t]*$//'| sed 's/^.*D: /\" ; mtp-getfile /' | sed 's/^.*e: / \"/' | tr -d '\012' | colrm 1 4; echo \")

Not very elegant, very much ad hoc, but worked for me. As the command actually just prints a download command, which you can then check before pasting and running it, there should be no risk trying it. But, of course, I promise nothing and give no guarantees.

At this point I gave up on MTP for the moment and turned the player back to MSC mode. (Information from mtp-detect should probably be posted at libmtp bug tracker. I haven't got around doing this yet, unfortunately, as MTP isn't a must for this device. Perhaps someone else will find the time.)

Video

Getting video playback is a whole different story. Others have tried with no real success (see e.g. reqeya's post). First I copied the video file preloaded to the player and transferred it back with a new name. It worked. Then I tried copying some random avi files to the player. The player detected these files as video, but complained that they were in a wrong format. No surprise there.

Next I downloaded Windows software Sansa Media Converter from Sansa web site and tried it under Wine and in a virtual machine. Neither worked.

I tried numerous different things to get video working. Again and again, the player said that the media format is unsupported. I'm not very optimistic at the moment, as further investigation revealed that the player requires very specific format for the avi container. See the post I wrote about this for further details on the problem and the format used by the player.

I don't know much about video encoding and would appreciate if anyone else could give some advice on getting video work. For reference you might want to see further information on the video clip and this discussion. It's also worth noting that in the past others have had some success with earlier Sansa models and video, but the player's video format has been ridiculously specific. And they have of course changed the format for this model.

Let me know if you find anything useful.

Playlists

I already mentioned that m3u playlists seemed to be supported in principle. Some additional work is required, however, to get them fully functional. I tried creating a simple m3u file in the root folder of the device with only two entries. I created two versions of the file: normal one with a text editor and a dos version with unix2dos. Both showed up on the device but neither worked.

After some additional frustration I installed Easytag from Synaptic. This is how I got my first working playlist with a single song. I then copied this playlist to a different name, opened it in nano, changed the single entry in the file into a different file and saved. This also worked. Then I created my own list with identical input with nano and ran the file through unix2dos. After several tries I got this working too. As far as I know it is essential that the playlist has CR's in the end of every line:
$ cat -A list.m3u
#EXTM3U^M$
#EXTINF:259,song1.mp3^M$
song1.mp3^M$

The playlist must also use relative paths and Windows-style backslashes as directory separators.

Quite bizarrely, some of the stuff I tried seemed to work on and off. It seems that there were some random errors, possibly due to me yanking the usb cable on and off constantly. So, to be safe, you probably should wait for a while before detaching the cable, or you should unmount the device cleanly.

I have written some custom scripts that generate a few playlists automatically from my music collection. Unfortunately I noticed that Fuze read these very slowly and worked with them only after pushing menu button and back after the list had been loaded. Strange.

Slooow

The most notable annoyance with the player has been it's slow functioning. Apparently several gigabytes of music on a VFAT drive is just too much for it.

Especially slow is the "database update" after file transfer. This is mostly due to the numerous media files on the player, but still it could be a bit snappier. This also makes testing playlists etc. painful. Fortunately files in RECORD directory, for example, are not indexed, so you can put there everything that doesn't need to be indexed.

Playlists are also read very slowly. If a playlist is long, reading it will take forever. The best way to cope with these problems, I think, is to use only small playlists. Better way to categorise files is to set their genres to your liking with Rhytmbox/Easytag. Genres are indexed during database update and can be accessed almost instantly.

One other observation, that I can't be sure about at this point, is that the player seems a bit faster when mp3's are scattered in different directories in root folder, rather than all in MUSIC-folder. It also seems that very long file names may cause some sporadic file system problems from time to time. So, I have decided to remap my music collection to the root folder of the player, in a few directories with short names, with no folders for albums and such. I have automated this with a script that rsyncs my music collection to the device.

I've also had this problem with file transfers from time to time, where nothing is copied to the player and the system says the file system is read only. I'm not sure but perhaps this has something to do with filenames starting with a dot. After that remounting and deleting the file sometimes helps:
sudo mount -o remount,rw /media/SANSA\ FUZE/


A Few Further Notes

My firmware version was V01.01.11F, which at the time of writing this is the newest. So there was no need for firmware update. Apparently you can update firmware, however, without Windows just by dragging firmware .bin file to the device root in MSC mode. I haven't tested this.

I have some mp3 files with broken unicode characters in them. During this exercise I found that it is just easier to remove them from filenames than to get them working with Fuze and playlists. Here's one pretty demented way of doing just that:
ls --color=none -b1i | while read i; do find . -inum ${i%% *} -exec mv {} ${i#* }" \;; done

That took some experiment to get working. If you have just one or two broken filenames, it is easier just to rename them in Nautilus. Unfortunately, I had tens of them. This command is probably not the ideal way to rename files, but again, it was good enough for me.

Some discussion on Sandisk forums:



Conclusions

At this point it is hard for me to say whether I would recommend this player for Linux owners. SanDisks attitude towards Linux seems somewhat positive and they deserve to be rewarded for that. On the other hand, their media conversion software is still Windows only and their video format is just silly. The player probably takes some time to get used to, but at this point it does seem slow. Also, managing a large number of media files is not very easy.

This page chronicles the several problems I have had with this player, many of them in no way related to Linux. In general, I'm not happy with the quality of its software, especially. But from my own experience and from what I gather from the forums, other players are not much better. My suggestion is to research your own purchases thoroughly beforehand.

2008-05-03

Revisiting Ndiswrapper and MadWifi

To recap: Acer 2920Z has Atheros AR2425 (AR5007EG) wireless chipset:
$ lspci | grep Wireless
04:00.0 Ethernet controller: Atheros Communications Inc. AR242x 802.11abg Wireless PCI Express Adapter (rev 01)


Support for this chipset with the official Madwifi-drivers is incomplete. So, you have two choices: either you use Windows drivers with Ndiswrapper or you try the Madwifi-drivers anyway. I have tried them both and both eventually worked for me. Now I'm using Madwifi, which is more native and hopefully a bit faster solution. Below are instructions for both

Ndiswrapper

Earlier, I wrote how I got my WLAN working using the instructions given at http://wiki.gadz.org/Linux/LaptopAcer. As that site has been down for quite a while now, as a public service, I'm posting the relevant commands given there here. This page has been reconstructed from my own notes, so it does not really resemble the original much, only the commands are the same.

To check for Madwifi driver compliance:
dmesg | grep -i wifi
lsmod | grep ath
sudo iwconfig


To remove madwifi driver:
sudo rmmod ath_pci

To blacklist it add a line
blacklist ath_pci

to /etc/modprobe.d/blacklist-common

To download ndiswrapper drivers that worked for me on 2920Z: drivers-32bits or drivers-64bits. (These seem to be still up, although the page itself is down.)

Using the driver:
sudo ndiswrapper -i net5211.inf

Launching the driver:
modprobe ndiswrapper

Testing to see that you have wlan interface:
sudo ndiswrapper -l
sudo iwconfig


To load module on boot add line
ndiswrapper

to /etc/modules. (This may be unnecessary on Ubuntu if ndiswrapper is already loaded.)

Finally reboot and setup your network. Alternatively you can use the graphical ndisgtk and network settings.

These are the links suggested by the page:


MadWifi

Update 2008-10-11: This information on installing MadWifi is somewhat outdated, see my post here and this MadWifi ticket.

I tried following the tutorial that was linked from the Google docs site listed above, but my machine froze when trying to do the modprobe. With some additional effort, however, I was able to get a newer version working and I'm using it right now. Here is a modifed version of the tutorial that worked for me.

If you've been using ndiswrapper earlier and have blacklisted the atheros driver, first remove the blacklisting. Also make sure that you are not using the currently installed atheros drivers from the restricted drivers manager (untick the boxes).

If you haven't built anything before, install build utilities
sudo apt-get update && sudo aptitude install build-essential

Get the latest madwifi snapshot with the patch from http://snapshots.madwifi.org/special/. For me it was madwifi-nr-r3366+ar5007.tar.gz. In terminal window untar it
tar xvzf madwifi-nr-r3366+ar5007.tar.gz

and cd in to the directory
cd madwifi-nr-r3366+ar5007/

Build (make clean is usually not absolutely required)
sudo make clean
sudo make
sudo make install

and add the driver
sudo modprobe ath_pci

You should now get a connection with devices wifi0 and wlan0
sudo iwconfig

You may have to reboot, though. You may also want to add ath_pci to /etc/modules, so that it is loaded automatically at boot. If at a later time, for example, a kernel update breaks something, rebuild and reinstall.

2008-05-02

Acer Aspire 2920Z and Ubuntu 8.04 LTS : upgrade notes

As promised, here are my notes on upgrading my Laptop to Ubuntu 8.04 LTS.

The download and installation took some four hours over my "broadband" connection. The installation asked a few questions about replacing old files. As it provided diffs, it was possible to see the changes and whether it was necessary to overwrite the files or not. The only file that I was unsure about was alsa-base, which I did overwrite but only after I had made sure I had a backup copy of the old file, as I wasn't sure if the changes were all OK.

Then it was time to reboot. After the first reboot, when I logged in, Gnome was very sluggish to load. I suspected this was due to wireless network being down, so I connected LAN cable and rebooted. Then I rebooted a couple of times again for various reasons like boot process freezing. Then I logged in.

For some reason, in Gnome, my keyboard now produced Greek symbols! I changed the keyboard layout from generic to Acer laptop, which fixed the issue.

Next I discovered sudo was not working anymore either. To fix it I followed instructions give by JP-NYC here.

The sound still worked but the volume slider had no effect anymore on the internal speakers, only on line out. This was easily fixed from settings. Jack sensing was working, though. I couldn't get internal mic working despite considerable effort.

Wifi stopped working, naturally. I uninstalled and reinstalled the wireless driver from ndisgtk. After that I fiddled around with network settings turning things on and off. Finally, after about two hours, I got the network wireless working again. During this episode I noticed that often the problem with the wireless seems to be with the encryption. If you can afford to leave your wireless network without encryption for a second it may be easier to get the wireless working that way first and then add encryption. I'm still not convinced, though, that the wireless is working completely. It seems a bit flaky and slow to connect after reboots. But I'm usually able to connect to the Internet at least after a while. I've switched to roaming mode for now, as it enables easier reconnection to the network.

Drivers for Intel graphics cards have been updated. I turned on desktop effects and they now work even when displaying video. Nice. The X server was also updated. I also tried to get the TV-out working, but I had no success. Of course I spent way too much time adjusting Compiz settings to get every glare and animation right. I also switched from Gdesklets to Screenlets and spent a lot of time configuring them the way I like. I prefer Screenlets to Gdesklets as they tend to look more polished. And now Screenlets can be found with Synaptic and you don't have to install it yourself anymore.

Speaking about the programs I use for a while, Ubuntu 8.04 comes with Firefox 3 Beta 5. I mostly enjoy the changes they have made apart from some minor peeves. All in all Firefox 3 is a pleasant step forward. Pidgin IM has been updated and I do not like it. (Apparently at least some agree with me.) Eclipse, on the other hand, is still version 3.2 Callisto and not 3.3 Europa. This is unfortunate. Well, at least Netbeans has been updated to version 6.0, which I think is a huge improvement.

Suspend or hibernation do not work at the moment. I'll have a closer look later, but I do not expect any meaningful progress.

After a few days I noticed that some things were working less perfectly than before the upgrade. It seems that the internal speakers now sometimes produce an odd "crackling" noise when playing a short loud sample like instant messaging notifications. Also it seems that some samples are left unplayed if I'm playing music at the same time. Also, now after reboot I have to login twice, as the first login always fails. (It goes something like this.) And of course the problems with WLAN annoy the living daylight out of me.

In my earlier post, which was a wish list for Hardy, I mentioned three things which I especially wanted to get working: suspend, sound and Compiz. The first one I didn't get, the second one I got only partially with some setbacks and the third one is working now very nicely. All in all I do not yet see enough benefits to justify this upgrade. Maybe later if they get the bugs sorted out. Next I will be still looking for that suspend fix and now also for better wireless drivers, as ndiswrapper is hardly ideal.

2008-04-26

Hardy is here!

Oh, joy!

As Linux enthusiasts may already know, Ubuntu 8.04 LTS (code name Hardy Heron) was released this week. I've already earlier installed the development version on several normal desktop machines without any major issues. Now that it has been released officially, I'll also be upgrading my Acer 2920Z laptop shortly. I'll write about the results here later.

2008-02-13

Nokia 9500, MMC-cards and Canon Smartbase MCP190

Since my last post I've had a chance to test a couple of pieces of hardware with my Acer 2920Z laptop and Ubuntu 7.10. Here are my notes.

First of all, the Nokia 9500 Communicator, which I tried connecting with the Nokia USB cable. Nothing happened. I also tried Wammu and KMobiletools, which did not recognise the phone. The phone shows up on lsusb listing, though. Apparently some have had better luck with Bluetooth or infra red connection.

Then, the 128 MB MMC card which was from the Nokia phone and which I inserted in the internal card reader in my laptop. Nothing happened. A "Generic- Multi-Card" listing which shows up in Gnome file manager apparently means nothing.

And finally, the Canon Smartbase MPC190 printer with an internal scanner. The printer is broken but the scanner works with Windows. I was eager to see if I was able to scan something in Linux. I plugged it in and tried various things I found from the Internet. Nothing happened.

So, there you go. 0 out of 3.

I obtained these machines for free, so I didn't pay for anything I didn't want. Therefore I'm not too annoyed. But still it is sad to see how poor the driver support from big corporations still is. Canon is notorious for it's poor Linux support. I wouldn't buy anything from them, when at the same time HP is making open drivers and even some other cool Open Source contributions. Way to go HP, I know where I'll be spending my money next time I need a printer!

But Nokia... makes me really sad. I've been buying Nokia phones solely for several years. And what I'm about to say is almost considered treason in my home country. Nokia isn't doing so great, not at least on the Open Source front. Surely it is not too much to ask that their phone would be accessible from other OS's. But even their closed source Windows connectivity suite is pretty horrible. Sure, they have done some cool stuff with open tablet software, for example. Still, (unfortunately) I'm really rooting for Google's Android nowadays. Google seems to be showing Nokia how things should be done. At the same time, Nokia keeps shunning open formats on many fronts. Nokia's recent acquisition of Trolltech raisesy questions about Nokia's motives with not enough answers. And all this might mean that my days of buying Nokia phones only are over.

And, as far as the internal card reader in my laptop is concerned, I hope i get it working sooner or later. If anyone reading this has any suggestions I would be happy to hear them.

2007-12-30

Update on sound and power saving

In an earlier post I wrote about the problems I had with sound in Ubuntu on my laptop. Well, "Henning" commented on it and suggested installing latest development snapshot of Alsa drivers, which I did. I then modified the option line I had added earlier to /etc/modprobe.d/alsa-base to "options snd-hda-intel model=acer". Now jack sensing and recording via the microphone jack work fine! No luck with the internal microphone, though. I'm not sure if I haven't just found the right settings or if it's not supported yet.

Henning also suggested this nice website lesswatts.org and the program powertop, which I promptly installed from Synaptic. I'll have a closer look at it when I get the time.

PS. I would like to thank those who have commented on my earlier post. If you have anything to add I hope I hear from you. Especially if you have any suggestions on how to get suspend to work.

Update 2008-04-26: ChrisSavery wrote a couple of interesting comments to this post about the built-in mic. I was unable to get it working, but perhaps someone else can give further advice?

2007-12-19

My sound just died

I just installed an official kernel security update vie Ubuntu update feature, rebooted and when my system was back up I had no sound. Nice.

This may have been due to the fact that I have manually installed newer Alsa to get the sound working. Well, I recompiled the drivers and rebooted. Now I have sound again. I know it isn't easy to support hardware, especially when it's new or you have to reverse-engineer it. And I certainly don't now what is the case with my sound drivers. Still, it would be nice if the end user didn't have to recompile drivers, ever.

2007-12-13

Ubuntu Hardy: what I want to see

The next Ubuntu edition, codenamed "Hardy Heron" is coming out next spring. It is a so called Long Term Support edition. From my point of view, when I evaluate my experiences with my new Acer laptop, this is what I'm hoping to see. This is mainly stuff that isn't up to the developers of Ubuntu but to the developers upstream who make the drivers and such. I'm just hoping new versions make it to Hardy.
  • Working suspend. ACPI-support is a mess. I think there are at least some improvements planned, I really hope they fix the issues I'm having.
  • Updated sound drivers. I have actually already tried some updated ALSA drivers, which did fix some of my problems. The rest, maybe later.
  • Compiz and graphics drivers. There will be a new version of X11 in Hardy and with that some new graphics drivers from Intel. This may or may not fix some of the issues I had with Compiz.
It seems that my problems are common so there is at least some hope of getting them (partially) addressed. As it is often the case, Linux support for new hardware improves gradually in time. It can sometimes be hard to support hardware when the manufacturer releases only Windows binary drivers. So I'm waiting patiently.

2007-12-11

About the Load_Cycle_Count issue

Some time ago there was a post on Slashdot suggesting that there might be an issue with the way some laptop HD's handle power management. There is a page on Ubuntu wiki explaining this issue. I'm not sure if this is something to be worried about or not. I did however notice my HD making this constant clicking sound when the machine was idle. Something is probably trying to access the drive every few seconds so that whenever it spins down it must spin up almost right away.

There are problems with the suggested fixes. Nevertheless I decided to give them a go as the rate of clicking was at least annoying. I followed the instructions given in the wiki for the "99-fix-park.sh" workaround. I also tried the command measuring the count. After the fix the count does indeed increase less rapidly. Since using the workaround I haven't noticed any more clicking from the drive. But it seems there is increased heat output now.

If I understand correctly lower values of Advanced Power Management level setting (option -B of hdparm) park drive heads more often and produce less heat while higher values cause less frequent drive head parking. The original workaround suggests using 254, which provides least frequent drive parking. I tried several different values but settled to 195, which seems to be about the lowest value for me that doesn't cause constant HD clicking.

I think I may have to keep an eye on this issue and see if there is some compromise or a better fix some place.

2007-12-10

Acer Aspire 2920Z and Ubuntu 7.10 Gutsy : installation notes

This is an informal case study of installing Ubuntu 7.10 Gutsy on my new Acer Aspire 2920Z notebook. The computer came with pre-installed Vista. I found this to be enough of a push to give Linux a try. I suspect a lot of what is written here applies also to Aspire 2920 and 2420, which are quite similar to 2920Z.

As my Linux skills are far from perfect, this is not really a how-to but a document of my learning experience. I have had the machine only for a few days and I will update the situation in case I get any progress. I would also appreciate to find out about the experiences others have had with these notebook models either here or on the Ubuntu forums.

Update 2008-05-02: I've written some notes on my upgrade to Ubuntu 8.04 LTS and updated this post to reflect that. Summary: upgrade fixed Compiz, but other issues remain.
Update 2008-07-22:See this blog by Christian Imhorst for more on installing 8.04 on 2920.
Update 2008-10-11:See here for my notes on upgrading to Ubuntu 8.10.

Still Remaining Issues

Suspending and hibernation are not working. These are the most serious issues. Compiz messed up video playback until I upgraded to 8.04.

The Computer

Acer Aspire 2920Z, Intel Pentium Dual CPU T2330 @ 1.60GHz, Intel GMA X3100, 2 GB, 160GB, 12.1".

Here's some of the more interesting parts of lspci:
00:00.0 Host bridge: Intel Corporation Mobile PM965/GM965/GL960 Memory Controller Hub (rev 03)
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 03)
00:02.1 Display controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (rev 03)
00:1b.0 Audio device: Intel Corporation 82801H (ICH8 Family) HD Audio Controller (rev 03)
02:00.0 Ethernet controller: Broadcom Corporation NetLink BCM5787M Gigabit Ethernet PCI Express (rev 02)
04:00.0 Ethernet controller: Atheros Communications, Inc. AR5006EG 802.11 b/g Wireless PCI Express Adapter (rev 01)

Background

Although I have been using Linux at work for several years, the last time I tried installing it at home was about five years ago. The results were not very impressive. After that Linux has matured a lot, so I was eager to see if I could eventually dump Windows altogether. This was made easier by the fact that I have been using open source software and Cygwin on Windows for a long time, so many of my favourite programmes (Firefox, Octave, Eclipse, ...) were also available for Ubuntu. I must admit that I kept my old Windows XP machine around, as my previous experiences with Linux laptops had left me prepared to do quite a bit of tinkering to get the laptop working fully.

Installation

First of all, I created DVD's in Vista for system recovery. Just in case something goes terribly wrong. The process was both nerve wrecking and time consuming thanks to the crapware Acer had pre-installed on the machine. Apparently supplying real OEM disks would have been too much of a trouble.

Gutsy Live CD booted OK, but there were some random glitches on the desktop screen. Opening screen settings fixed that. Installation went with no noteworthy issues. I did not want to keep my old Vista partition, so I didn't have to think about partitioning the drive. I am not sure though if Acer's hidden partitions were successfully wiped out. The one annoyance was caused by the lack of live Internet connection during the installation. Because of this the installer disabled repositories in /etc/apt/sources.list. I uncommented the repositories after installation by hand so I could download updates once my ethernet cable was connected.

Ubuntu installed automatically the restricted atheros drivers for wifi, but wifi still did not work. I installed ndiswrapper and downloaded drivers for the similar Acer 5720Z laptop. These did work. (Update 2008-05-02: the preceeding link seems to be dead. I have been able to partially reconstruct the instructions and find links to the drivers.) I also tried some XP drivers directly from Acer's web site but had no luck with them and didn't bother trying for long after I got wifi working. (Update 2007-12-23: If you have problems with wifi you might want to have a look at this Madwifi support ticket. Thanks for suggesting this in the comment section to "cyrille".) "Experimental" Intel graphics drivers installed automatically, but apparently the Intel chipset in my notebook, combined with Compiz and buggy Gnome resolution utility results in a quite volatile mix, which caused the manifestation of several problems, detailed below.

I installed the common restricted extras, so MP3's, Flash videos and such work. Installing Java broke programme installer somehow. This was fixed with the a terminal command suggested by the installer.

Later on I also tried Feisty Live CD to see how it would boot. It didn't. Rather it game me just a BusyBox prompt. Nice to see that things have move forward since the last release.

Graphics

First I didn't get Compiz working at all. After some googling I discovered that my gfx chip is on the Compiz Hardware Blacklist. I got Compiz working by doing what the page suggests (ie. setting SKIP_CHECKS=yes in ~/.config/compiz/compiz-manager). Trying the sleep mode with Compiz on broke something in the gfx drivers or X configuration, I had to reinstall gfx drivers and boot to fail safe and such before the Intel drivers could do 1280x800 again. Unfortunately I discovered that Compiz broke video playback completely. VLC complained about lack of gfx memory. I tried reconfiguring X, explicitly setting gfx memory to 300 MB. This time VLC tried to begin video playback, but them died with the same error message. Same thing with MPlayer (error: X11 error: BadAlloc (insufficient resources for operation)?,?% 0 0). (This problem seemed to have same similar symptoms as described here and here. I tried what the other page suggests, setting Option "LinearAlloc" "8160" in xorg.conf. It didn't work.) After these problems I decided to turn Compiz off. Video playback and 3D apps work fine now. These issues with Compiz were only resolved after upgrading to 8.04.

Dual monitor setup didn't work out of the box, rather it messed up X pretty decently. I had to reconfigure X again and try some other stuff as well. By this time my xorg.conf file and all of its backups (xorg.conf.*) were getting pretty looped. Googling around I found a page describing the procedure of getting dual view working with xrandr. The page also suggested tossing gnomes display manager out of the window and, as I was getting pretty fed up with it, I was happy to comply. So it was time to start reading about manually configuring xorg.conf and then trying xrandr to get the display working.

This approach worked OK and I was able to set up dual view. The problem is Gnome, which forces toolbars initially on the external screen for no good reason. Also, the size of the virtual screen is apparently quite limited so I was unable to set the monitors side by side virtually Only one above the other worked. Dual view is an important feature for me, so getting this working was a priority. It's a shame the setup wasn't more intuitive. Also the results could be better, especially Gnome performed inadequately. Fortunately Ubuntu 8.04 fixed a lot of these problems.

Some other pages I found Informative:

Power management / ACPI

  • Closing the lid turns the monitor off. This is apparently an automatic hardware feature, as it works even after I turned it off from Gnome.
  • LCD brightness setting in Gnome Power Management works only in the increments of 10 %. Ie. values like 55 % or 85 % just set the LCD brightness to 100 %.
  • Resuming hibernation kind of worked at first. Then after resuming I seemed to have lost at least the sound. Now it doesn't work at all, apparently not enough swap space.
  • Resuming suspend doesn't work. Machine apparently tries to turn itself on but then freezes. Working power management, suspend mode is important for laptops, so I'm disappointed this is not working. I tried numerous things to get suspend working, among them information on these pages:
One of the things tried was installing s2ram (see the page at opensuse.org) which was a lot easier to understand than standard Gutsy suspend configuration or pm-tools. However, none of the options presented at the web site worked. I tried running them from the failsafe command prompt selected from GRUB menu. In every case the laptop refuses to resume from suspend. Instead it just turns the power led and fan on. Caps lock is not working. The only exception is option -s which occasionally (1/3 of the time) got me back to the command prompt with the error message: "Function not supported? Switching back to vt1". I tried running s2ram from a minimal shell by adding "rw init=/bin/bash" to the kernel line in GRUB settings. Now "s2ram -f" resumed to the command prompt, but apparently not completely successfully, since the terminal seemed to be only partially the same as before suspending (at least the font was different). After this I also tried pm-suspend, which seems to work as s2ram. I also tried s2ram after downgrading to an earlier kernel that some claimed would might fix suspend issues. It did not help.

Interestingly, rebooting does not work either. If I choose to reboot from the Gnome shutdown menu, the laptop freezes in the "Acer" boot screen. If I want to reboot I have to shut down the machine completely and then turn it on manually.

I see from the Ubuntu forums that a lot of people are having problems with suspending, so I can't say I'm surprised. Since the machine almost makes it back from the minimal shell, there clearly is some potential here to get suspend working, but I'm not succeeding. What gives?

Networking

At one point after installation I relocated and my WLAN configuration changed. Unfortunately there were problems setting up the wireless connection with my D-Link router. I was able to ping the router and some websites, but about 20 % of the pings didn't return. Looking at the router logs I discovered that the wireless connection was hanging up every few seconds. This made Internet "not work", ie. surfing is impossible. It turned out this was due to the default encryption used by the router WPA/WPA2. Once I changed the same encryption to both the router and my laptop it worked fine.

Home network. I had to transfer files from my old Windows desktop to my laptop. I tried setting up the laptop as SMB server. The XP box was able to see it all right, but I was unable to access it at all. This is still unresolved and I have no interest in debugging Samba configuration files... In the mean time, I found a much simpler answer to file transfer. I typed "sudo apt-get install ssh" in Ubuntu which installed the ssh server. After this I was able to connect to the laptop with WinSCP and transfer all the files I needed. I for example transferred my Firefox bookmarks and Pidgin configuration files. Since I already had Cygwin on XP it was relatively easy to set up ssh server there too, so I could browse files on my desktop from Nautilus. This turned out to be much simpler than setting up SMB.

I also tried TightVNC to see if I could easily get remote desktop working on XP. Unfortunately I experienced frequent random lockups on XP when connecting from Linux. Connecting with the VNC Java applet from Firefox was the most stable solution though.

Peripherals

  • Web camera works using the KDE program Kopete and Ekiga, though Kopete was the only one to automagically get the settings right. In Ekiga I had to change the device type to V4L2 manually. Other programs, apparently the ones using original V4L, did not work at all. This is a shame, I would have expected at least Camorama to understand V4L2.
  • DVD-burner and CD-burner are untested.
  • TV-OUT seems not to work. (See Christian's comment to this post, though, for more information on this.)
  • USB sticks, mice and such seem to work. External CompactFlash reader works.
  • Synaptic touch pad works. I haven't tried configuring its sensitivity though. The default setting is OK, but it could be a little less sensitive I guess.
  • I plugged in Logitech game pad, which was recognised by joystick calibration program, but did not work with any games I tried.
  • Internal speakers worked, but headphone jack wasn't not recognized. Sound still came through internal speakers and there was no sound from headphones. Internal microphone seemed to record only static. External microphone jack was apparently not recognised. I followed instructions on Hda Intel soundcards at Ubuntu website. I installed the latest version of ALSA using "3stack" as the model identifier, as that was the only one available for ALC268. This got me a bunch of new sliders in Alsamixer. Playing with them I got sound from the headphones. Still no jack sensing though. And the microphones still do not work. I suspect that ALSA does not yet support this model and this is something I hope will change in the future. (Update on sound 2007-12-30: jack sensing and line recording work now, see this post.)
  • Volume wheel works. Extra keys, such as wlan on/off and web browser start seem to work in Gnome, although their indicator leds seem not to.
  • Memory card slot not tested
  • 56k modem not tested
  • (Update 2007-12-23: I have now also tested my Canon Digital Ixus V2 camera and it worked right out of the box! This was a very pleasant surprise.)

Conclusions

Since the last time I tried installing it Linux has matured a lot for sure. I was surprised by the relatively few serious issues I had with the installation. As expected, most problems, although numerous, were minor annoyances having to do mostly with incomplete device drivers.

By far the biggest disappointment were the problems with power management. One of the nicest features of a notebook computer is the ability to just open the lid anywhere and have the machine up and running within seconds. I'm really hoping Ubuntu gets this fixed as soon as possible. Hopefully Hardy will have power management that actually works for most people. This is such a serious issue that I am not comfortable recommending Ubuntu to anyone less technically inclined, at least not for laptops. Nevertheless, for me it is fine and it seems that this machine will replace my Windows box as my number one machine very soon and I'm hoping to be completely Windows free at home at some point in the future. It may not be this year, but I sure as hell hope it won't take another ten years.

Update: I created threads in English and in Finnish on the Ubuntu forums about the remaining problems, because I hope there might be someone there who knows how to solve them. If you have some suggestions but you prefer replying in the forum threads instead of this blog then please feel free to do so.
TuxMobil - Linux on Laptops, Notebooks, PDAs and Mobile Phones Linux On Laptops

2007-12-08

Some motivation

Erm, hello.

A week ago I bought a laptop. I then installed Linux on it. That didn't go completely smoothly, which was not surprising considering that the model was quite new. I decided to write down some notes on the installation in the hope that they may benefit others who own the same laptop.

These notes had to be published somewhere and I came to the conclusion that a blog might be the best alternative. So here we are. Initially I am going to write here about the laptop, maybe also about computers and technology in general. Later on I might write about other things as well, but I haven't really thought about that yet. Who knows, maybe I'll even use this blog for incomprehensible ramblings ("w00t!") and inane rants ("Wake up sheeple!"), keeping with the best traditions of the blogosphere. Provided that I first go insane, of course.

Post scriptum: As English isn't my native language, I feel I must apologise in advance for all the bad English you are about to see here. I hope it doesn't bother you too much. But enough about that, moving on.