Difference between revisions of "Playstation 2"

From NAS-Central Buffalo - The Linkstation Wiki
Jump to: navigation, search
(Installing Ups2client)
(Installing Ups2client)
Line 58: Line 58:
 
Copy this into it:
 
Copy this into it:
  
  #! /usr/bin/env python
+
#! /usr/bin/env python
 
  import commands
 
  import commands
 
  import time
 
  import time
Line 69: Line 69:
 
     #if the ping returned 0, we can see the PS2
 
     #if the ping returned 0, we can see the PS2
 
         if rc == 0:
 
         if rc == 0:
    # If the server isn't running, start it.
+
                # If the server isn't running, start it.
        if serverrunning == 0:
+
                if serverrunning == 0:
            serverrunning = 1
+
                        serverrunning = 1
    # start server app
+
                        # start server app
        os.system("./ps2client -h 192.168.0.10 listen &")
+
                        os.system("./ps2client -h 192.168.0.10 listen &")
            print "server started"
+
                        print "server started"
    # If the server is running and we're no longer connected, close it.
+
                # If the server is running and we're no longer connected, close it.
 
         else:
 
         else:
        if serverrunning == 1:
+
                if serverrunning == 1:
            serverrunning = 0
+
                        serverrunning = 0
    # close server app
+
                        # close server app
        output = commands.getoutput("killall ps2client")
+
                        output = commands.getoutput("killall ps2client")
            print "server closed"
+
                        print "server closed"
    time.sleep(10)
+
        time.sleep(10)
  
 
I put a start script in to start ps2client and the run the above script as this was the only way I could get it to work how I wanted it to, e.g turn on PS2 and have access to Linkstation files.
 
I put a start script in to start ps2client and the run the above script as this was the only way I could get it to work how I wanted it to, e.g turn on PS2 and have access to Linkstation files.

Revision as of 11:55, 31 October 2006

Smsb.gif

Contents

Simple Media System (SMS)

SMS is a DivX and MP3 player for the PS2.

get it here: http://sms.ps2-scene.org/eng/index.htm

Using SMS, you can stream movies and music right to your TV. forget about all the set-top boxes, forget about the 'Media PC', if you have a PS2, you have all the hardware you need.

Features

Features of SMS include:

  • Smooth DivX AVI Playback at decent resolution
  • Pan/Scan and zooming
  • Subtitles support (SRT and SUB)
  • Visual seek (Fast Foward and Rewind)
  • Multiple language and character set support for subtitles other than English
  • MP3 Playback
  • AC3 Surround Support
  • Full resolution
  • Multilanguage
  • Copy your movies and mp3's to your internal HDD!

SMS will read video files from a variety of sources:

  • Network Streaming
  • USB Drives
  • Hard Drives (both the Official Sony HDD and any normal PC HDD)
  • CD/DVD-ROM (and NO modchip required!)

Running SMS

To run SMS you will need to have a modchip or use the PS2 Independence Memory Card Exploit

Installing Ups2client

This is the server that will allow the PS2 to connect to your Linkstation. You can download the source code from this post HERE (registration required). The code has been updated to allow for applications to traverse through subdirectories on Linux systems, thanks husky99 of kurubox forums

I believe you will need to have the development tools installed if you run OpenLink to compile Ups2client

Compile Ups2client

make clean
make PREFIX=$PS2DEV/usr install

This installs ps2client and fsclient into /usr/bin. Only problem now is that SMS has to be started on the PS2 before you start ps2client, husky99 solved that with a python script below, checkPS2.py, obviously you'll need python installed on your system. FreeLink users can just:

apt-get install python

You will need to place the script in the same place as ps2client (/usr/bin in my case)

pico /usr/bin/checkPS2.py

Copy this into it:

#! /usr/bin/env python
import commands
import time
import os

serverrunning = 0
while 1:
    # Check for connectivity to PS2
       (rc, output) = commands.getstatusoutput("ping -c 3 192.168.0.10")
    #if the ping returned 0, we can see the PS2
       if rc == 0:	
                # If the server isn't running, start it.
                if serverrunning == 0:
                        serverrunning = 1
                        # start server app
                        os.system("./ps2client -h 192.168.0.10 listen &")
                        print "server started"
                # If the server is running and we're no longer connected, close it.
       else:
                if serverrunning == 1:
                        serverrunning = 0
                        # close server app
                        output = commands.getoutput("killall ps2client")
                        print "server closed"
       time.sleep(10)

I put a start script in to start ps2client and the run the above script as this was the only way I could get it to work how I wanted it to, e.g turn on PS2 and have access to Linkstation files.

pico /etc/init.d/ps2client

Copy this to it:

#!/bin/sh
#
# $Date: 01/09/2006 $ Bauldrick $
#
# ps2client      This shell script takes care of starting and stopping
#            ps2client.
#
# description: ps2client server for Playstation2 (SMS).

PATH=/usr/sbin:/usr/bin:/bin:${PATH}
   export PATH

   PS2CLIENT='/usr/bin/ps2client'
   IP='192.168.0.10'

   case "$1" in
   start)
   echo -n "Starting ps2client: "
   $PS2CLIENT -h $IP listen &
   cd /usr/bin
   ./checkPS2.py &
   echo "done"
   sleep 1
   ;;
   stop)
   echo -n "Shutting down ps2client: "
   $PS2CLIENT -h $IP poweroff &
   # -- Or: kill `getpid $PS2CLIENT`
   sleep 1
   echo "done"
   ;;
   restart)
   echo -n "Restarting ps2client: "
   $0 stop
   sleep 1
   $0 start
   ;;
   status)
   echo "Status of ps2client: "
   ps auxw|grep ps2client
   ;;
   *)
echo "Usage: ps2client {start|stop|restart|status}"
   exit 1
   esac

   exit 0

Then link it:

cd /etc/rc2.d && ln -s /etc/init.d/ps2client S99ps2client
cd /etc/rc6.d && ln -s /etc/init.d/ps2client K99ps2client
cd /etc/rc0.d && ln -s /etc/init.d/ps2client K99ps2client

Configuring

Now that it is installed and running (hopefully), you would normally create an elflist.txt and enter locations, however I believe this is currently broken? So, create links from the media you would like to stream, to the place ps2client is located, i.e:

ln -s /mnt/hda/films /usr/bin
ln -s /mnt/hda/music /usr/bin



USB

SMS is capable of reading files from a USB drive, but due to liscencing issues, the USB driver USBD.IRX is not included with the SMS distribution. SMS looks for it in the following folders:

  • host:USBD.IRX
  • mc0:/BOOT/USBD.IRX
  • mc0:/PS2OSCFG/USBD.IRX
  • mc0:/SYS-CONF/USBD.IRX
  • mc0:/PS2MP3/USBD.IRX
  • mc0:/BOOT/PS2MP3/USBD.IRX
  • mc0:/SMS/USBD.IRX

A suitable version of USBD.IRX can be found within the distribution of naplink: naplink-ps2-v1.0.1a. This can be found at http://naplink.napalm-x.com/.

Download the above zip file, and open it up – inside you will find a file called npm-usbd.irx. Copy this file to a local folder on your computer, then rename it to USBD.IRX (must be in capitals). Then use an FTP program or other method to copy the file to one of the above locations. Next time SMS starts up, it will have USB support enabled. You won't see any difference until you plug in a compatible USB drive. Then you will see a new icon as shown below. Press RIGHT to select this icon and browse the USB drive.