Magic Mouse

My current mouse was not good at scrolling, so I decided to buy Apple’s Magic Mouse. Yes, my “old” mouse is still working, so I should not have bought a new one (but in fact I’m still using it).

As usual with Apple, it’s a nice piece of hardware and as usual with Apple, it’s sucking in some ways.

It’s a beautiful mouse, with its complete surface being tactile. I bought it because my previous mice was not scrolling correctly. Does the magic mouse does the job correctly? Yes. Scrolling is very nice. And with the momentum option activated it’s even better.

Some people are complaining because the edges are a bit too sharp, in fact I didn’t noticed it before reading it, but yes, a bit smoother would be better.

Some other people are complaining that the cursor’s movements on the screen are not fluid. I had the same problem from time to time and the simple solution was to have the mouse closer to my laptop, I reduced the distance from 1 meter to 50 cm. Yes it’s lame, it’s bluetooth, I experienced the same problem with an other bluetooth mouse. And bluetooth is also slow, it introduce a latency in cursor’s movements that you can feel when switching from a wired mouse to a bluetooth one, but it’s small enough to go unnoticed after few minutes.

An other thing is that you can’t do the nice gestures you can do on the trackpad. You can download MagicPrefs which enables lot’s of gestures, but in fact I found it quite awkward and difficult to do most of the gestures on the mouse.

Forget about gaming. Of course this mouse is not designed for hardcore gamers, even for gamers at all. The simple fact is you can’t do left and right click at the same time (you were thinking about jumping and firing at the same time in QUAKE LIVE? So that’s why I’m still using my old mouse when I want to play).

But to me, the major problem is that the mouse is way too slow. And it looks like a lot of people think the same.

Event when putting the track speed to the maximum, the magic mouse is still a bit too slow. Interestingly, when removing the drivers, the mouse is way much faster but no more scrolling or gestures… which was the point of buying this mouse. MagicPrefs allows you to increase the speed a bit, looks like MouseZoom do the same as well. But I don’t really like the idea to have to install an extra software to increase the speed. I should be able to set it directly somewhere. Some people are giving some commands like this one:

write -g com.apple.mouse.scaling -float 5.0

It seems that it’s the value written in the system when changing the track speed. In the System Preferences the max value seems to be “3”. So with this command you can set it to a higher value. But each time you have to log out and log in!

If you have to do it only once, it may do the trick. But here I come to an other problem. Let’s imagine I want to play on some games requiring a “classical” mouse, I need to change the tracking speed to a lower value for the “gaming” mouse and when I’m not playing anymore, change back the value… with the command line, and logging out, then logging in…

I already talked about it, but why operating systems are designed for only one mouse and one keyboard?

Have a look at this (from Mac OS X System Preferences):

What do you notice? We can configure several displays, but only one keyboard, one mouse and one trackpad… One mouse and one trackpad? Those are two point and click devices, aren’t they? So in a way we can have two different pointing devices with different settings, so why limiting this difference by “kind” (mouse/trackpad) and not by plugged devices?

Only few people are using more than one of these devices? OK maybe, and most people are also using only one display… and most people I know using a laptop as their main computer plug an external keyboard, so they have the laptop keyboard (and trackpad) and the external keyboard (and mouse) and usually laptop keyboards and standalone keyboards are different and may require different configurations. And of course the case when pair programming.

Mice and keyboards are not dead yet (they are not going to be wiped-out by touchscreens and virtual keyboards before long (in the end they may, but not before at least a decade or two)). So please, you people writing operating systems, would you be nice enough to handle that problem?

Conclusion

After few days using the Magic Mouse, I can say that I found it being a nice device in general, a very good mouse for common usages, not suitable at all for games and way too slow (a fix for that should be trivial to release).

fit-PC2

Last year I bought a fit-PC in order to replace my old router (which was a desktop PC). This year I bought a fit-PC2 to replace my home server (which was a big fat computer).

Requirements

This time my needs were a bit different than the ones for my router. I was looking for a low power consumption device with at least 512 MB of RAM, fast enough to read videos (I may use it as a HTPC in the future), fan-less and of course, it must work with Linux.

fit-PC2 specifications

So I end up with Compulab’s fit-PC2. Here are the official specs:

  • CPU: Intel Atom Z530 1.6 GHz
  • RAM: 1 GB DDR2-533
  • HDD: 160 GB SATA 2.5”
  • Gigabit ethernet port
  • USB 2.0 ports
  • 2 mini-USB 2.0 ports
  • 1 mini-SD socket
  • 1 IR receiver (infra-red, for remote control)
  • DVI output (using a HDMI connector, HDMI to DVI cable provided)
  • Power consumption: 6 W idle, 7 W reading H.264 videos, 8 W at full load
  • Shipped with Ubuntu

Several flavors are available (with WiFi, without hard drive, with an Atom Z510 CPU…).

Pictures

Usage

I tried the pre-installed Ubuntu but it’s an old version (8.04). Anyway, it was working quite fine. For video playback only MPlayer was using hardware acceleration provided in fit-PC2. I played Sita Sings The Blues on it, it works wonderfully (the movie is a Full HD (1920*1080), 4.12 GB file (I was hardly able to read it on my MacBook)).

But I don’t really want to use Ubuntu. If I want a *buntu linux I would install Kubuntu instead, anyway I installed Debian. Here is the beginning of my troubles.

First, I’m using Debian’s “testing” version, which proved to be quite stable so far. Except with the new 2.6.30 Linux kernel which froze my VIA C7 powered Dedibox and is behaving weirdly on the fit-pc2. I don’t know if the problem is in linux kernel, gcc, debian… but installing 2.6.30 kernel was not a good thing on my debian boxes. I’m using the fit-pc2 remotely (ssh, music streaming, time machine backups…) and from time to time it stops to respond, but if I hit a key on the keyboard, network operations resume… very weird. A problem in power saving code? a deadlock which resolved itself when a new interruption is raised? No idea, I’m clearly not competent in that domain. Easy solution: revert to 2.6.26 kernel.

Second problem: drivers. The graphic chipset used is an Intel GMA500. Even if Intel recently helped the Open Source community by giving specifications of its chipsets, they didn’t for that one (because it’s not really an Intel one, it was developed by PowerVR (and they are much less cooperative)). Somehow Compulab/DeLL/Ubuntu managed to get a partly open source driver with hardware acceleration (that part is still proprietary), but according to various websites, the driver is crappy and not well maintained (but it looks like some people are trying to make that better). So, for now, hardware acceleration does not work easily on Debian. I hope it will work soon.

Power consumption
  • Off: 0.3 W
  • Idle: 9 W
  • H.264 playback: <10 W
  • Full load: <11 W

It seems that it consume a bit more than expected (my watt-meter is a cheap one, I’m not sure how reliable it is), or maybe figures on fit-pc2 website were given for an Atom Z510.

Note: the case can be very hot.

Conclusion

fit-PC2 is a nice bit of hardware, but if you are going to install an alternative BSD/Linux operating system, you have to know that you may get some troubles with video drivers (if you need nice graphical interface).

D-Link DWA-110 on OpenBSD 4.4

In order to reduce power consumption and simplify my home network, I wanted to remove my WIFI router and replace it by adding an USB WIFI dongle on my router (a fit-PC with OpenBSD on it).

Choosing a dongle

As WIFI hardware is mostly proprietary stuff with Windows only drivers, not all of them are able to run on OpenBSD (or Linux).

So my requirements are:

  • USB WIFI dongle (USB is the only kind of connectors I can use on my fit-PC)
  • recognized by OpenBSD
  • do not requires non free (as in free speech) binary firmware
  • can work as an access point

I already had an Acer WLAN-G-US1 dongle, it has a ZyDAS chipset, which is supported by the zyd driver, but it can’t act as an access point.

From the OpenBSD’s supported WIFI hardware page I randomly selected the rum driver (working with Ralink RT2501USB and RT2601USB chipsets) and went to a store with the list of dongle models supported.

So I bought a refurbished D-Link DWA-110.

Plugging the dongle

When plugging it in the fit-PC, I got the following message in /var/log/messages:

(…)
Nov  7 20:00:32 hal /bsd: ugen0 at uhub0
Nov  7 20:00:32 hal /bsd: port 1 "Ralink 802.11 bg WLAN" rev 2.00/0.01 addr 2
(…)

What did just happened? The dongle is not recognized and the generic USB driver is associated with it.

Digging a bit in the manuals I found that in rum manual on my OpenBSD do not have D-Link DWA-110 in the hardware list. In fact, the online manual is more up to date than the one in OpenBSD which is already at least two weeks old… So my dongle will be supported in next OpenBSD release.

So what? Can’t do anything to fix that?

Compiling the kernel

The problem here is just that OpenBSD do not know that D-Link DWA-110 works with the current rum driver.

It’s quite easy to change that, but it requires recompiling OpenBSD’s kernel and rebooting.

First, download kernel sources:

# cd /usr/src
# wget ftp://ftp.crans.org/pub/OpenBSD/4.4/sys.tar.gz
# tar zxvf sys.tar.gz

Then, add the relevant changes to the drivers source files and the USB devices list.

  • Add the following line in the file /usr/src/sys/dev/usb/if_rum.c in the vendors/products list:
{ USB_VENDOR_DLINK2,            USB_PRODUCT_DLINK2_DWA110 },
  • In /usr/src/sys/dev/usb/usbdevs in the D-Link products add:
product DLINK2 DWA110           0x3c07  DWA-110
  • In /usr/src/sys/dev/usb/usbdevs_data.h in the usb_known_products structure add:
{
    USB_VENDOR_DLINK2, USB_PRODUCT_DLINK2_DWA110,
    "DWA-110",
},
  • And in /usr/src/sys/dev/usb/usbdevs.h:
#define USB_PRODUCT_DLINK2_DWA110       0x3c07          /* DWA-110 */

Then compile the kernel and reboot (this can be a bit long, especially on a slow computer like my fit-PC, it was about half an hour):

# cd /usr/src/sys/arch/`arch -s`/conf
# config GENERIC
# cd ../compile/GENERIC/
# make depend
# make
# make install
# reboot

Now we can check the USB devices:

# usbdevs -dv
Controller /dev/usb0:
addr 1: full speed, self powered, config 1, OHCI root hub(0x0000), AMD(0x1022), rev 1.00
  uhub0
 port 1 addr 2: full speed, power 300 mA, config 1, 802.11 bg WLAN(0x3c07), Ralink(0x07d1), rev 0.01
  rum0
 port 2 powered
 port 3 powered
 port 4 powered

The rum driver is associated with the D-Link dongle.

We can see that it uses around 300 mA on a 5 V USB power source, so I assume that the dongle is using 1.5 W. My actual WIFI router consumes 4 W.

The fit-PC was consuming 3.7 W, now with the dongle plugged in and running it consumes 5.5 W, that’s 1.8 W for the dongle, not so far from the theory.

Anyway, it seems that DWA-110 was already in “-current”, so it should have been in November’s release.

Useful links: