The Asus Zenbook models UX31E/UX21E works very well with Ubuntu but does benefit from a little post installation configuration regarding. This page aims to describe the steps needed to fully enable all features of the Asus Zenbook. For the newer Asus Zenbook Prime models UX32/UX31A/UX21A, see the AsusZenbookPrime.

You can check what is your model with the command:

sudo dmidecode -s system-product-name

For further discusion and to seek help, see Ubuntu and the Asus Zenbook thread in the Ubuntu Forums. Please contribute valuable information to this page and create bug reports in launchpad if Ubuntu needs to fix something. Place links to those bug reports in the text below.

Asus Zenbook and Ubuntu

Especially power management and possibly touchpad depending on the touchpad vendor need manual configuration. Please either use the 12.04.1 LTS point release for installing, or if using the original 12.04 LTS installation media install all the updates available on your first run! There was a suspend related problem that was fixed only via updates.

Ubuntu 12.10 should also work generally well, but LTS versions of Ubuntu are recommended for normal users. Ubuntu 12.04.2 LTS point release in January 2013 will also include updated hardware support, optionally installable for current 12.04 LTS users. Ubuntu 13.04 is reported to also works properly.

Overview

Anything not mentioned here should work out of the box.

IconsPage/ok.png (works out-of-the-box) IconsPage/ok.png IconsPage/info.png (works, with remarks) IconsPage/warning.png (needs manual work) IconsPage/dont.png (won't currently work (completely)) IconsPage/question.png (not yet documented)

BIOS

The default BIOS works well. If needed, you can download the newest BIOS here:

UX21E: http://support.asus.com/download/download_item_mkt.aspx?model=UX21E

UX31E: http://support.asus.com/download/download_item_mkt.aspx?model=UX31E

You can update the BIOS from the BIOS menu itself, without any additional utilities.

Copy the BIOS file onto a memory-stick. Reboot and press the esc button to enter the BIOS menu. Then select "Enter Setup". From the Advanced tab, choose the Easy Flash option and then select the BIOS file to update.

LCD

Current Xorg-server uses a display resolution setting of 96dpi by default. UX31E Zenbooks have a resolution of ~138dpi. The default value of 96dpi makes fonts (and every thing else) look really small.

You can list the current setting with:

xdpyinfo|grep resolution

You can try use this option to override the default value:

xrandr --dpi 138/eDP1

You can add this line at the end of /etc/X11/xinit/xinitrc

Also these two bug reports should get more attention: https://bugs.launchpad.net/ubuntu/+source/xorg-server/+bug/589485 https://bugs.freedesktop.org/show_bug.cgi?id=41115

Only when dimension and resolution are set correctly after an Ubuntu installation, the remark in the overview can disappear.

SSD

The SDD works out-of-the-box but its performance can be optimised. You should follow the directions at http://www.howtogeek.com/62761/how-to-tweak-your-ssd-in-ubuntu-for-better-performance/ and change your /etc/fstab parameters by adding "discard,noatime" to the mount options for your SSD. In addition, it recommends changing your scheduler to "deadline". Further minimize SSD writes by mounting /tmp in RAM by adding the line "tmpfs /tmp tmpfs defaults,noatime,mode=1777 0 0" to the bottom of /etc/fstab. Finally you can enable TRIM by adding "rootfstype=ext4" to the 'GRUB_CMDLINE_LINUX_DEFAULT=' parameters line in /etc/default/grub and then running:

sudo update-grub

**Only enable TRIM this way if /root is on your SSD drive.**

Only when SSD optimisation is done automatically by Ubuntu, the remark in the overview can disappear.

Suspend, Hibernate, Shut-down and Reboot

Works perfectly out of the box, provided you have installed the 12.04.1 LTS updates.

Before the kernel update was added to 12.04 LTS, the following workaround was needed:

The kernel USB 3.0 (and sometimes 2.0) modules needs to be unloaded before suspending, and in kernels prior to 3.1 X also needs to disable/enable DPMS to get the screen back on resume. Save the following script as /etc/pm/sleep.d/20_zenbook (and make it executable):

IconsPage/warning.png If this workaround not used on an unfixed kernel, there have been reports that the laptop's memory controller setting may be screwed. After an incorrect suspend, if the corruption happens, many memory blocks starting with ~1G will be corrupt. Good way to see it is to use "memtest86+". The only way to fix controller setting is to open the case and plug off the battery. Please note that on this ultrabook the battery is not a user serviceable part and this could mean that by opening you can get your warranty void! If you start Windows or Linux with a corrupted controller, you will get system crashes or/and damaged file system. More info here: https://bugzilla.kernel.org/show_bug.cgi?id=42728 and https://bugs.launchpad.net/ubuntu/+source/linux/+bug/962798

For kernel 3.1 or newer (Ubuntu 12.04 LTS):

EHCI_BUSES="0000:00:1a.0 0000:00:1d.0"
case "${1}" in
    hibernate|suspend)
        # Switch USB buses off
        for bus in $EHCI_BUSES; do
            echo -n $bus > /sys/bus/pci/drivers/ehci_hcd/unbind
        done
        ;;
    resume|thaw)
        # Switch USB buses back on
        for bus in $EHCI_BUSES; do
            echo -n $bus > /sys/bus/pci/drivers/ehci_hcd/bind
        done
        ;;
esac

For 13.04 it works bu after wake up the login (unlock) dialog is a compete white rectangle. However, it does work but one cannot see the field to enter you password and the button to unlck the machine. This needs to be fixef before it can be reported that it works out of the box.

Keyboard

The keyboard works fine out of the box. If you do not want dead keys to be enabled, choose Engish (US) in

gnome-control-center region

All other three English (US) keyboards enable dead keys and provide no option of disabling dead keys in any other way. Usually the installation of Ubuntu will suggest you choose English (US) International. The compose key can be enabled in Options... under Compose key position. Left Win and Right Win are good candidates for this.

Multimedia keys

Toggle internal/external screen: Works.

Volume up, down, mute: Works.

Brightness up, down: Works.

NOTE: As of BIOS update 214 "Support Windows8 brightness control" is added. This means that the brightness buttons won't work in Ubuntu any longer. Brightness workaround 2 in the Zenbook Prime wiki works fine for changing brightness.

Switch screen on/off: Works.

Sleep Zz: Works.

Switch touchpad on/off: Works. (Where are the files in GNOME 3 for the OSD icons for? There is a small alignment error in of them.)

Switch Network connection on/off: Works.

Context menu key: Works.

Fn + C (Launch1): Works, but not bound by default.

Fn + Space (Launch6): Works, but not bound by default.

Fn + V (Web Cam): Works, but not bound by default.

Example binding:

sudo apt-get install cheese
gconftool-2 -s /desktop/gnome/keybindings/custom0/name -t string 'Web Cam'
gconftool-2 -s /desktop/gnome/keybindings/custom0/binding -t string 'XF86WebCam'
gconftool-2 -s /desktop/gnome/keybindings/custom0/action -t string 'cheese'

Fn+C/V/Space still does not work on 13.04 when the command above have been executed. How can this be fixed? Once fixed in a new Ubuntu installation, the remark on the icon of the section can be resolved.

Touchpad

Summary

Works fine out of the box, if you have Elantech made touchpad in your Zenbook. Use System Settings -> Mouse and Touchpad to change several settings including enabling two finger scrolling. Also three and four finger touch gestures work.

Works only in a basic way if you have Sentelic made touchpad in your Zenbook. Using a 3.5 kernel instead is recommended for optimal behavior - the Ubuntu 12.10 kernel will be available for 12.04 LTS users around the time 12.04.2 LTS will be released. current non-supported 3.5 backport snapshot version to 12.04 LTS here (note you only need the kernel)

Extra tweaking

This section is only for advanced users and requires usage of command line.

The Zenbook comes with one of two types of touchpads: Sentelic or Elantech. To determine which touchpad you have use this command:

cat /proc/bus/input/devices | grep -i pad

Sentelic Touchpad

Works out of the box. Currently multi-touch doesn't work, but see Bugs & Issues below for current status. To disable tap-to-click on boot, add the following to /etc/rc.local (and to the resume section of the suspend/resume script above, if necessary):

        echo -n 0x90 0x80 > /sys/devices/platform/i8042/serio4/setreg
        echo -n c > /sys/devices/platform/i8042/serio4/flags

Elantech Touchpad

Works out of the box. Multi-touch works in Ubuntu 12.04 LTS (kernel 3.2). Changes made in 3.2 were that the whole pad is the left button, there is thus no right button*. Click and drag is done by clicking anywhere on the pad and moving the finger. Right mouse is available as two-finger tap. Middle button is available as three finger tap.

* A revision to the synaptics driver restores click-pad functionality.

See here for the instructions. (See here for ubuntu versions previous to 12.04) Unfortunately the provided script is aged out because properties of the command xinput did changed. In order to provide a working script, copy and replace the following lines in your "enable-rightbutton.sh" script file (only last line did changed) :

#!/bin/bash

if [ $# -ne 1 ]; then
        echo "$0 <device id|device name>"
        exit 1
fi

i=0
while read label min delim max; do
        if [ $i -eq 0 ]; then
                minx=$min
                maxx=$max
        elif [ $i -eq 1 ]; then
                miny=$min
                maxy=$max
                break
        fi

        (( i++ ))
done < <(xinput list "$1" | grep Range)

left=`echo \($maxx - $minx\) / 2 + $minx | bc -l`
right=$maxx
top=`echo \($maxy - $miny\) \* 0.8 + $miny | bc -l`
bottom=$maxy

echo "Left = $left"
echo "Right = $right"
echo "Top = $top"
echo "Bottom = $bottom"

# Modification as per https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-input-synaptics/+bug/944961
xinput set-prop "$1" "Synaptics Soft Button Areas" $left $right $top $bottom 0 0 0 0

Check the ID of your pointer device by typing :

xinput

Change de execution right of your script, and execute it :

chmod a+x enable-rightbutton.sh
./enable-rightbutton.sh <ID>

With the 3.2 kernel, there is a very simple solution to the very low sensitivity problem. You can just use synclient to setup the sensitivity you want (and many other things).

Here is an example script from Aurélien Jacobs and Marcus Möller. You can save it e.g. as ~/bin/touchpad_settings and add it as Unity startup script using gnome-session-properties.

# higher sensitivity
synclient FingerLow=9 FingerHigh=12

# faster speed and acceleration
synclient MinSpeed=1.5 MaxSpeed=3.5 AccelFactor=0.1

# 2 fingers scroll (can be also enabled in System Settings)
synclient VertTwoFingerScroll=1 HorizTwoFingerScroll=1

# faster coasting
synclient CoastingSpeed=10

# enable tap to click (2 fingers for middle click, 3 fingers for right click)
synclient TapButton1=1 TapButton2=3 TapButton3=2

# continue dragging movement when reaching the edge of the touchpad
synclient EdgeMotionMinZ=30 EdgeMotionMaxZ=40 EdgeMotionMinSpeed=100 EdgeMotionMaxSpeed=400

In order to include more functionality on 3 or 4 fingers, report this on https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-input-synaptics/+bug/1174395

Alternatively

Only the first line is required to increase sensitivity. Other lines make the touchpad much more useful, but may not fit your needs. It is highly recommend to spend some time playing with synclient to find a setup that you really like (see 'man synaptics').

For kernel 3.3-rc5 on Ubuntu 12.04 LTS is Elantech drivers is working very good.

How can I disable touchpad on the buttons? In other words, when I move my fingers on the touchpad buttons I do not want the pointer to move. How an I configure this?

Wireless

Many users report that this works out of the box. Seems to work flawlessly, several megabytes per second. However, the hardware only supports 2.4GHz networks.

Additionally, in non-optimal conditions the connection starts easily to be flaky and slow. Debugging and development effort between a driver developer and users having the same wifi hardware as Zenbook occurred in June 2013 which lead to a fix that tremendously improves the wifi quality. Currently it's not yet integrated in a released kernel, but you may see the comments #63 and #65 in this bug report:

https://bugs.launchpad.net/ubuntu/+source/linux/+bug/971809

...on how to get the improved driver currently for the current running kernel.

The patches will be part of Linux 3.11 kernel (and will be possibly backported 3.10 etc)

USB Ethernet

Works out of the box. (kernel 3.2-rc7 and later, commit)

For older than 12.04 LTS kernels, the following patch was needed to be applied:

--- a/asix.c    2011-03-10 13:46:05.000000000 +0100
+++ b/asix.c    2011-11-26 09:39:48.000000000 +0100
@@ -829,7 +829,7 @@
        .ndo_do_ioctl           = ax8817x_ioctl,
        .ndo_set_mac_address            = ax8817x_set_mac_addr,
        .ndo_validate_addr              = eth_validate_addr,
-       .ndo_set_multicast_list = ax8817x_set_multicast,
+       .ndo_set_rx_mode        = ax8817x_set_multicast,
 };
 #endif
 
@@ -1522,7 +1522,7 @@
        .ndo_get_stats          = axusbnet_get_stats,
        .ndo_set_mac_address    = ax8817x_set_mac_addr,
        .ndo_validate_addr              = eth_validate_addr,
-       .ndo_set_multicast_list = ax88772b_set_multicast,
+       .ndo_set_rx_mode = ax88772b_set_multicast,
 };
 #endif

Reported at: http://bugs.launchpad.net/ubuntu/+source/linux/+bug/947723

Bluetooth

Works perfectly out of the box, provided you have installed all the 12.04 LTS updates.

Sound

Works perfectly out of the box, both internal and through HDMI.

Microphone

Internal mic

Works perfectly out of the box.

External mic

Works perfectly out of the box, provided you have installed all the 12.04 LTS updates.

Webcam

Ubuntu recognizes the camera out of the box. You can test it with Cheese and use that for taking pictures, series of pictures for stop motion and for making movies.

sudo apt-get install cheese

If you find video too dark when using video-conferencing apps (eg. Skype, Google Hangouts) install and run guvcview and adjust your brightness, contrast and gamma settings.

sudo apt-get install guvcview

If this option doesn't work you can also try entering

uvcdynctrl -s "Exposure, Auto Priority" 1

in the shell while Skype is running, to boost your gamma settings.

External Monitor

HDMI

HDMI works out of the box (with audio). If you wish to use the laptop display at the same time as an external display, you must plug in the HDMI cable after X has started (also after resuming from suspend).

VGA

VGA works out of the box. But the internal screen has only one resolution setting (1600x900). This can be changed by creating an xorg configuration file called e.g. 10_eDP1.conf and placing it in /usr/share/X11/xorg.conf.d. The file should have the following content:

Section "Monitor"
    Identifier      "eDP1"
    Modeline "1600x900_60.00"  118.25  1600 1696 1856 2112  900 903 908 934 -hsync +vsync
    Modeline "1440x900_60.00"  106.50  1440 1528 1672 1904  900 903 909 934 -hsync +vsync
    Modeline "1368x768_60.00"   85.25  1368 1440 1576 1784  768 771 781 798 -hsync +vsync
    Modeline "1360x768_60.00"   84.75  1360 1432 1568 1776  768 771 781 798 -hsync +vsync
    Modeline "1280x800_60.00"   83.50  1280 1352 1480 1680  800 803 809 831 -hsync +vsync
    Modeline "1280x768_60.00"   79.50  1280 1344 1472 1664  768 771 781 798 -hsync +vsync
    Modeline "1280x720_60.00"   74.50  1280 1344 1472 1664  720 723 728 748 -hsync +vsync
    Modeline "1280x600_60.00"   61.00  1280 1328 1456 1632  600 603 613 624 -hsync +vsync
    Modeline "1152x864_60.00"   81.75  1152 1216 1336 1520  864 867 871 897 -hsync +vsync
    Modeline "1024x768_60.00"   63.50  1024 1072 1176 1328  768 771 775 798 -hsync +vsync
    Modeline "800x600_60.00"   38.25  800 832 912 1024  600 603 607 624 -hsync +vsync

EndSection

Section "Screen"
    Identifier    "Default Screen"
    Monitor       "eDP1"
    SubSection "Display"

        Modes   "1600X900" "1440x900" "1366x768" "1360x768" "1280x800" "1280x768" "1280x720" "1280x600" "1152x864" "1024x768" "800x600"
    EndSubSection
EndSection

Note that if you want to use the internal and external screen at the same time the same rule applies as for the HDMI slot: plug in after system booted up. In case the user is "ready" pressing Fn+F8 before GRUB appears should solve the dual screen problem as well (according to reports on Ubuntu and the Asus Zenbook thread).

Ref.: https://wiki.ubuntu.com/X/Config/Resolution

SD card slot

Works perfectly out of the box.

Fan Control

Works perfectly out of the box.

Sensors

Sensors for temperature and fan speed work by default. However to (optionally) read the sensor data requires the package lm-sensors which is installed by:

sudo aptitude install lm-sensors
sudo tee -a /etc/modules <<-EOF
        coretemp
EOF

Power Saving Optimizations

Power saving on Asus Zenbook is pretty good out-of-the-box on Ubuntu 12.04 LTS, although not as perfect as it could be if Asus was shipping/certifying Ubuntu itself. This section gives a couple of hints to perfect it.

The biggest improvement - the Intel graphics RC6 power saving - is enabled by default in Ubuntu 12.04 LTS and is not needed to be specified separately anymore like in earlier Ubuntus. Likewise, Frame Buffer Compression is enabled by default in 12.04 LTS.

After enabling also the optimizations below, one should get circa 5W idle power usage with screen on but brightness to minimum, with WLAN connected.

Kernel parameters to use

Enabling ASPM saves a meaningful amount of power when idle according to powerstat. It's recommended. The pcie_aspm=force parameter is however required on Zenbook because the Zenbook BIOS gives Ubuntu wrong information. Therefore, add the following to the file /etc/default/grub, after the text quiet splash but within the same quotes:

pcie_aspm=force

There are a couple of optional kernel parameters which save some power and have not shown any problems with Zenbook, but are not enabled by default. Instead of the above, you may also use the following:

pcie_aspm=force drm.vblankoffdelay=1 i915.semaphores=1

After editing /etc/default/grub, make sure to run

sudo update-grub

Reported at: http://bugs.launchpad.net/ubuntu/+source/linux/+bug/1196183

ALPM

Enabling ALPM may save a meaningful amount of power when idle according to powerstat.

Read more and also the warnings on page ALPM. So far it has worked without problems for people, for example the Zenbook users, but has not been enabled by default in Ubuntu yet.

Reported at: http://bugs.launchpad.net/ubuntu/+source/linux/+bug/1196186

Bugs and issues

Not yet solved

Manually enabling USB 3 / XHCI runtime PM disables port

In "auto" suspend setting for the Fresco controller causes the USB3-port on the right to disable, although cellphones etc still can be charged with it.

Status: Awaiting kernel developer feedback. [add link!]

Improved support for Sentelic touchpad synaptics/multitouch

Reuben Bond has begun work on a synaptics driver for the Sentelic touchpad on https://github.com/ReubenBond/sentelic-multitouch but is awaiting further documentation from Sentelic regarding the multi touch.

Also, Oskari Saarenmaa has managed to get two finger scrolling working in his git repo at https://github.com/saaros/sentelic/, which Chris D aims to refine further in his fork at https://github.com/thaelim/sentelic.

Status: Work in progress.

Machine won't boot with UEFI

As of 21-Feb-2012 Grub2 seems to have problems booting Asus machines using UEFI, so use BIOS.

EDIT by JW (16-Dec-2013): ASUS uses Aptio firmware from American Megatrends. It appears the BIOS is case sensitive. It looks for the filename EFI/BOOT/bootx64.efi, but Ubuntu provides EFI/BOOT/BOOTX64.EFI. See https://bugs.launchpad.net/linux/+bug/1261465.

Solved

USB Ethernet dropping packages

On ux31e and ubuntu 12.04 64 bits, ASIX USB-Ethernet driver noticably slow, dropping packets and reporting RX errors. It shows errors on syslogs such as: asix 2-1:1.0: eth0: asix_rx_fixup() Bad RX Length 1808 asix 2-1:1.0: eth0: asix_rx_fixup() Bad Header Length

In order to include on new kernel, please report it as bug on http://bugs.launchpad.net/ubuntu/+source/linux/+bug/947723

Status: Bug fixed in Ubuntu 12.04 LTS updates

USB 2 / EHCI module needs to be unbound on suspend (Solved)

The module needs to be unbound or the machine won't suspend, bound on resume.

Status: Fixed in upstream kernels and Ubuntu 12.04 LTS kernel update.

https://bugzilla.kernel.org/show_bug.cgi?id=42728 https://bugs.launchpad.net/linux/+bug/962798

VT-d setting in BIOS (Solved)

Earlier VT-d feature was recommended to be disabled in Zenbook BIOS. To disable VT-d, reboot your Zenbook, holding down the Esc-button while it starts up. Locate the VT-d setting in the BIOS menus and toggle it to disabled.

Status: Fixed in Ubuntu 12.04 LTS update, VT-d has not shown problems, even if i915.semaphores is used.

pcie_aspm=force doesn't work (Solved)

Bug report at https://bugs.launchpad.net/ubuntu/+source/linux/+bug/962038

Status: Bug fixed in Ubuntu 12.04 LTS update

Machine check events (MCE) errors reported in kernel log

power limit notification MCE errors have been confirmed to be harmless (see here

Status: Specific issue noted above may be safely ignored.

Intel RC6 causes sudden shutdowns (Solved)

Kernel developers are aware and working on an issue with DMAR+RC6.

However, Zenbboks experience sudden shutdowns with RC6 on and Intel IOMMU off.

The most stable configuration is to enable semaphores and turn off VTd in BIOS, see above.

However, this needs to be properly fixed in the kernel once RC6 gets enabled by default.

Status: Solved in kernels 3.3-rc6 or newer, and Ubuntu 12.04 LTS update.

Kernel 3.2 KMS (Solved)

Commit dc22ee6fc18ce0f15424e753e8473c306ece95c1 in 3.2-rc1 causes the KMS to fail on the Zenbook graphics. 3.2-rc1 to 3.2-rc5 will therefore not boot without supplying kernel parameter i915.modeset=0, in which mode hardware acceleration is disabled.

Status: Solved in 3.2-rc6 with commit ed4a51842a9d9e618d4f4c31349b15b974dba5df

EHCI power savings preventing shutdown (Solved)

Status: Solved in kernels 3.0.11, 3.1.3 or newer.

Appendix: Older information

The following parts are kept for historical reasons.

  • New Zenbook users should install Ubuntu 12.04 LTS, even Beta. Ubuntu 11.10 users may find information still below.
  • Power saving scripts should be near optimal in 12.04 LTS without changes, and the other power optimization topics above are much more relevant for saving power.
  • With the Bluetooth fix in the kernel, most users shouldn't have a need to compile their own anymore, although of course that always can be done if wanted.

Ubuntu 11.10

This section includes special instructions for Ubuntu 11.10 that are not anymore needed in Ubuntu 12.04 LTS. If some section is not included here at all, the situation in 11.10 was similar to 12.04 LTS ie. most things work out of the box.

Suspend, Hibernate, Shutdown and Reboot

The kernel USB 3.0 (and sometimes 2.0) modules needs to be unloaded before suspending, and in kernels prior to 3.1 X also needs to disable/enable DPMS to get the screen back on resume. Save the following script as /etc/pm/sleep.d/20_zenbook (and make it executable):

IconsPage/warning.png If this workaround not used, there have been reports that the laptop's memory controller setting may be screwed. After an incorrect suspend, if the corruption happens, many memory blocks starting with ~1G will be corrupt. Good way to see it is to use "memtest86+". The only way to fix controller setting is to open the case and plug off the battery. Please note that on this ultrabook the battery is not a user serviceable part and this could mean that by opening you can get your warranty void! If you start Windows or Linux with a corrupted controller, you will get system crashes or/and damaged file system. More info here: https://bugzilla.kernel.org/show_bug.cgi?id=42728

For kernel 3.0 (Ubuntu 11.10):

EHCI_BUSES="0000:00:1a.0 0000:00:1d.0"
XHCI_BUSES="0000:03:00.0"
case "${1}" in
    hibernate|suspend)
        # Switch USB buses off
        for bus in $EHCI_BUSES; do
            echo -n $bus > /sys/bus/pci/drivers/ehci_hcd/unbind
        done
        for bus in $XHCI_BUSES; do
            echo -n $bus > /sys/bus/pci/drivers/xhci_hcd/unbind
        done
        ;;
    resume|thaw)
        # Switch USB buses back on
        for bus in $EHCI_BUSES; do
            echo -n $bus > /sys/bus/pci/drivers/ehci_hcd/bind
        done
        for bus in $XHCI_BUSES; do
            echo -n $bus > /sys/bus/pci/drivers/xhci_hcd/bind
        done
        # Hacky workaround to fix display after suspend, not needed for kernels 3.1 or newer
        export DISPLAY=":0"
        export XAUTHORITY=`ps aux | grep X | grep auth | awk '{sub( /^.*-auth / ,""); sub( / .*/,"");print }'`
        xset dpms force off
        xset dpms force on
        ;;
esac

Wireless (11.10)

Many users report that this works out of the box.

Many users have also reported bad signal strengths, or random disconnections with low signal levels in Ubuntu 11.10.

For some, frequent disconnections are shown in dmesg but are not visibly indicated. If you are getting poor wireless performance run dmesg to check or run tail -f /var/log/kern.log.

Possible workaround: run sudo killall wpa_supplicant after booting (see here)

Possible workaround: patch network-manager (see here)

Possible workaround: set the BSSID for your single access-point network (see here)

Possible workaround: remove network-manager and install wicd. You'll have to manually enable the tray icons in Unity (see here)

See this bug report also, and mark yourself as affected.

External microphone

This information only affects you if you're using earlier Ubuntu than 12.04 LTS, or have not installed all the 12.04 LTS updates.

By default, the headphone/microphone combo jack (TRRS) does not switch automatically to the external microphone when one is plugged in. Bug report here

To resolve this, add the following line to /etc/modprobe.d/alsa-base.conf

options snd-hda-intel model=laptop-dmic

(Note that if you already have a line starting with "options snd-hda-intel" then you should modify it to include the extra option.)

USB Ethernet

For Ubuntu 11.10 and earlier kernels, or if you still experience instability, download the asix-driver from http://www.asix.com.tw/FrootAttach/driver/AX88772B_772A_760_772_178_LINUX_Driver_v4.2.0_Source.zip

Once downloaded, the source needs to be compiled: First unzip the file.

Then download essentials:

sudo apt-get install build-essential linux-headers-`uname -r`

Next, go into the unzipped directory and compile the source as follows:

cd AX88772B_772A_760_772_178_LINUX_Driver_v4.2.0_Source

make

Install the just compiled module:

sudo make install

Finally load the module:

sudo modprobe asix

That's it. You should be able to connect using a wired connection now.

For 3.2 kernels, the following patch has to be applied:

--- a/asix.c    2011-03-10 13:46:05.000000000 +0100
+++ b/asix.c    2011-11-26 09:39:48.000000000 +0100
@@ -829,7 +829,7 @@
        .ndo_do_ioctl           = ax8817x_ioctl,
        .ndo_set_mac_address            = ax8817x_set_mac_addr,
        .ndo_validate_addr              = eth_validate_addr,
-       .ndo_set_multicast_list = ax8817x_set_multicast,
+       .ndo_set_rx_mode        = ax8817x_set_multicast,
 };
 #endif
 
@@ -1522,7 +1522,7 @@
        .ndo_get_stats          = axusbnet_get_stats,
        .ndo_set_mac_address    = ax8817x_set_mac_addr,
        .ndo_validate_addr              = eth_validate_addr,
-       .ndo_set_multicast_list = ax88772b_set_multicast,
+       .ndo_set_rx_mode = ax88772b_set_multicast,
 };
 #endif

Bluetooth

The bluetooth module is the Atheros AR3012, which requires loading a firmware before it can be used. For now, patching the kernel is required to recognize this module as AR3012 one.

The patch, and it's upstream progress, can be seen here: http://thread.gmane.org/gmane.linux.bluez.kernel/18801

More info: http://ubuntuforums.org/showthread.php?t=1867447&highlight=zenbook

Reported to Ubuntu kernel Team http://bugs.launchpad.net/ubuntu/+source/linux/+bug/916319

Power Saving Optimizations

Kernel parameters

To get the most power efficient system with longer battery life and cooler CPU temperatures, the configuration recommended so far is to disable VT-d in the BIOS and boot kernel 3.2-rc6 or newer with the boot options:

i915.i915_enable_rc6=1 i915.semaphores=1 pcie_aspm=force

RC6 and semaphores are disabled by default in final kernel 3.2, so they should be forced on. FBC should not be enabled and has not shown any improvements. LVDS downclock does not have any effect on the ZenBook since it's eDP.

To disable VT-d, reboot your Zenbook, holding down the Esc-button while it starts up. Locate the VT-d setting in the BIOS menus and toggle it to disabled.

Occasional shutdowns still occur but the cause it yet unknown - it might be the ath9k driver or something related to RC6 or ASPM. (This was fixed on kernel 3.3.0-rc6)

Note that this configuration trades off a bit of stability (unexpected shutdowns) for power efficiency. Without these RC6 settings, you will have less battery life etc., but the system will be perfectly stable (or so it seems).

possible patch: modifying the DSDT table seems to fully stabilize the system with RC6 active, acording to http://files.benesovi.eu/ux31e/ (This patch is not necessary since kernel 3.3.0-rc6) - Note: Patch does not solve the problem. system still shuts down sometimes (MM)

Power saving scripts

To apply all recommendations by powertop when on battery, put the following in a script (the name does not matter) in /etc/pm/power.d:

# Powertop tunables

case $1 in
        true)
                ## VM writeback timeout
                echo 1500 > /proc/sys/vm/dirty_writeback_centisecs

                ## Autosuspend for USB devices

                ### USB2.0-CRW (Generic)
                echo auto > /sys/bus/usb/devices/1-1.7/power/level

                ### Bluetooth USB Host Controller (Atheros Communications)
                echo auto > /sys/bus/usb/devices/1-1.8/power/level

                ## Runtime PM for PCI devices

                ### Atheros Communications Inc. AR9485 Wireless Network Adapter
                echo auto > /sys/bus/pci/devices/0000:02:00.0/power/control

                ### Fresco Logic Device 1009
                #echo auto > /sys/bus/pci/devices/0000:03:00.0/power/control
                # Currently this turns the USB3 port off, awaiting response

                ### Intel Corporation 6 Series/C200 Series Chipset Family
                ### 6 port SATA AHCI Controller
                echo auto > /sys/bus/pci/devices/0000:00:1f.2/power/control

                ### Intel Corporation 6 Series/C200 Series Chipset Family
                ### USB Enhanced Host Controller #1
                # echo auto > /sys/bus/pci/devices/0000:00:1d.0/power/control
                # Causes machine to freeze on shutdown, should work with kernels 3.0.11, 3.1.3 or newer

                ### Intel Corporation 2nd Generation Core Processor Family
                ### DRAM Controller
                echo auto > /sys/bus/pci/devices/0000:00:00.0/power/control

                ### Intel Corporation 6 Series/C200 Series Chipset Family
                ### MEI Controller #1
                echo auto > /sys/bus/pci/devices/0000:00:16.0/power/control

                ### Intel Corporation 6 Series/C200 Series Chipset Family
                ### High Definition Audio Controller
                echo auto > /sys/bus/pci/devices/0000:00:1b.0/power/control

                ### Intel Corporation 6 Series/C200 Series Chipset Family
                ### PCI Express Root Port 1
                echo auto > /sys/bus/pci/devices/0000:00:1c.0/power/control

                ### Intel Corporation 6 Series/C200 Series Chipset Family
                ### PCI Express Root Port 2
                echo auto > /sys/bus/pci/devices/0000:00:1c.1/power/control

                ### Intel Corporation 6 Series/C200 Series Chipset Family
                ### PCI Express Root Port 4
                echo auto > /sys/bus/pci/devices/0000:00:1c.3/power/control

                ### Intel Corporation 2nd Generation Core Processor Family
                ### Integrated Graphics Controller
                echo auto > /sys/bus/pci/devices/0000:00:02.0/power/control

                ## SATA link power management
                echo min_power > /sys/class/scsi_host/host0/link_power_management_policy

                # 50% screen brightness on battery
                echo 5 > /sys/bus/pci/devices/0000:00:02.0/backlight/acpi_video0/brightness

                # Set powersave CPU governor
                for i in 0 1 2 3; do
                    echo powersave > /sys/devices/system/cpu/cpu${i}/cpufreq/scaling_governor
                done
        ;;
        false)
                # 90% screen brightness on AC
                echo 9 > /sys/bus/pci/devices/0000:00:02.0/backlight/acpi_video0/brightness

                # Set ondemand CPU governor
                for i in 0 1 2 3; do
                    echo ondemand > /sys/devices/system/cpu/cpu${i}/cpufreq/scaling_governor
                done
        ;;
esac

exit 0

How to upgrade kernel

WARNING: This is a long operation and not usually recommended if you don't know what you're doing.

If you want to upgrade to the newest kernel, which improves power use, wlan and a number of other issues which are solved from time to time, do the following:

1. Set kernel options

Edit the kernel options in grub (using nano, vi, gedit or any other editor):

sudo nano /etc/default/grub

And change the line starting with GRUB_CMDLINE_LINUX_DEFAULT to:

GRUB_CMDLINE_LINUX_DEFAULT="pcie_aspm=force quiet splash"

save and run update-grub:

sudo update-grub

2. Download the kernel

Browse to http://kernel.ubuntu.com/~kernel-ppa/mainline/ to find the latest kernel (e.g. 'v3.2.2-precise', which is kernel version 3.2.2 and works also on Oneiric), and from that folder download 3 files:

linux-headers-<version>-<other stuff>_amd64.deb
linux-headers-<version>-<other stuff>_all.deb 
linux-image-<version>-<other stuff>_amd64.deb

3. Install the kernel

Open a terminal and change to the directory where you downloaded these files, and run

sudo dpkg -i linux-*.deb

(if you have older linux-*.deb files laying around in that folder, you should specify the new files explicitly instead of using wildcards). Reboot to run the new kernel. You can verify the kernel version from the grub menu selection, or by running

uname -a

How to recompile kernel for Ubuntu 12.04 LTS and ux31e

1.Install some tools to compile: Code:

sudo su -
apt-get install fakeroot build-essential
apt-get install crash kexec-tools makedumpfile kernel-wedge
apt-get build-dep linux-image-$(uname -r)
apt-get install git libncurses5 libncurses5-dev libnewt-dev
exit

2. Create some directory somewhere where you'd like to store the source files you'll want to compile, I'm calling it "kernel". Cd into that directory and get the kernel sources via git. Code:

git clone git://kernel.ubuntu.com/ubuntu/ubuntu-oneiric.git  source

3. Download kernel last source from http://www.kernel.org/ and uncompress it.

http://www.kernel.org/pub/linux/kernel/v3.0/testing/linux-3.3-rc5.tar.bz2

4. Donwload felsi's bluetooth patch

wget http://fenski.pl/zenbook/bluetooth.patch

and apply patch on 3.3-rc5 folder.

patch -p1 < ./bluetooth.patch

note that within the patch the paths are still linking to kernel version 3.2.5. You have to enter the respetive path to where you have downloaded and unpacked the kernel (e.g. linux-3.3-rc6/drivers/bluetooth/).

5. Now you'll actually have to compile the source. This takes commands: Code:

make menuconfig
fakeroot make-kpkg clean
fakeroot make-kpkg --jobs=4 --initrd --append-to-version=-ux31custom --revision=`date +'%Y%m%d%H%M'` kernel_image kernel_headers modules_image

6. the compiled kernel packages will be in the parent folder. So make a "cd .." and install: Code:

sudo dpkg -i linux-*.deb

7. Just for safety, update grub Code:

sudo update-grub

AsusZenbook (last edited 2014-01-15 15:09:03 by wim-glenn-w)