Results 1 to 10 of 114

Thread: Asus U43JC

Threaded View

  1. #1
    Join Date
    Aug 2006
    Beans
    87

    [Howto] Asus U43JC

    Ubuntu 12.04 Precise Pangolin on an Asus U43JC-X1

    Edit: Updated for Precise! This will be edited as known issues are solved.

    Automatic Nvidia Power Management

    Let's begin by installing bumblebee to handle Nvidia power management as well as Optimus:

    Code:
    $ sudo add-apt-repository ppa:bumblebee/stable
    $ sudo apt-get update
    $ sudo apt-get install bumblebee
    This makes it so the nvidia card will be disabled automatically on boot (and remain so even after resume from standby), and therefore will not consume any power or generate additional heat. To test if it worked, reboot, unplug the laptop from the power outlet and do a:

    Code:
    $ cat /proc/acpi/battery/BAT0/state
    The "Present rate" line should be around 13500 mW. With WiFi off, low screen brightness, and no USB devices attached, it should get as low as 11500 mW!

    To run opengl applications manually using Nvidia's binary driver, execute:

    Code:
    $ optirun <application>

    Touchpad Fixup

    To configure the touchpad beyond what is available in Gnome configuration, we will use the hotplug-command hook available in the new gnome-settings-daemon. Start off by creating this script somewhere in your executable path, such as $HOME/bin:

    $HOME/bin/touchpadconf
    Code:
    #!/bin/bash
    #
    # This script is an example hotplug script for use with the various
    # input devices plugins.
    #
    # The script is called with the arguments:
    # -t [added|present|removed] <device name>
    #	   added ... device was just plugged in
    #	   present.. device was present at gnome-settings-daemon startup
    #	   removed.. device was just removed
    # -i <device ID>
    #	   device ID being the XInput device ID
    # <device name> The name of the device
    #
    # The script should return 0 if the device is to be
    # ignored from future configuration.
    #
    
    args=`getopt "t:i:" $*`
    
    set -- $args
    
    while [ $# -gt 0 ]; do
    	case $1 in
    	-t)
    		shift;
    		type="$1"
    		;;
    	 -i)
    		shift;
    		id="$1"
    		;;
    	 --)
    		shift;
    		device="$@"
    		break;
    		;;
    	*)
    		echo "Unknown option $1";
    		exit 1
    		;;
    	esac
    	shift
    done
    
    retval=0
    case $type in
    	added|present)
    		if [ "$device" == "ETPS/2 Elantech Touchpad" ]; then
    			xinput set-prop $id "Synaptics Tap Action" 0, 0, 0, 0, 1, 2, 3
    		fi
    		;;
    	removed)
    		;;
    	*)
    		retval=1
    		;;
    esac
    
    # All further processing will be disabled if $retval == 0
    exit $retval
    Now make it executable:

    Code:
    $ chmod a+x $HOME/bin/touchpadconf
    Edit the "Synaptics Tap Action" line to whatever you like - that's where the actual configuration is set. Refer to "man synaptics" for possible keys/values.

    Now execute the following to set the hook. It'll be executed whenever g-s-d is called, be it at startup, after resume, of when you plug/unplug a device. "touchpadconf" refers to the script you created above. If it's not in your path, change it to include absolute path information.

    Code:
    $ gsettings set org.gnome.settings-daemon.peripherals.input-devices hotplug-command touchpadconf
    Fix Suspend

    We have to unbind the USB buses manually before suspending. Create /etc/pm/sleep.d/20_custom-asus-u43jc:

    Code:
    #!/bin/sh
    
    EHCI_BUSES="0000:00:1a.0 0000:00:1d.0"
    XHCI_BUSES="0000:04:00.0"
    
    case "${1}" in
        hibernate|suspend)
            # Switch USB buses off
            for bus in $EHCI_BUSES; do
                echo -n $bus | tee /sys/bus/pci/drivers/ehci_hcd/unbind
            done
            for bus in $XHCI_BUSES; do
                echo -n $bus | tee /sys/bus/pci/drivers/xhci_hcd/unbind
            done
            ;;
        resume|thaw)
            # Switch USB buses back on
            for bus in $EHCI_BUSES; do
                echo -n $bus | tee /sys/bus/pci/drivers/ehci_hcd/bind
            done
            for bus in $XHCI_BUSES; do
                echo -n $bus | tee /sys/bus/pci/drivers/xhci_hcd/bind
            done
            ;;
    esac
    And make it executable:

    Code:
    $ sudo chmod a+x /etc/pm/sleep.d/20_custom-asus-u43jc

    Fix Hibernation

    To fix hibernation, simply create /etc/pm/config.d/hibernate_mode with the following contents:

    Code:
    HIBERNATE_MODE="shutdown"
    Reboot, and try it out. It is kinda slow either hibernating or resuming, so be patient. This is one of the reasons I plan to get a fast SSD some time in the near future.


    Fix CPU Frequency Scaling

    Sometimes the BIOS limits the available CPU frequency to just 1.2GHz, either when on the power cord on on the battery. Since recent kernels respect this limit (a feature not present in Ubuntu 10.04, for instance), the workaround is to tell the kernel to ignore it.

    To check if you have the same problem, do:

    Code:
    $ cat /sys/devices/system/cpu/cpu0/cpufreq/bios_limit
    If it's anything less than 2400000, you got the same problem. The fix is to add "processor.ignore_ppc=1" as a boot parameter to the kernel. To do so, edit /etc/default/grub and modify the GRUB_CMDLINE_LINUX_DEFAULT parameter so it reads:

    Code:
    GRUB_CMDLINE_LINUX_DEFAULT="quiet splash processor.ignore_ppc=1"
    Then update grub.cfg:

    Code:
    $ sudo update-grub
    Reboot.


    Known Issues

    * No WiDi out.
    Last edited by arbrandes; May 25th, 2012 at 05:21 PM. Reason: Updated for 12.04.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •