Mac OS X Install

From pyTivo - Wiki

(Redirected from OS X Install)
Jump to: navigation, search


pyTivo Requirements

  • pyTivo - Download a recent version from Current_Releases
  • Python - Requires version 2.5 or higher
    • 2.5.1 is already installed by default on Leopard 10.5
    • 2.6.1 is already installed by default on Snow Leopard 10.6
    • 2.7.1 is already installed by default on Lion 10.7
  • FFmpeg - Recommended to use builds from at least 2010 or later
    • Downloadable builds for FFmpeg are available on the pyTivo forums:
      • Intel Macs with OS X 10.6 and above are here
      • Intel Macs with OS X 10.5 or PPC Macs are here
    • Another method to obtain FFmpeg, although more difficult, is to compile your own using the MacPorts application. This may yield slightly faster transcoding speeds.

pyTivo Installation

1. Download pyTivo

  • Grab a development snapshot from one of the developers at the Current_Releases page.
  • Extract the downloaded file.
  • Rename the folder to 'pyTivo' and move it to where you want to run pyTivo from. Ex: /Applications/pyTivo/

2. Download FFmpeg

Note:  FFmpeg enables pyTivo to transfer many types of video/audio to the TiVo.
       It is not technically required (for some functions) but highly recommended.
  • A ready and downloadable copy is available from this link
    • Place it in a folder called 'bin' in your pyTivo folder. You will need to make this folder. Ex: /Applications/pyTivo/bin/
      • If you choose instead to manually build FFmpeg using MacPorts you should update the path in pyTivo.conf to point it. EX: ffmpeg = /opt/local/bin/ffmpeg

3. Create a configuration file

  • Using a text editor create a new file called 'pyTivo.conf' and save this within the pyTivo folder.
    • Make sure pyTivo.conf is saved in plain text and not rich text mode or pyTivo will have troubles running.
    • You may need to uncheck 'If no extension is provided, use ".txt" in the save dialog so that the '.txt' extension is not added to the pyTivo.conf file.

The most basic pyTivo.conf file needed to start pyTivo and use the WebAdmin interface will look like this:


4. Run pyTivo

  • pyTivo is run from the Terminal app (/Applications/Utilities/ using the following commands (be certain to use the correct path to where you moved the pyTivo folder to):
cd /path/to/pyTivo/


5. Customize pyTivo

You should now be able to use your browser to navigate to http://localhost:9032 and finish setting up pyTivo with the WebAdmin interface. To see all the available options read Configure_pyTivo or by reading the descriptions available in the WebAdmin interface.

Popular options are:

  • Sharing videos with TiVo and shown in the 'Now Playing List'
  • Transferring TiVo recordings with TiVo ToGo
  • Pushing files back to the TiVo
  • Streaming music files to TiVo
  • Viewing photos on the TiVo

Launching pyTivo at startup

If you choose to launch pyTivo automatically on startup be aware that you will no longer be able to directly see any error messages that may be produced. These can be viewed by using the /Applications/Utilities/Console program and selecting "All Messages" or you can filter for 'pytivo' to see the error messages.

Mac OS X 10.6 and up

Setting pyTivo to launch on startup automatically and in the background on Mac OS X is relatively easy.

  • You must make a text file named "pyTivo.plist" with any text editor.
  • Place the file in /Users/yourusername/Library/LaunchAgents (your user library folder) if you want pyTivo to load only when you are logged on. Or place the file in /Library/LaunchDaemons if you want pyTivo to startup on system boot regardless of whoever is logged in.
    • In 10.7 Lion, Apple has hidden the User library folder. To view it open your Finder and hold down the 'Option' key and choose 'Go > Library' from the Finder menu.
  • Include the following code in the file (you need to update the path to the your pyTivo folder).
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">

OSX 10.4 and 10.5

I have left the older instructions for OSX 10.4 and 10.5 unedited as I am unsure if the above plist file would work for these older systems.

To setup pyTivo to launch on startup automatically, you can use launchd to launch the pyTivo file (on 10.4 or 10.5).

First, you must make the file executable with the following command

bash$ chmod 777

More detailed instructions about creating launchd.plist files are available at [1] and [2]

But the quick version is to

  • Make a text file named "com.pyTivo.plist" (any text editor will do, like TextEdit or SubEthaEdit, vi or emacs)
  • Place the in the ~/Library/LaunchAgents folder and
  • Include the following code in the file (you need to update the path to the your pyTivo folder)
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "">
<plist version="1.0">
	<string>Script to launch pyTivo server</string>

This should cause pyTivo to use launchd to launch automatically when you log into your account.

FFmpeg Installation with MacPorts

If you choose to compile your own FFmpeg instead of using the downloadable version mentioned above you can compile FFmpeg with a program called MacPorts. Download and run the MacPorts installer package to install on your system. You will also need XCode Developer Tools installed. Install this from the Apple Install DVD that came with your Mac or download Xcode on the Mac App Store (10.6 and 10.7 only).

After installing MacPorts open the Terminal application (found in /Applications/Utilities). At the Terminal prompt issue the following commands, you will be prompted for your Administrator password.

sudo port selfupdate
This updates the MacPorts program and available ports to the latest versions
sudo port install ffmpeg +no_x11
This is a lengthy install, as it installs many other dependencies. If you require x11 for another application you may leave off the '+no_x11'.

You should now have a functional copy of FFmpeg installed in /opt/local/bin directory. You can test this by typing the command 'ffmpeg -i' into your terminal prompt which should display a summary screen of the installed FFmpeg options.

Personal tools
Get pytivo at Fast, secure and Free Open Source software downloads