Tivo-PPP (over serial) for Windows 9x - PPP on TiVo

Dummy's Guide to:
Tivo PPP over Serial for Win 9x

PPP on TiVo

Setting up Tivo for PPP:

Ok you should still be on your Bash prompt from the previous chapter. From here we need to do a few things, reset the diagnostic console password if you couldn't get into it (SA units only), get a working pppd binary if your using Tivo's 2.5.1 software (the one included in 2.5.1 is problematic), and create and edit files to get PPP working.  Since we'll mostly be editing and creating new files to setup the PPP on TiVo to to this it would be nice to have a simple text editor to use, so first we'll load a copy of Joe onto the Tivo - Get it here you can use PowerArchiver to extract it. Ok I've noticed a little bit of confusion with this page so I've reformatted it a bit, when your supposed to be at the bash prompt Bash# will appear before the instructions, files to written in Joe are identified by path/filename between Horizontal Rules, and end with the same.

Resetting diagnostic console password:

Bash#  
   
stty sane // This lets you see what your typing
crypto -u -srp "factory" // Resets Password to factory

Getting Joe onto tour TiVo :

Bash#  
   
stty sane // This lets you see what your typing
mount -o rw,remount / // Tivo boots in read only, we need to remount with read/write
mkdir /var/hack // Make /var/hack directory
cd /var/hack  
rz // Should get "waiting to recieve", telling TiVo to expect a file


Now we send the files with ZModem transfer directions below
note: you'll need to to do this twice to get both joe and joerc over

 
   

Hyper Terminal

Tera Term


Browse to the file location and send Browse to the file location and send
repeat for second file repeat for second file

For TiVo's running pre 2.5.1 Software:

Bash#
 
chmod +x * // allows execution of Joe (poor Joe)
PATH=$PATH:/var/hack // this way TiVo knows where Joe is
cd /sbin  
cp pppd custpppd // create our own pppd cause TiVo kills its own
cd /dev  
mknod cua3 c 5 67 // Make our cua3 device( basically Tivo's Comm3 )
cd /etc  
joe ppp-options.cua3 // Create our ppp options file

For TiVo's running 2.5.1 Software:

If your TiVo is running software version 2.5.1, then you'll need to download the old pppd binary here. Extract and transfer it to TiVo as you did JOE, I assume your moving the old pppd into the same directory as JOE from there we copy it to its correct location.

Bash#
 
chmod +x * // allows execution of Joe (poor Joe)
PATH=$PATH:/var/hack // this way TiVo knows where Joe is
cp custppd /sbin // create our own pppd cause TiVo kills its own
cd /dev  
mknod cua3 c 5 67 // Make our cua3 device( basically Tivo's Comm3 )
cd /etc  
joe ppp-options.cua3 // Create our ppp options file

Joe our humble text editor:

Joe is a simple text editor, think of it as your new version of Window's Notepad =P.  I'll provide some simple commands, and walk you through the first file.

CTRL K - H Help Screen
CTRL K - X Save and exit
CTRL C Abort - exit and do not save
CTRL K-F Find Text
CTRL K -U Move to start of file
CTRL K - V Move to end of file

/etc/ppp-options.cua3
   
#This what Joe will look Like 
/dev/cua3 // device for pppd to use
115200 // Baud Rate
debug // provides debugging info
nocrtscts // turns off Flow Control
lcp-echo-failure 2 // used to restart ppp
lcp-echo-interval 60    // check link every 60 sec
local // no modem
noauth // do not require authentication
nodetach // stay with terminal
asyncmap 0 // control key info
name tivo // Give TiVo a Hostname
defaultroute // Add route from peer
refuse-chap // We want PAP
     

end /etc/ppp-options.cua3
now hit Ctrl^k followed by Ctrl^x to exit and save
your terminal window will now look like this
   
   
   
Now that your a bit familiar with Joe  we'll move on
 
To Do:
  add pap-secrets file
  add login script
  modify rc.sysinit
  fix for internet updates
 
 
Bash#  
   
joe pap-secrets // Adding PAP authentication settings
 

/etc/pap-secrets
   
tivo * tivo // username * password  ( * is server but is of no concern to us )
 

end   /etc/pap-secrets

 

Bash#  
   
cd /etc/rc.d  
joe rc.remote-login // Adding login script
 

/etc/rc.d/rc.remote-login
   
#!/bin/bash // execute under bash
tnlited 23 /bin/bash -login & // Start a telnet service so we can use bash later
while : ; do // setup while loop so we can reconnect
     stty 115200 </dev/cua3 // connect at 115200 Baud
     echo "CLIENTCLIENT" > /dev/cua3 // simulate a ring (doesn't really matter what we say )
     sleep 1s // give windows a chance to pick-up
     /sbin/custpppd file /etc/ppp-options.cua3 nodetach // Start our ppp daemon
     echo "pppd started on /dev/cua3" // Just for the logs
     sleep 60 // allows it to restart every minute so we can reconnect
done // Ends our While loop
 

end   /etc/rc.d/rc.remote-login
   

Bash#

 
   

 chmod g+x rc.remote-login

// Add execution attributes

Ok the next to steps are modifying system files which already exist, don't just go changing things and know where your making the changes. Now to the first file type joe rc.sysinit now page down to the end of the file. The last line should be /bin/bash < /dev/ttyS3 >& /dev/ttyS3 & this is the line we added earlier you may now delete it and the following in its place:


/etc/rc.d/rc.sysinit   modification
   
# TiVo PPP modification // Just a comment so we can find this later
   
PATH=$PATH:/var/hack // Add Joe's path again so we can use it later
export PATH // make sure PATH exists globally
   
#  DirecTiVo   Users read note!  
   
if [ "$shondss" = true ]; then // Check our boot parameter
     echo "Starting bash on /dev/ttyS3" // For the Logs
     /bin/bash </dev/ttyS3 >& /dev/ttyS3 & // Start Bash on Serial port
else  
     echo "Starting PPP, running remote login" // For the Logs
     /etc/rc.d/rc.remote-login & // Run Login script
fi // End our If..Then..Else structure
   
# End TiVo PPP modification // We're done here
   

end   /etc/rc.d/rc.sysinit   modification
   

# note for DirecTiVo  users since you can not set shondss as a boot parameter you need to add the following before the IF statement

   

shondss=false

export shondss

Getting Updates over the Net:

The last modification we're going to make is to allow TiVo to retrieve its updates via or PPP connection, if for whatever reason you do not wish your TiVo to use the PPP connection to retrieve  updates (TiVo will continue to use its Modem)  you may skip this.This is a BIG file so pay attention to the directions.  We'll be searching for the the 1st occurrence of  " if [file exists /var/tmp/pppaddr]" and writing a snippet before it. The Search directions are preceded by Inside JOE#.

Bash#

   

cd /tvlib/tcl/tv

// Move to the proper location

joe TClient-lib.itcl

// Edit another file =P

 

Inside JOE#

 

CTRL-K, CTRL-F

// Start a search

pppaddr (ENTER) (ENTER) // What we're serching for
   

Place Modification before this line:  if [file exists /var/tmp/pppaddr] {

 

 /tvbin/tcl/tv/TClient-lib.itcl   modification
   
# TiVo PPP Modification  
   
if [ info exists env(shondss) ] { // find out if the shondss parameter exists
     if { $env(shondss) == "false" || $env(shondss) == "FALSE" } { // find out if we're running our ppp
          putlog "custpppd running, using existing connection" // for the logs
          catch { file delete /var/tmp/pppaddr } // delete pppaddr, making TiVo ignore the modem
     }  
}  
 
# End TiVo PPP Modification  
 

end   /tvbin/tcl/tv/TClient-lib.itcl   modification

Now we're finally done with the TiVo side. We'll just make some quick backups and move on to Setting Up Windows.

Bash#  
   
mkdir /var/hack/backup // create our backup directory
cp /etc/ppp-options.cua3 /var/hack/backup  
cp /etc/pap-secrets /var/hack/backup  
cp /etc/rc.d/rc.remote-login /var/hack/backup  
cp /etc/rc.d/rc.sysinit /var/hack/backup  
cp /tvlib/tcl/tv/TClient-lib.itcl /var/hack/backup  

Alternatively you can use your terminal program to copy the files over to your computer, just set up your terminal program like before except choose receive instead of send and type sz path/filename in the terminal window. You may now turn off your TiVo a continue to PPP on Windows


Dummy's Guide to:
Tivo PPP over Serial for Win 9x

index:
  Introduction | Backing Up your Tivo | Getting to Bash | PPP on Tivo
PPP on Windows | Trouble Shooting | Feedback/Contact