MacBook 5,2 and Ubuntu 10.04 (Lucid)
This page aims to describe the steps needed, to fully enable all features of the 5.2 Withe Macbook (release date: early 2009) when using Ubuntu 10.04, Lucid. You can check here if you own this model: on wikipedia, on apple.com
You can find out what model you have in OSX, System Profiler
If you have a different model, please go https://help.ubuntu.com/community/MacBook and find the right wiki.
Overview
Anything not mentioned here probably already works out of the box. If not, please refer to the Ubuntu Apple Users forum.
(works out-of-the-box)
(works, needs a little job)
(works, with remarks)
(won't work)
(not yet documented)
Basic Installation Instructions
Common things about installing and maintaining Ubuntu on Intel-based Macs: Intel CPU-based Macintosh Generic Installation Instructions
Wireless (AirPort)
To enable wireless you need to install the restricted Broadcom STA driver. Open System -> Administration -> Hardware Drivers and choose Broadcom Sta.
Desktop Effects (Compiz)
You probably want to enable the proprietary graphics driver. Go to System -> Administration -> Hardware Drivers and choose the NVIDIA accelerated graphics driver (latest version).
Trackpad
..now testing..
Keyboard functions
..now testing..
Adjusting the screen brightness works out of the box with the default "nv" graphics driver. But when you install the restricted NVIDIA graphics driver, you will need to manually enable this repository http://ppa.launchpad.net/mactel-support/ubuntu/pool/main/n/nvidia-bl-dkms/ and install the package nvidia-bl-dkms
External Monitor
Works fine with proprietary NVIDIA graphics driver, you just need to configure it with the nvidia-settings tool - no reboot is needed. You can find it in System -> Administration.
Sound and Headphones
I get these working only with some settings in file /etc/modprobe.d/options - you may need to create it.
If you use this, you get poor sound quality but headphones working (you need to reboot)
options snd_hda_intel model=mbp3 power_save=5
If you don't want to reboot, you can:
- close all audio applications
- unload the module snd-hda-intel typing a couple of times in a terminal
sudo killall pulseaudio && modprobe -r snd-hda-intel
- and than reload the module with this command
sudo modprobe snd-hda-intel model=mbp3 power_save=5
If you want good audio quality but NO headphones working, you can instead use this in the same file as above, and than reboot - or if you don't want, you can do as before:
options snd_hda_intel model=acer-aspire-7730g power_save=5
Microphone
The internal microphone works with both settings as in the section above.
Suspend/Hibernate
Suspend works out of the box. I didn't test Hibernate.
Remote Control
You have to install gnome-lirc-properties from repositories, and configure it following the wizard, choosing Apple Mac Mini IR Receiver with Custom remote control. Then go in System -> Preferences -> Infrared Remote Control, unlock the window, choose autodetect and select the IR receiver. Now you can test it: in the bottom of the window, you can see if you remote control works.
Works with the small Apple Remote and LIRC (although auto-repeat appears to be broken, and you have to leave a second or so between repeated key presses). Install the lirc package. There are many possible configurations, here is one that simply injects standard keys into X when pressing the keys on the remote.
Then change the file /etc/lircd.conf.gnome into this:
begin remote name Apple_A1156 bits 8 eps 30 aeps 100 one 0 0 zero 0 0 pre_data_bits 24 pre_data 0x87EE81 gap 211982 toggle_bit_mask 0x0 ignore_mask 0x0000ff01 begin codes KEY_VOLUMEUP 0x0B KEY_VOLUMEDOWN 0x0D KEY_PREVIOUSSONG 0x08 KEY_NEXTSONG 0x07 KEY_PLAYPAUSE 0x04 KEY_MENU 0x02 end codes end remote
Now, create and make executables two files in your home directory-I created them in the "script" directory: they will let you adjust audio volume from shell: script/volume_up
A=`pacmd dump | grep "set-sink-volume " | cut -d " " -f 3` B=$((A + 0x01000)) if [ $(($B)) -gt $((0x10000)) ] then B=$((0x10000)) fi pactl set-sink-volume 0 `printf "0x%X" $B`
script/volume_down
A=`pacmd dump | grep "set-sink-volume " | cut -d " " -f 3` B=$((A - 0x01000)) if [ $(($B)) -lt $((0x00000)) ] then B=$((0x00000)) fi pactl set-sink-volume 0 `printf "0x%X" $B`
This two scripts are useful to control your audio level from the shell or in a script. If they don't work because you have some esoteric configs, maybe you can adjust them on line 3 - take a look at the output of the command
pacmd dump
in line beginning with "set-sink-volume" and adjust line 3 accordling.
Now, you have to create a file like this (this is my own config, you can change it according to your preferences) in your home directory: .lircrc
begin rhythmbox begin prog = Rhythmbox button = play config = playpause end begin prog = Rhythmbox button = pause config = pause end begin prog = Rhythmbox button = forward config = next end begin prog = RhythmBox button = backward config = previous end begin prog = RhythmBox button = fw config = seek_forward end begin prog = RhythmBox button = bw config = seek_backward end end rhythmbox begin prog = irexec button = volup config = $HOME/script/volume_up repeat = 2 end begin prog = irexec button = voldown config = $HOME/script/volume_down repeat = 2 end begin prog = irexec button = play config = rhythmbox-client end begin prog = irexec button = menu config = rhythmbox-client --set-rating 2 end
and last add and enable the command "irexec --daemon" in System -> Preferences -> Session Properties (gnome-session-properties, from shell) - this will run irexec every time you log in into your home session and execute your favourite commands when you press something on your remote control.
With this .lircrc file:
- Pressing Play/Menu will start rhythmbox, if it is not already running
- Pressing vol+/vol- will change system volume
- Pressing Play will play/pause playback, if rhythmbox is running
- Pressing forward/backward will change song, if rhythmbox is running
- Pressing menu will rate with two stars the current song, if rhythmbox is running
You can change it as you prefere.
|