Mar 142012

This is just a quick and dirty script to delete MythTV recordings that had been previously transcoded and moved to the stream directory, but have since been autoexpired out of MythTV. This is an issue because trying to pull data outta the MythTV recording database about a recording that has been deleted causes an error because the entry isn’t there anymore. All it does is loop through each file in the stream directory and if it doesn’t exist in /var/lib/mythtv/recordings/ it gets deleted.

Contents of:
/usr/local/bin/ Continue reading »

Mar 142012

Since I’m already transcoding the recordings to h.264, might as well make them easily accessible to my iPhone or Boxee Box or Miro. Since the filenames are more likely to be seen, might as well make them more human readable. The biggest advantage to this renaming a season of a recorded show for archiving using filebot. If you want to get fancy, could use tversity to stream the rss feed to a playstation 3 or an xbox 360, but I still think the Roku is the easiest frontend for previously transcoded material.

Disclaimer: I’ve removed a few things specific to my oddball setup so I can’t guarantee I didn’t break anything.

Contents of:
/usr/local/bin/ Continue reading »

Mar 142012

Before I forget, here’s my MythTV UserJob1:
/usr/local/bin/ %DIR% %FILE%

This script runs on a MythTV recording to remove commercials and transcode to h.264 video that I’ve tested and will play on Android (Motorola Droid), iPhone (iPhone 4), Roku DVP (Original Roku Netflix Player), Boxee Box, and in Miro on Windows.

The contents of
/usr/local/bin/ Continue reading »

Mar 142012

Once the files have been created, will need to create an XML file the brightscript program on the Roku DVP can parse to display show data. This bit of perl reads the stream directory, sorts by file creation date, picks out the .mp4 files, uses the MythTV bindings to pull out show data, smashes it into some XML and writes it to a file.

Contents of:
/usr/local/bin/ Continue reading »

Mar 142012

This is a lot of the rest of the important configuration changes. I’ve added the bandwidth module (more info available in my previous post: Apache 2 bandwidth control) and enabled port 8080 as well since Cox Communications blocks traffic on 80 and 443. Continue reading »

Mar 062012

As soon as I knew they existed, I got a Hexbug Spider. I wish these things existed when I was little. It is COOL!

Now that I’m older and can buy toys for myself, I can do more interesting things with my toys. The Hexbug is IR controlled, like a tv remote control. I have a Microsoft MCE IR blaster connected to a Mythbuntu linux box. LIRC is pretty easy to configure.

Of course this is just a substitute remote control. It isn’t as awesome as what EMGRobotics is doing with the hexbug spider. The biggest advantage of a computer remote control is scripting moves!


Continue reading »

Nov 202011

One of my first experiences with mythtv was restoring a recording and a dump of the MySQL database before I could buy my own tuner card. It was cool to see recordings populated and get a feel for the UI, but it was ultimately pretty pointless. Anyhoo, I bork’d my mythbuntu setup and needed to migrate my previous recordings to another installation. Come to find out, this has gotten so much simpler than ever before! Continue reading »

Oct 252010

My MOTD was lacking, so it got prettied up a bit. I have Apache available externally for Mythweb and transcoded shows. I like to keep an eye on recent accesses.

raging@mythbuntu:~$ cat /etc/update-motd.d/40-apache-hosts
echo "nRecent Apache Accesses"
cat /var/log/apache2/access.log | cut -f1 -d" " | sort | uniq

I loved when mythtv-status was included in mythbuntu, but is in the repository. I missed this feature and wished to have it again.

sudo apt-get install mythtv-status

… but that didn’t quite work. The fix is in this gossamer-threads link.

I didn’t have a MTA configured, and I just wanted to email upcoming recordings to myself, so I set up sSMTP

I got an error
Use of uninitialized value in numeric gt (>) at /usr/bin/mythtv-status line 867.

I love the open source community! This problem had already been identified and solved so i just needed to apply the included .patch file.

I’m including it here again for my convenience if i were to need it again soon,

--- /usr/bin/mythtv-status.orig 2010-11-17 09:52:08.043031500 +0000
+++ /usr/bin/ 2010-11-17 09:36:51.347027492 +0000
@@ -10,6 +10,9 @@

use LWP::UserAgent;
use XML::LibXML;
+# $Date::Manip::Backend = 'DM5';
use Date::Manip;
use Getopt::Long;
use Text::Wrap;
@@ -864,7 +867,7 @@
for my $key (@{ $block->{'human_readable_sizes'}}) {
for my $unit (@size_thresholds) {
if (defined $unit->{'threshold'}) {
- if ($vars->{$key} > $unit->{'threshold'}) {
+ if (defined($vars->{$key}) and $vars->{$key} > $unit->{'threshold'}) {
$vars->{$key} = sprintf("%.1f", $vars->{$key} / $unit->{'conversion'});
$vars->{"${key}_unit"} = $unit->{'unit'};

Mar 152010

So, quite a bit has happened, inspired by mythtv podcast post.

Video podcast client Miro works really well

TVersity is a upnp media server that will pull in content from an RSS feed, such as the one on my MythTV box… This enables playback on the Xbox 360

Of course, this is the reason for the Apache2 bandwidth control post, since I am not very happy with the bandwidth shaping options in pfsense

I suspect a firewall upgrade is in order… My friend just raves about Untangle, and for good reason. The latest version now includes captive portal, and I will not have a network without multiple separated interfaces… Perhaps soon.