My favorites | Sign in
Project Logo
             
Search
for
Updated Jun 24, 2008 by sdavilla
PostMythbuntuHardy  

Mythbuntu Hardy Post-Install Fixes

Mythbuntu Hardy is pretty easy to fix up.


NVIDIA

Mythbuntu Hardy uses the 169.12 nvidia binary kernel (selected during the install). This mean we don't have to update it, just add the under-clock. The nvidia gpu needs to be under-clocked to prevent nvidia xvmc related hangs/video corruption when doing xvmc assisted mpeg2 decode/display.

This enables gpu clock changes. Note that it's "nvidia_new" not "nvidia" as we are running under the linux restricted modules install of the nvidia driver. Edit "/etc/modprobe.d/options" and add following which forces the nvidia driver to treat the chipset as non-mobile and disabled "PowerMister" which provide dynamic clock changes depending on gpu load.

options nvidia_new NVreg_RegistryDwords="PerfLevelSrc=0x2222" NVreg_Mobile=0

Create an autostart entry for X11. This is used to automatically apply our clock changes when X11 starts running. Clock changes using "nvidia-settings" are not saved and restored on restart so we have to do this manually. Ubuntu and Mythbuntu uses "/home/username/.config/autostart/" as the path to autostart apps. If you are running a different debian distribution then you will need to figure out where to place these additions.

# nvidia-settings is used to actually change the gpu clock but,
# we want it to always be applied after the startup of X11. Create an 
# autostart entry for the username that was setup during the install. 
# I'm using "username" here, you should replace "username" with your username.
#
sudo nano /home/username/.config/autostart/nvidia_fixes.desktop
[Desktop Entry]
Encoding=UTF-8
Version=0.9.4
Type=Application
Name=nvidia xvmc hang fixup
Comment=fixes nvidia problems with xvmc decode
Exec=/usr/sbin/nvidia_hang_fix.sh
StartupNotify=false
Terminal=false
Hidden=false

# now create the actual script
sudo nano /usr/sbin/nvidia_hang_fix.sh
#!/bin/bash
nvidia-settings -a GPUOverclockingState=1
nvidia-settings -a GPU2DClockFreqs=200,800

# change the file permission so it can execute
sudo chmod 755 /usr/sbin/nvidia_hang_fix.sh

Finally

# add nvidia-setting from apt-get
sudo apt-get install nvidia-settings

# run the nvidia xconfig tool to enable coolbits so we can actually change the nvidia gpu clock
sudo nvidia-xconfig --cool-bits=1 --no-composite --no-logo

if "nvidia-xconfig" complains about "cool-bits" then just do "sudo nvidia-xconfig --no-composite --no-logo" and add this option manually to 'Section "Screen"' in "/etc/X11/xorg.conf"

    Option         "Coolbits" "1"

if "nvidia-xconfig" complains about "--no-composite", manually add that to "/etc/X11/xorg.conf"

Section "Extensions"
    Option         "Composite" "Disable"
EndSection

To test, stop X11, unload/load the nvidia module then restart X11 and check the gpu clock settings. Note this might be "nvidia-new" instead of "nvidia".

# stop X11
sudo /etc/init.d/gdm stop

sudo modprobe -rv nvidia
sudo modprobe -v nvidia

You should see the following

insmod /lib/modules/2.6.24-16-generic/kernel/drivers/i2c/i2c-core.ko 
install /sbin/lrm-video nvidia 
insmod /lib/modules/2.6.24-16-generic/volatile/nvidia_new.ko NVreg_RegistryDwords="PerfLevelSrc=0x2222" NVreg_Mobile=0

Start X11 then check the gpu clock settings

# start X11
sudo /etc/init.d/gdm start

sudo nvidia-settings -q all

AUDIO

Dirt simple, edit "/etc/modprobe.d/options" and add

options snd-hda-intel model=imac24

That's it, remember to run "alsamixer" and un-mute for analog and digital audio output. The iMac with 24 inch LCD has very similar ALC885 ALSA configuration and we can use it for the AppleTV.


IR Controller

Edit "/etc/modprobe.d/options" and add

options usbhid quirks=0x05ac:0x8241:0x10

Rebuild the initramfs so that the usbhid module options get propagated to the initramfs

sudo update-initramfs -u

Now follow the "Setup LIRC" section (half way down the page) in the old IR Update wiki page. Skip the "Enable usbhid" part as it was already enabled by the modprobe quirk above.


Comment by tflu...@gmail.com, May 03, 2008

For anyone that has an issue getting the sound working through spdif here are the settings that I used to get it working.

Changed the myth sound settings to the following:

Audio Output Device: ALSA:default Passthrough output device: ALSA:plughw:0,1 Checked Enable AC3 to spdif passthrough Checked Enable DTS to spdif passthrough

I'm now completely setup and working. I'm going to run for a while (a couple weeks) using the external usb hardrive and see if I run into any issues. If I run into anything I will post the issues.

After I'm comfortable that everything is working I will do a clean install to the internal HD to test that out.

Thanks again for your fantastic work on this.

Comment by tflu...@gmail.com, May 03, 2008

sorry forgot to format the settings:

Audio Output Device: ALSA:default 
Passthrough output device: ALSA:plughw:0,1 
Checked Enable AC3 to spdif passthrough 
Checked Enable DTS to spdif passthrough
Comment by fred.m.hamilton, Jun 01, 2008

A few more details for audio out (digital anyway, not sure if it applies to analog): 1. I rebooted after changing modprobe/options and before running alsamixer. Not sure if it was necessary, though. 2. You want to unmute the IEC958 entry in alsamixer. Use the cursor keys to select it, then press "m" to unmute.

Comment by lea...@mac.com, Jun 02, 2008

I had problems with irrecord until I unplugged my USB hub and USB keyboard. I could not figure out how this affected anything but it was my last resort when I could not get the remote working. Hope this saves someone the grief. Also worth repeating here is the comment on another distribution's page that setting toggle_bit_mask 0x9 in the lircd.conf file to toggle_bit_mask 0x0 is required to get all keys working or some generate identical output.

Comment by wck555, Apr 24, 2009

After I got MythTV installed, my Samsung TV showed it was getting a signal and showed the correct refresh rate and resolution. It even showed the refresh rate / resolution changing when I changed those settings (using VNC). But the screen was black. Finally, in desperation, I unplugged the HDMI cable and tested the TV with my laptop. When I plugged it back into the AppleTV, the MythTV screen appeared! The only problem now is when I reboot I have to (usually but not always) unplug and plug the HDMI cable to get video out. I always see the boot console messages on the TV. But when GNOME starts, the display goes blank until I unplug/replug.

I am using Intrepid Ibex (8.10) with NVIDIA 177.80 which may be part of the difference. All the steps above worked on Intrepid BTW. With the unplug/plug trick, I have a functional AppleTV / Mythbuntu setup. Thanks for everyone's hard work on this project! It's been fun.

Comment by wck555, May 04, 2009

I was able to solve my problem by disabling EDID detection in the nvidia driver using the xorg.conf option

Option         "UseEDID" "FALSE"

I then had to tell the driver which video mode to use. This also has the benefit that I can now boot the system with the TV turned off. Normally nvidia tries to query the display to see what its abilities are. But if the TV is disconnected or turned off the driver can't query the display and falls back to a default display setting, which is often not what you wanted. With UseEDID, you can disable this feature and then force the driver to use the settings you tell it. There is more information on this thread:

http://ubuntuforums.org/showthread.php?t=913224


Sign in to add a comment
Hosted by Google Code