Author: Jon

Howto: Get a Movie from a DVD to your Sony Clie (and probably other PDA’s as well)

Howto: Get a Movie from a DVD to your Sony Clie (and probably other PDA’s as well)

I’ll try to make this as simple as possible.

I’m going to assume that you’re using Linux (and that you are not a complete noob at it) for this tutorial. I will assume that you’re using a Sony Clie.

Here’s an overview of what we’re going to do:

  1. Rip dvd using DVD:Rip
  2. Convert ripped movie into a clie compatible format
  3. Download and install TCPMP (free media player)
  4. (optional) Install Memory Stick Pro fix
  5. Copy Movie to the Memory Stick

Step 1: Download and Install Files
apt-get install dvdrip
apt-get install pilot-link
Download TCMP (for palm)
Download all attachments

Step 2: Rip DVD
Encode with the xvid4 codec
Set file size to One CD at 700Mb
The only reason that I have this step is because I like to watch the video in high quality on my desktop

Step 3: Convert ripped DVD to Palm Readable Format
Put the following into a script called vid2palm and make it executable


#!/bin/sh
#Change 480:320 to the size of your PDA screen
#480:320 works for the Sony Clie

nice mencoder $1 -vf scale=480:320 -ovc xvid -xvidencopts bitrate=300 -oac mp3lame -lameopts cbr:br=64 -o $2
So, if dvdrip created the file MyMovie.avi you’d run the command vid2palm MyMovie.avi MyMovie_Palm_Format.avi

Step 4: Install files on your Clie
This can be a little tricky for someone doing it for the first time, but after a couple of times it works great.

The syntax for installing a palm file is:
pilot-xfer /dev/pilot -i [File to be installed]

However, If you just run this command it won’t work. You first need to hit the hotsync button and then quickly run the previous command.

If you do this and the console says to press the hotsync button, just hit cancel on your clie, and terminate the command, and try again. It’s been a bit of hit-and-miss for me.

Files to install on the PDA from the TCPMP Archive:

  • pilot-xfer /dev/pilot -i tcpmp_ffmpeg_plugin.prc
  • pilot-xfer /dev/pilot -i tcpmp_mp3_plugin.prc
  • pilot-xfer /dev/pilot -i tcpmp_mpeg4_plugin.prc
  • pilot-xfer /dev/pilot -i tcpmp.prc
  • As well as the attached tcpmp_aac_plugin.prc
  • If your memory card is a memory stick pro it will not work by default with the clie, so you have to install a fix for it (it’s the MSPRONX_ENUS.PRC one):
    pilot-xfer /dev/pilot -i MSPRONX_ENUS.PRC

    Sound doesn’t work by default on mine either, I had to install the following patch (again, an attachment: MCA2_05_TEST.prc):
    pilot-xfer /dev/pilot -i MCA2_05_TEST.prc

    You need to set up this plugin by going to prefrences and then in the drop down menu select MCA2, and check the button “auto install after reset”. It will restart, then go back to the same area and select “DEFAULT is ON (normal)”.

    Step 5: Moving the finished product to your Memory Stick (pro)
    First, goto MS Import. If you have a newer distro / kde it will mount the flash drive as a local directory. If it doesnt, use the “mount” command to mount it. I assume that you know how to do this (if you don’t try “man mount”).

    Now it’s a bit of a waiting game. Once it looks like it’s done copying unmount the device in linux first, wait a minute, and then disconnect in MS Import.

    Step 6: Play the Movie
    Goto TCPMP, open, and play your movie!

    This is how I did it, after a week or so of trying.

    If you have any questions leave a comment or email me (howe -dot- jon -at- gmail -dot- com.

    Later,
    Jon Howe

    Hacking the Linksys WRT54G

    Hacking the Linksys WRT54G

    Recently, my Dad purchased the Linksys WRT54G. If you follow tech news, you probably know that more or less, the device (as well as at least one other Linksys device) was hacked.

    All that I have so far is a couple of links, here they are:

    Seattle Wireless
    Shaneo
    I-hacked article (good)
    Openwrt
    Hyperwrt
    Wifi-Box
    Ewrt
    Sveasoft

    The last one looks the most promising.

    I’ll be working on this over spring break (next week), so keep an eye out for a little ‘howto’ on this.

    Later,
    Jon Howe

    Don’t let your daemons die

    Don’t let your daemons die

    Okay, let’s pretend that this isn’t the first time that I’ve posted in about a month. School really has been crazy. I haven’t really even had time to do anything new or cool lately. Tonight though, I’m putting school aside.

    I’ve been having some problems with one of the daemons on one of my server’s randomly dying on me, and it got to the point that I couldn’t bear it anymore, I had to find a solution.

    Thankfully, people have been using developing things for unix/linux for longer than I’ve been alive, and there’s a program that acts as a perfect band-aid. It’s called Monitor.

    Get the file:
    apt-get install monit

    Create the monit control file:
    (The monit control file uses a language of it’s own, if you want to learn it, feel free to go to the references at the bottom of this page. Otherwise just use some form of the file below)


    check process sshd with pidfile /var/run/sshd.pid
    start program "/etc/init.d/sshd start"
    stop program "/etc/init.d/sshd stop"
    if failed port 22 protocol ssh then restart
    if 5 restarts within 5 cycles then timeout

    Then, on the console type monit -c [path to the above file] -d [number of seconds inbetween checks]

    This this is saving me a lot of trouble.

    Sources:

    http://www.tildeslash.com/monit/doc/examples.php
    http://www.tildeslash.com/monit/
    http://www.tildeslash.com/monit/doc/manual.php

    Hopefully it wont be another month,
    Jon Howe

    Howto: Kernel Building in Debian Sarge (3.1)

    Howto: Kernel Building in Debian Sarge (3.1)

    I’ve tried and tried to build my own custom kernel over the past year or so, usually only to stop in frustration because of some small part of the process not working.

    This is all different now.

    I found out that using the took make-kpkg makes things way easier. In fact I configured, compiled, and installed kernel 2.6.15 in about 30 minutes including the time that it took me to build it.

    Here’s the process that I followed to achieve this:

    1. Get required packages apt-get install libncurses5-dev fakeroot bzip2 kernel-package
    2. Get latest kernel package from Kernel.org. The latest one at the time of this post is linux-2.6.15.tar.bz2.
    3. Decompress the kernel archive (tar -xjvf linux-2.6.15.tar.bz2)
    4. Start the kernel configuration tool (make menuconfig)
    5. I should mention that it was way easier for me to load my existing kernel configuration, which was located at /boot/config-(kernel version here).

    6. make-kpkg clean
    7. fakeroot make-kpkg –initrd –revision=myfirstkernelbuild_v.0.1 kernel_image
    8. This runs make-kpkg as root, while making it so that initrd can load the kernekl. –revision is just the revision of the kernel, and kernel_image is just the name of the kernel that you’re building.

      The output of this command is kernel-image-2.6.15_myfirstkernelbuild_v.0.1.deb

    9. Install the kernel (dpkg -i kernel-image-2.6.15_myfirstkernelbuild_v.0.1.deb)
    10. Restart the computer (init 6)
    11. If this process worked the output of uname -r should be 2.6.15.

      Let me know if you have any problems.

      Later,
      Jon Howe

    Argh

    Argh

    This semester is going to be crazy.

    I just got done with my first morning class in more than a half of a year and I thought that I was going to die. I didn’t really care about the fact that it was a morning class, it was more about the class itself.

    My 9:30 class on Mondays and Wednesdays is Intro to Logic. The class seemed like it would be a good choice (plus it was required for my degree), but I didn’t think that it would be as boring as it was today.

    The Prof talked the whole time about things that seemed complely… well, logical to me. In other words, he talked about things that were obvious to me.

    I guess that this should make me happy that I have an easy class, but for some reason it leaves me a little scared.

    Historically when I get into situations like this, I tend to pay less attention in class and end up with a worse grade than I would if it was a harder class and I had to pay attention.

    Oh well, we’ll see what happens.

    I have a break from 11:00AM – 1:15PM, so I decided that I’d get some stuff done.

    I’m a big fan of IRC, and without my laptop here I have no way to use it. So I found a CGI based IRC client.

    I haven’t installed it yet, but I plan to before I leave for lunch.

    Later,
    Jon Howe

    Great Iptables Tool

    Great Iptables Tool

    I’ve been messing around with iptables a bit more than usual the past week or so. Through this process, I decided that it wasn’t worth it for me to keep creating / tweaking all of my rules by hand. So.. I found an Excellent (with a capital ‘E’) frontend to iptables.

    For me the frontend had to meet some strict requirements.

    1. It must have a curses graphical user interface
    2. It must be easy to use

    Something called Jay’s Iptables Fits these requirements perfectly.

    You can find all of the details at it’s website.

    Check it out!

    Later,
    Jon Howe

    Convert RPM to Deb + News

    Convert RPM to Deb + News

    I found a few cool things this morning.

    The first being a way to install a rpm file in Debian. You do this using the alien command (apt-get install alien).

    To convert a package from an rpm to a deb run the following command:
    alias --to-deb

    To just install a rpm use the following command:
    alias -i

    It's that easy.

    Also, I was looking at some stories on the front page of Digg, and found a Great New Library for use with Google Maps. It has the features of the one that I was messing around with earlier (I forgot the name of it). It even includes the features that I had to add inot the other library.

    Who knows, you might be getting a little tutorial on how to use this library soon.

    Later,
    Jon Howe

    How To Cache Apt Packages On A Network Using Apt-Cacher

    How To Cache Apt Packages On A Network Using Apt-Cacher

    If you’ve got more than one computer running Debian that packages are downloaded through apt, then apt-cacher should help you a lot.

    Apt-cacher is actually a cgi script that is run by apache. Using apt-cacher is very easy, and installing it is even easier.

    Step 1: Install apt-cacher.
    (Run this on the proxy computer)

    apt-get install apt-cacher

    Enter the webpage : http://localhost/apt-cacher
    to see that the proxy is running.

    Step 2: Backup and Convert Clients sources.list.
    (Do this on the computers that you want to access the cache.)

    cp /etc/apt/sources.list /etc/apt/sources.list.backup

    vi /etc/apt/sources.list

    Press ‘:’ while in vi.

    Enter “%s/http:///http://[Your Proxy IP]/apt-cacher?//g

    This searches through your sources and adds http://[Your Proxy IP]/apt-cacher?/ before every repository.

    An example from my sources.list looks like this:

    deb http://192.168.3.2/apt-cacher?/www.backports.org/debian/ sarge-backports main

    Step 3: Update Clients

    apt-get update

    Optional Step 4: Import Existing packages into the apt-cacher cache

    Copy the desired packages to the proxy directory /var/cache/apt-cacher/import

    Run the import script to make it so that apt-cacher can use them.
    perl /usr/share/apt-cacher/apt-cacher-import.pl

    Step 5: Use apt-get

    If the required previous steps completed successfully you should now be able to use apt with it’s connection proxied through your apt-cacher proxy.

    Questions / Comments, leave me a comment, and I’ll reply.

    Later,
    Jon Howe

    Okay…

    Okay…

    I did get something good out of this whole fiasco. When I think of it, this blog being down for a day or so is a small price to pay for the amount of knowledge that I gained relating to setting up apache, mysql, and php… Over and Over Again.

    Let me know if there are problems that you see.

    I’m pretty sure that mail is all screwed up because I have no mail server, or at least I hope that I don’t (I uninstalled it).

    However, that’s something that I’m going to work on next. I’m going to try to find a new mail solution, at least until a stable release of Hula comes out.

    I’m a pretty picky customer when it comes to mail servers. I want a mail server that’s got a lot of easy to use documentation, so it might be a while until the jonhoweonline.com mx record is active again…

    Some other things that I’ll be working on:

  • Running my own DNS
  • Setting up mod-rewrite for apache / drupal. This will make it so that instead of this site saying www.jonhoweonline.com/me/?q=node/1 it will say www.jonhoweonline.com/me/node/1
  • I am going to be starting an open source Content Management System (CMS) project with (primarily) a couple of my friends, so I’m going to get a cvs server up and running.
  • I hope to have some turorials out for all of those at some point or another,so stay posted!

    Later, and thanks for sticking with me,
    Jon Howe

    Copyright VirtJunkie.com © 2024