Deprecated: Assigning the return value of new by reference is deprecated in /var/www/psdevWiki/inc/parserutils.php on line 161

Deprecated: Assigning the return value of new by reference is deprecated in /var/www/psdevWiki/inc/parserutils.php on line 164

Deprecated: Assigning the return value of new by reference is deprecated in /var/www/psdevWiki/inc/parserutils.php on line 294

Deprecated: Function split() is deprecated in /var/www/psdevWiki/inc/auth.php on line 97

Warning: Cannot modify header information - headers already sent by (output started at /var/www/psdevWiki/inc/parserutils.php:161) in /var/www/psdevWiki/inc/auth.php on line 180

Deprecated: Function split() is deprecated in /var/www/psdevWiki/inc/common.php on line 552

Warning: Cannot modify header information - headers already sent by (output started at /var/www/psdevWiki/inc/parserutils.php:161) in /var/www/psdevWiki/inc/actions.php on line 71
ps3:mediacenter [psDevWiki]
Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Los_Angeles' for 'PDT/-7.0/DST' instead in /var/www/psdevWiki/inc/template.php on line 154
 
Table of Contents

PS3 Mediacenter

This how-to

  • is up to date
  • can be improved by anyone
  • is for everyone who wants to use the ps3 as a mediacenter
  • is for everyone who wants to look at movies at ps3 without lags/skips
  • explains how to setup a linux on PS3 with the fastest possible video playing that’s possible until now.
  • mentions every ressource needed to accomplish this task

That includes:

  • How to install patched mplayer on gentoo
  • How to install freevo


ToDo:

  • Update Kernel
  • Get controller working in freevo wirelessly
  • HowTo Install patched x11 modul
  • Make ps3gentoo or gentoo ebuild’s of patched mplayer, libspe2 etc avaiable

What are we doing here?!

This how-to explains the not-yet-so-easy-way to get the linux mediacenter working.

arguments for a linux ps3 mediacenter

  • plays every format (not just mpeg, and some divx and xvid)
  • plays subtitles
  • great connectivity (smb, nfs, sftp, http, you name it)
  • full control (free, open source)
  • costumizeable

why does'nt it just work?!

The biggest problem is, that the PS3 is too slow to play movies. BUT, you say, HOW can such a numbercruncher be slow at playing movies?

First, Sony does allow direct access to the graphic cpu, only to graphic output. This means that even such simple things as scaling an image or color conversation has to be done in software. This leads us to the second problem: the slow ass cpu. Sony advertises with “two 3,2ghz cpus” or something, but in reality, it feels like an Athlon with 1Ghz. This means, even heavy compiler optimized mplayer/xine/whatever are not capable of playing many movies smoothly and without lag.

The solution to this problem is to offload those simple, but computally expensive things to the seven SPUs, which are especially designed for those things, and with their help we can provide smooth video playing. We’re using the spu-medialib for this task. All this has nothing todo with the RSX hack which worked on pre 2.10 versions.

shortcomings:

  • no support for x264 yet, which means big .mkv movies are still unwatchable
  • mplayer does not really support every realmedia file out there
  • no flash (?)

what are we going to do

  1. get a linux up and running
  2. install cell development tools
  3. install some very usefull libraries
  4. patch and install mplayer to use spu’s with spu-medialib
  5. patch and install freevo

Ubuntu

Everything’s here: http://psubuntu.com/
more info here: http://linux.yes.nu/PS3Ubuntu/
Even pre-compiled vo-patched-mplayer packages are avaiable.

Gentoo

Why gentoo@ps3?

  • small base install (few installed packages)
  • small memory footprint
  • can be optimized (recompiling is very easy)
  • BUT: emerge is python and very slow :(

Install Gentoo

Install Cell development Tools

Use this howto: howto install cell environment in gentoo (but we _dont_ need the CELLSDK21)

Or, in short:

# emerge rpm rpm2targz
# emerge glut libXmu libXext

Get the following rpm’s from: http://www.bsc.es/projects/deepcomputing/linuxoncell/cellsimulator/sdk2.1/ (not the “src” files!)

spu-binutils, spu-gcc, spu-gcc-c++, spu-gdb, spu-newlib, spu-newlib-debuginfo

Install with:

for x in *.rpm
do
        rpm2tar $x
done
BUILDDIR=`pwd`
cd /
for x in $BUILDDIR/*.tar
do
        sudo tar xvf $x
done

Fix: spu medialib want the compiler as “spu-elf-gcc”

# ln /usr/bin/spu-gcc /usr/bin/spu-elf-gcc

Install libspe2.2

Get the following files from http://www.bsc.es/plantillaH.php?cat_id=463

libspe2-2.2.?, libspe-devel2-2.2.?

As i’ve got 32bit Userland, i took those without “ppc64” (unsure if you have u32? test with “file /bin/bash”)

Install it as above, with “rpm2tar” and “tar”

fix pkg-config

paste the following into “/usr/lib/pkgconfig/libspe2.pc”: (or else spu-medialib cant find the libspe2 library)

prefix=$(prefix)
exec_prefix=$(exec_prefix)
libdir=$(libdir)
includedir=$(includedir)
Name: libspe2
Description: A wrapper library to adapt the JSRE SPU usage model to SPUFS
Version: 2.2.0
Requires:
Conflicts:
Libs: -L${libdir} -lrt -lpthread
Cflags: -I\${includedir}

Install SPU Medialib

Follow steps from: http://wiki.ps2dev.org/ps3:spu-medialib:install
or, in short:

# svn checkout svn://svn.ps2dev.org/ps3ware/trunk/spu-medialib spu-medialib
# cd spu-medialib
spu-medialib # aclocal && libtoolize --copy --force && automake --add-missing --foreign && autoconf
spu-medialib # cd spu
spu # aclocal && libtoolize --copy --force && automake --add-missing --foreign && autoconf
spu # ./configure --host spu-elf
spu # cd ..
spu-medialib # ./configure --prefix /usr (ignore error due to previusly configured spu)
spu-medialib # make && make install

install libps3fb

Follow the steps in: http://forums.ps2dev.org/viewtopic.php?p=59150#59150
or, in short:

# svn checkout svn://svn.ps2dev.org/ps3ware/trunk/libps3fb libps3fb 
# cd libps3fb 
# aclocal 
# autoconf 
# automake --add-missing 
# ./configure 
# make && make install

install mplayer

Follow the steps in: http://forums.ps2dev.org/viewtopic.php?t=9187
or, in short:

# svn co svn://svn.mplayerhq.hu/mplayer/trunk mplayer 
# svn co svn://svn.ps2dev.org/ps3ware/trunk/mplayer-vo mplayer-vo 
# cd mplayer 
# patch -p0 < ../mplayer-vo/latest.patch 
# ./configure; 
# make && make install

How to user mplayer

# mplayer -vo ps3 -fs -zoom file.avi

Fixes

elfspe

some package installed the file “/etc/init.d/elfspe” on my system, which is not in a gentoo compatible format/syntax and produces an error while starting. Changing it is trivial. Maybe we dont even need it ?

slow portage

Using CDB as database for portage instead of flat files does speed it up a little: http://gentoo-wiki.com/TIP_speed_up_portage_with_cdb

Gentoo: Install freevo

Use the following, sane, use-flags in make.conf:

USE="altivec X fbcon x264 xvid -opengl -kde -gnome -qt4 -qt3 -mplayer -sdl"

then, just emerge freevo:

emerge freevo

Note:
emerg’ing freevo will also install mplayer. I found no way to avoid it (i messed with “package.provided”, but it did not work). Finally, i installed the patched mplayer into /opt/mplayer/ (”./configure –prefix=/opt/mplayer/”). You also just can re-install the patched mplayer after emerging.

Get the following files from the freevo.tar.gz, and copy it to /etc/freevo/ and/or ~/.freevo/

contrib/ps3/freevo.conf contrib/ps3/local_conf.py

(see http://doc.freevo.org/FAQ#head-76f4d7283b6d458fbf780b0c613b66f04a1f6f2e)

and now the most important step: apply the following patch to /usr/lib/python2.5/site-packages/freevo/childapp.py (it also could be in python2.4/). Or else, your screen will be blank after mplayer quit’s, as freevo will not update the screen.

@@ -358,6 +358,8 @@
 
         if pid == self.child.pid:
             self.status = status
+            osd.stop()
+            osd.restart()
             return True
         return False
@@ -385,6 +387,9 @@
         if self.stop_osd:
             osd.restart()
 
+        osd.stop()
+        osd.restart()
+
         if self.is_video:
             rc.post_event(Event(VIDEO_END)) 

in the file freevo.conf, change

display = fbdev

to

display = ps3

if you want to use patched mplayer. Dont forget to adjust

mplayer = /usr/bin/mplayer

into

mplayer = /opt/mplayer/bin/mplayer

if you installed it there.

Then:

# mkdir ~/videos/
# freevo setup
# freevo

TADA! Welcome to your new mediacenter.

Note: If freevo still does not reappear after exiting mplayer, unmerge freevo, download freevo 1.7.5 source, apply the little patch for childapp.py and install it manually with “python setup.py install”.

Other

Bugs

Timeline

Last checked and updated: 22 Jan. 2007

 

Warning: date() [function.date]: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected 'America/Los_Angeles' for 'PDT/-7.0/DST' instead in /var/www/psdevWiki/inc/template.php on line 523
ps3/mediacenter.txt · Last modified: 2008/05/15 00:07
 
Recent changes RSS feed Creative Commons License Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki