Archive for the ‘Linux’ Category

Canon i-Sensys MF8280Cw on 64bit Debian

Friday, October 9th, 2015

I’ve gotten my hands on a Canon i-Sensys MF8280Cw multifunction colour laser printer, in part because I noticed that Canon has published CUPS drivers for Debian (that is Ubuntu), so it should work.

It also does work, but I had to jump a few hoops.

The driver is available from here (Italian site).

Running Debian testing on amd64, I downloaded the 64bit driver. Unpacking the file gives you two DEB files to install: ‘cndrvcups-common’ and ‘cndrvcups-ufr2-uk’ which installed without a hitch.

Opening the CUPS admin interface, the printers were installed in a second. I used the wifi link, and the printer was autodetected.

Printing a test page from within CUPS went fine. At least CUPS thought it went fine, as there were no error messages or anything. Document printed.

The printer didn’t agree, though. It just emitted a long beeeeep and printed nothing. There’s a work log in the printer, and it stated that each and every print job from CUPS gave an error #822. Printing over wifi from Android or iOS worked fine.

So printer works, wifi link works, and apparently the CUPS driver works, only nothing is printed.

So Google to the rescue, but also not. There was preciously little to find. In the end I ended up with some hints that there might be some 32bit (i386) parts of the driver, that wouldn’t work without the i386 libraries installed.

I ran a command like this on both installed packages:

dpkg -L cndrvcups-ufr2-uk | while read f; do ldd "$f" 2>/dev/null | grep -v 0x | grep -v "not a dynamic executable"; done

but it gave no errors.

I installed the i386 packages

libc6:i386
libc6-i686:i386
libstdc++6:i386

And the still no prints.

I ran the command checking for unresolved linker dependencies again, and lo and behold, it said libxml2 was missing. I installed that from the i386 architecture, restarted CUPS, turned the printer off and on again, and it printed.

So it does work, but not easily.

To summarise I have done this:

dpkg --add-architecture i386
aptitude update
aptitude install libc6:i386  libc6-i686:i386 libstdc++6:i386 libxml2:i386
/etc/init.d/cups stop; /etc/init.d/cups start

 

 

Cpu Frequency and Gnome Power Manager

Thursday, February 12th, 2009

I’ve installed Debian with Gnome on my new Asus EeePC 1000H, and for some reason the Gnome Power Manager preferences wouldn’t let me decide on what cpu frequency scaling governor I wanted to use.

I’m trying to squeeze as much time as I can out of the battery, so I wanted it to be “powersave” when on battery.

The options weren’t there.

After a bit of digging I fould a gconf key,

/apps/gnome-power-manager/ui/cpufreq_show

which, when set, causes the options to be shown.

It’s a bit annoying with all these hidden preferences but at least we have gconf-editor 🙂

Bluetooth Audio Headset

Wednesday, February 11th, 2009

I have a Philips SHB6100 bluetooth headset which I have only used with my mobile phone.  A long time ago I tried getting it to work with Debian, but it was too much work for too little.

Today I tried again, and things has changed quite a bit. I had it working in less than five minutes.

The explanations are here: http://wiki.bluez.org/wiki/HOWTO/AudioDevices.

First I put the headset in pairing mode, which is done by pressing the “on” button continuously until the led blinks red/green alternately.

Then the command “hcitool scan” will reveal the BT address of the headset. It looks like a MAC address.

Add this to your ~/.asoundrc:

pcm.bluetooth {
   type bluetooth
   device 00:11:22:33:44:55
}

Replace the address with what “hcitool scan” showed for the headset.

This is it.

Play an song with

mplayer -ao alsa:device=bluetooth yoursong.mp3

and the Gnome bluetooth applet should prompt you for a pairing code for the headset, which is “0000” for the Philips headset.

I use Banshee for my music, and to get Banshee to use the headset, first close it down, then run this command:

gconftool -t string -s /system/gstreamer/0.10/default/musicaudiosink "alsasink device=bluetooth"

and restart Banshee. It will now play to your headset.

The only thing missing now is an easy GUI way for those who don’t want to edit configuration files. In my Gnome setup I have a “System | Preferences | Multimedia Systems Selector” but it doesn’t handle the music player setup or anything bluetooth at all.

Asus Eee Pc 1000H with Debian Lenny (testing)

Wednesday, February 11th, 2009

I have bought an Asus EeePc 1000H which is one of the new popular netbook – a very small and light weight notebook.

I chose the Asus EeePc 1000H for several reasons:

  • I travel a lot, often by motorcycle and kayak,  and need something compact and lightweight for mail, internet, blog updates and social networks;
  • initially I wanted the EeePc 901, but its being discontinued and it costs almost the same as the 1000H, which has a hard disk and a larger keyboard;
  • though delivered with Windows XP, the hardware is quite Linux friendly and almost identical with the 901 which were sold with Linux;
  • its small and cute (even my wife says so).

The specs are:

  • Intel Atom N270 dual core CPU,
  • Intel Mobile 945GME chipset,
  • 1 Gb DDR2 667MHz RAM upgradable to 2Gb,
  • 160 Gb SATA harddisk,
  • Six-cell LiOn battery 6580 mAh,
  • 10″ WVGA display at 1024×600,
  • ElanTech touchpad,
  • RaLing RT2860 wireless network adapter – IEEE 802.11bgn,
  • Attansic Technology L1 Gigabit network adapter,
  • Broadcom BT-253 internal USB bluetooth adapter,
  • Alcor Micro SD/MMC Card Reader,
  • Genesys Logic USB 2.0 webcam 1.3Mpixel.

It is a fairly small laptop, measuring 27×19×3cm and weighing 1.45kg which is a bit more that I had hoped (the 901 is less than 1kg) but it is OK, as I won’t have to bring an extra USB disk for additional storage.

Conclusions

I have installed Debian testing/lenny on it, through the Debian Eee Pc projects installer. It is a specialised installer which does a slightly different installation and configuration, but the resulting system is a normal Debian system.

Most parts of the netbook work immediately with little or no manual configuration after a base install, but there are a few parts that doesn’t or that are a bit unstable. Most of these seem to have a solution on the way.

An install through the Debian Eee Pc installer of Debian Testing (lenny) with a Linux 2.6.26 kernel leaves these parts non-functional:

  • Front microphone doesn’t work (should be fixed in the latest ALSA release, included ibn Linux 2.6.27);

and these only partly functional:

  • Wireless network driver only works with certain setups (for me, open network and WPA/PSK work, WEP doesn’t);
  • Touchpad is working with a generic driver which doesn’t support all the functions of the hardware;

and these require an extra effort to get fully functional:

  • Keyboard hotkeys (editing a configuration file)

Installation

The installation procedure was more or less as specified on the Debian Eee Pc Wiki.

The computer came with Windows XP preinstalled and with the disk partitioned in a particular way. Since I’ve paid for that Windows installation, I’d like to retain it in case I should need it later.

The harddisk was initially partitioned like this:

  1. Windows XP system 75 Gb (type 7 – HPFS/NTFS)
  2. User data 60 Gb (type 7 – HPFS/NTFS)
  3. Windows accelerated boot 8Gb (type 0x1c – Hidden W95 FAT32)
  4. EFI partition for the BIOS “Boot Booster” 40Mb (type 0xef)

The partitions 1 and 4 would be needed for Windows XP and the BIOS, and I wasn’t sure what partition 3 was for, so I decided to leave it untouched. I think it is for an accelerated boot of Windows XP where they make a hibernation type snapshot at boot time which can then be used at subsequent boots to speed up things.

For Linux I would need a root, a swap and a user data partition, so I decided on this partitioning scheme:

  1. Windows XP system 10 Gb (type 7 – HPFS/NTFS)
  2. Extended partition 125Gb (type 5 – Extended)
    1. Linux root 8Gb (type 83 – Linux)
    2. Linux swap 1Gb (type 82 – Linux swap)
    3. Linux home 116Gb (type 83 – Linux)
  3. Windows accelerated boot 8Gb (type 0x1c – Hidden W95 FAT32)
  4. EFI partition for the BIOS “Boot Booster” 40Mb (type 0xef)

Starting the Debian Eee PC installer was quite easy. I downloaded the image, copied it to an SD card, inserted it into the card reader and booted while pressing ESC so the BIOS asked which device to boot. The installer is the normal Debian lenny installer, only with a payload of special modules for the EeePc specific hardware,  which for now include both wired and wireless network adapters and ACPI functions.

Before starting it is a good idea to disable “Boot Booster” and “Quick Boot” in the BIOS. Otherwise it is quite likely the system will just launch you into Windows XP so fast you have little time to press ESC for the boot device menu or F2 to enter the BIOS.

I had to start the installer several times to shrink and resize the Windows XP partitions and setup my own partitioning scheme as shown above.

The first several boots into the Debian installer was to shrink and resize the Windows XP installation, and setup my partition scheme. I repeatedly took the installer up to the point where it wants you to partition the harddisk, then pressed Alt-F2 to get a shell. The first time I used ntfsresize to shrink the Windows XP NTFS filesystem from 75Gb to 10Gb. Second time was to resize the actual Windows XP partition using fdisk, followed by a boot to Windows XP to make sure the installation was still bootable. Then the third time to setup the Linux partitions, and only afterwards did I let the installer continue and do the actual installation.

The Debian installer is so easy these days its almost boring. I only had to answer a few questions, enter some passwords and select what I wanted of software on the computer. I let it install all of the Gnome desktop environment, which was probably a mistake, since I had a bit of work afterwards reducing it to only the parts I actually wanted.  I have no use for Windows terminal services or remote desktop systems, or all the CD/DVD ripping and mastering software I had installled automatically.

Hardware walk-through

CPU – Intel Atom N270 1.6GHz works out of the box with both cores available and CPU frequency scaling activated.

Disk – the SATA disk works as expected.

Sound – works except for the front microphone, which is supported in the next version of ALSA, included in Linux 2.6.27.

SD card reader – works.

USB – works out of the box.

Wired network – the Attansic Technology L1 Gigabit network adapter uses an “atl1e” driver which works without any problems noted.

Wireless network – works partially with the rt2860sta driver included in the Debian Eee Pc install. It works for me with a WPA/PSK access point, and with an open network, but not without some problems. The driver drops the association at high throughput and subsequently fails to re-associate to the access point without a manual intervention. With a WEP setup it associated with the access point,  but failed consistently to get an IP address from the DHCP server. There is no hardware kill switch.

Bluetooth – the internal USB adapter works out of the box. There is not hardware kill switch.

ACPI – this is governed by a special eeePc driver included in the Debian Eee Pc installer. It seems to support everything: power switch, lid, extra keys, battery, cpu, suspend states etc.

Video out – not yet tested

Video – Intel Mobile 945GME chipset, which works with X.org. It is automatically configured by the Debian Eee Pc install, so X windows works immediately, compositing included.

Touchpad – works partially. It is currently controlled by a generic driver, which doesn’t support all the functions of the hardware. The touchpad works as such, with tapping and the two buttons below it. The middle mouse button can be activated by a two finger tap, and a scroll wheel simulated by a two finger drag. A three finger tap works as a right button click, but it is almost impossible to get right on the small touchpad.

Extra keys – works with initialisation – see later “Hotkeys”

Suspend – both suspend and hibernate works through the Gnome Power Manager. I have uswsusp installed, but I don’t know if the Gnome Power Manager uses the kernel suspend functions or uswsusp. Sometimes bluetooth disappears after a resume, but I still haven’t figured out why. You need to belong to the “powerdev” group to get full Gnome Power Manager functionality.

Webcam – the necessary Video4Linux drivers are automatically installed, and the camera seems to work. I can get mplayer to show me live video from it.

Keyboard – while it has nothing to do with Linux, I do have a few grievances about the keyboard. It has at least two deficiencies. While is has a nice and usable size, the right shift key is placed in a very annoying position, to the right of the “up” arrow key, which I alway hit by mistake. Also, the shift lock key has no status indicator anywhere, so you cannot see if shift lock is on or off, except trying to type something.

X Windows

Basic X.org configuration was automatic.

The X.org server uses the “intel” driver for the Intel 945GME graphics chip set. It is by default set up with EXA acceleration, but the Debian Eee Pc wiki states that using XAA might be better, and my experience confirms it. It feels quite a bit snappier with XAA, especially when scrolling in Firefox.

DRI was configured automatically.

The touchpad it is an Elantech touchpad but it is not recognised as such by the kernel. It detected as a “ExplorerPS/2”, not as a proper touchpad. The funny thing is, however, that the touchpad still works to some degree. It reacts to movement and taps, there is a scroll wheel area on the right side of it, and a two finger tab becomes a middle click. A three-finger tap becomes a right click but it is very hard to reproduce reliably. There seems to be a driver for the touchpad in the working, but it’s currently only semi-functional. I haven’t delved deeper into this, as it does work.

Compiz was only an “aptitude install compiz” away. All the necessary prerequisites were taken care of by the Debian Eee Pc installer.

Hotkeys

The keyboard has some special keys, which are handled by a special eeepc ACPI module.

I had to edit the /etc/default/eeepc-acpi-scripts file to get the sound volume keys to work properly.  I needed to set the variables

VOLUME_LABEL='Master'
HEADPHONE_LABEL='Headphones'

Apparently the default setup is for the latest Alsa release, but not the one used by the 2.6.26 kernel.

Major outstanding issues

  • Front side microphone is not working,
  • Touchpad not fully supported.

Links

Suspend / hibernate problems in new Debian Testing install

Thursday, January 31st, 2008

MenuI’ve had quite a bit of problems getting suspend and hibernate to work in Gnome on my new Zepto Znote 3215W.

The problem was that Gnome Power Manager simply refused to suspend or hibernate.

The actual functions of suspend or hibernation works great, with a minimum of fiddling. The Gnome Power Manager comes with a handful of wrapper scripts around the uswsusp programs s2disk and s2ram. The pm-hibernate script works out of the box from the command line as root. The system resumes correctly afterwards.

The laptop isn’t on the whitelist for s2ram, but it works with the –force flag, and that is easily automated by creating a file /etc/pm/config.d/s2ram with the line

S2RAM_OPTS=--force

and making the file executable. That will cause the pm-suspend script to pass –force to s2ram as default. Again, the system resumes correctly.

The problem was that when I tried to suspend or hibernate though the context menu of the Power Manager applet, I immediately got a dialog with the text:

Sleep Problem
Your computer failed to suspend.
Check the help file for common problems.

It happened so fast that no attempt at suspending could possibly have been made.

One track I followed was that the applet uses HAL to do the actual suspend/hibernate and HAL will only do that if it believes the laptop is capable of it. That can be checked by running the command:

lshal | grep power_management

I currently, after I solved my problems, get this output:

$ lshal | grep power_management
  power_management.acpi.linux.version = '20070126'  (string)
  power_management.can_hibernate = true  (bool)
  power_management.can_suspend = true  (bool)
  power_management.can_suspend_hybrid = true  (bool)
  power_management.can_suspend_to_disk = true  (bool)
  power_management.can_suspend_to_ram = true  (bool)
  power_management.is_powersave_set = false  (bool)
  power_management.quirk.none = true  (bool)
  power_management.type = 'acpi'  (string

To get HAL to recognise the laptop I have made a file
/usr/share/hal/fdi/information/10freedesktop/20-video-quirk-pm-zepto.fdi
with this content:

<?xml version="1.0" encoding="ISO-8859-1"?> <!-- -*- SGML -*- -->
<deviceinfo version="0.2">
  <device>
    <match key="system.hardware.vendor" prefix="ZEPTO">
      <match key="system.hardware.product" string="ZNOTE">
             <merge key="power_management.quirk.none" type="bool">true</merge>
      </match>
    </match>
  </device>
</deviceinfo>

and restarted HAL and logged out and in again. That should, as far as I have understood, whitelist the laptop in HAL by affirming that pm-suspend doesn’t need any additional options to work.

It didn’t make any difference, though. I still got the error message when trying to suspend from the applet’s context menu.

At this point I was about to give up. One last search on google brought up something new, however. There’s another level of permission checks involved, which is specified in the file /etc/dbus-1/system.d/hal.conf. In this file I found, among many other things, these lines:

  <!-- This configuration file specifies the required security policies
       for the HAL to work. -->

and

  <!-- Debian groups policies -->
  <policy group="powerdev">
    <allow send_interface="org.freedesktop.Hal.Device.SystemPowerManagement"/>
    <allow send_interface="org.freedesktop.Hal.Device.LaptopPanel"/>
  </policy>

which seem to indicate that I need to belong to the “powerdev” group to be able to use these functions.

I added myself to the group, logged out, logged in again, and everything worked.

This is the kind of experience that leaves you feeling a bit stupid. Totally unjustified, because I’m not to blame, but after having spend so much time looking in other directions, the solution is so simple.

Now the problem is solved, I hope to be able to use many of the useful functions of the Gnome Power Manager, such as automatic hibernation in low power situations.

I have notices another little thing that has changed. When I used the Fn-F4 and Fn-F5 keys to adjust the backlight on the display, I got a little on screen display, but it didn’t do anything, it just sat there. After I’m in the “powerdev” group, the on screen display actually shows an indicator of how the backlight is changed.

Zepto Znote 3215W with Debian Testing/lenny

Monday, January 28th, 2008

Zepto Znote 3215WAs my old Asus M2N laptop got older and older, and for some reason slower and slower, I decided to buy a new one. I ended up gettinng a Zepto Znote 3215W with a few customisations. There were several reason for this choice:

  • Zepto has very competive prices,
  • Zepto will sell laptops without an OS preinstalled – no involuntary Microsoft tax,
  • laptops can be customised as you want them,
  • and then this quote: “Works with Ubuntu Linux. 3215W is tested and will work together with Ubuntu Linux 7.10 beta, Out-of-the-box. For Wifi you will need to use the Intel Pro/Wireless 4965 netcard.”

The specs of mine are:

  • Intel Centrino “Santa Rosa” chipset
  • Intel Core2 Duo CPU T5450 @ 1.66GHz (*)
  • 2 Gb DDR2 800MHz RAM (*)
  • 120 Gb SATA harddisk 7200 rpm (*)
  • DVD-RW DL drive (*)
  • 15.4″ WXGA “Crystal Clear” display at 1280×800
  • Intel GMA X3100 graphics chipset
  • Intel Pro/Wireless 4965AGN wireless network adapter (*)
  • Broadcom NetLink BCM5906M network adapter
  • Broadcom internal USB bluetooth adapter (*)
  • Ricoh Firewire adapter
  • Ricoh SD/MMC card reader

The items marked with (*) are where I have asked for changes or additions to the default configuration.

It is a fairly large laptop, measuring 36×27×4cm and weighing 2.8kg which is OK for the kind of semi-stationary work I do currently.

Conclusions

Most parts of the laptop work immediately with little or no manual configuration on a Debian Testing install, but there are several parts that doesn’t. Most of these seem to have a solution on the way. Zepto states that the laptop is fully Ubunto 7.10 compatible, but not everything went that smooth with Debian.

An install of Debian Testing (lenny) with a Linux 2.6.23 kernel leaves these parts non-functional:

and these only partly functional:

  • X server sometimes fails to restore textmode correctly
  • Touchpad not recognised but it still usable
  • ACPI works only partially
  • Minor issues with sound and headphones

and these require an extra effort to get fully functional:

  • Compiz window manager
  • SD/MMC card reader
  • Keyboard hotkeys

(more…)

Google Calendar in the Gnome panel

Thursday, December 20th, 2007

My calendar on the desktopI haven’t really used the calendar part of the little clock I have in my gnome panel, since its integrated with Evolution, and I use Thunderbird for my mail and Google Calendar for my calendar.

The other day I decided to try out Evolution again—after all, you never know—and I subscribed to some of my calendars from Google Calendar, and they appeared automatically in the panel calendar.

Now I can have my calendars on my desktop 🙂

The calendars show up even without Evolution, because they are handled by the Evolution Database Server which can be used independently of Evolution.

Mass upload to WordPress

Wednesday, November 21st, 2007

I often make photo entries on my other non-technical blog, and it is such a pain having to upload photo after photo in two sizes. Yesterday I discovered the Upload Unzipper which implements uploads of zip-files which are then unpacked on the server and treated as individual uploads. Fantastic time saver.

Comment spam

Wednesday, November 21st, 2007

I just went through the comment moderation queue on this blog, and there were four (4) valid comments out of 385 comments. Spam is such a pain that I can’t even imagine how it would be without comment moderation activated.

Compiz 0.5 in Debian unstable

Friday, June 15th, 2007

Compiz 0.5 arrived in unstable a while ago. I usually run testing, but the Compiz 0.3.6 I used came from experimental. Unfortunately, an installation of Compiz 0.5 from unstable on a testing system would update libc6 and hence almost all of the system to unstable. I waited.

Compiz in actionThe libc6 update passed into testing recently, and I upgraded Compiz from unstable afterwards. Disaster.

Initially, Compiz started, but all windows were empty, blank, void. The windows were there, I could click on links in a browser window, but I could see nothing but a blank window. Pop-up menus didn’t even display, though they too were there, but invisible.

After much experimenting and searching and reading fora and blogs (using a Metacity session), I discovered that I needed to update the the latest version of xserver-xorg-core from unstable. That solved the blank window problem.

Now I could see the content of my windows. It is actually quite nice, once you’ve tried the opposite 🙂

The windows had no decorations, however. No titlebar, no borders, but naked and ashamed.

This was a bit harder to solve, but in the end I discovered that the package “libdecoration0” had version 0.3.6, so it had not been upgraded for some reason, probably due to an unversioned depends rule in the Compiz packages.

A manual upgrade of libdecoration0 solved the problem, and now Compiz 0.5 works very well on my little laptop.