Distributed MythTV Support Script

It has been a long time since I had time to play with my MythTV setup, but now it finally works. It turns out that the biggest hurdle was not to split the functionality, nor to configure the channels (one just has to get one’s head around the way that MythTV looks at receivers, channels and providers…). The big hurdle was that one of my frontends are connected over WiFi.

The issue was that the frontend application was launched before the WiFi connection was established. This resulted in the frontend running some sort of configuration guide each time the system was booted. Having realized the source of the issue, disabled the autostarting of the frontend and added my own autostart script:


#!/bin/bash

TRIES=0

ping 192.168.1.201 -c 1
RES=$?

while [ "$RES" -ne "0" ]
do
sleep 1
ping 192.168.1.201 -c 1
RES=$?

let "TRIES+=1"
if [ "$TRIES" -gt "100" ]
then
exit -1
fi
done

mythfrontend --service

Here, 192.168.1.201 is the IP of the backend. The script ensures that the backend can be pinged before the frontend process is launched. The end result is a stable boot every time.

Skype to Redmond?

Rumors indicate that Skype might be sold to Microsoft. This only raises the urgency to develop a simple free competator. So, a good starting point is to list the very basic requirements:

  • Peer-to-peer sound and video streams
  • Global, distributed contact book
  • Encrypted media-streams
  • Potential support for conference calls (with one peer acting as server?)

So, how does one meet these requirements?

  • GStreamer can solve the peer-to-peer sound and video streams
  • Conference calls are not limited by gstreamer
  • Encryption can be solved by gstreamer (put an encryption / decryption element in the pipe)
  • The global, distributed contact book, is needed but can hopefully be supported by XMPP (Jabber).

The benefit of choosing XMPP is secure and flexible base to build a protocol on. There encryption keys and such can be exchanged, as well as synchronizing the setup and connection of peer streams. Using this protocol we could also support speech.

Another benefit, or risk, depending on how you look at it, is that this solution would be close to Google Talk.

Well, enough talking, I’ll do some prototyping later on and see what I end up with :-)

MythTV getting TV

For the last few months I’ve run a MythTV frontend/backend combination as our upstairs entertainment center. I use it for SVT Play using Tommy Persson’s excellent plugin, but also to play some music and act as a DVD player.

Yesterday a box arrived with my brand new Hauppauge WinTV-NOVA-TD stick (from a sale on netonnet). Last time I fought with receiving TV through a Linux system, it was a proper struggle. This time, it was just a matter of plugging in the stick, setting up the MythTV backend and watch TV (I admit – I did spend a bit of time sorting and filtering channels, but nothing advanced).

Checking the system this morning, it had recorded all three shows I asked it to – on time. Even the ones colliding in time, i.e. requiring the dual tuners to be used. Very nice!

Now, all I have to do is to setup my dedicated backend machine and get the connection between it and the frontend working. If that goes smoothly,  a card reader and soft CAM would be the next step, but boxer is charging 89+21 SEK per month for a twin card, so I guess that would mean setting up a new frontend downstairs…

Necessitas

So, I’ve fought with Necessitas for a while now. I reported a bug on a flawed install, but then I hacked around it. Basically, what I did was the following:

  1. Create a directory: /data/data/eu.licentia.necessitas.ministro/files
  2. From that directory, create a symbolic link, qt, pointing at /opt/necessitas/Android/4.7.60

Then it works. I’ve built and deployed wiggly onto a poor old HTC Hero and it all seems to play nicely this far – just have to wait for Ministro to download Qt. Next step is an application built around plugins that I’d like to deploy. Looks like I might have to read up some more. Until then – thanks for the great work, BogDan!

Spring Cleaning

I did some cleaning, sorting and updating of various computers at home this weekend. In the process, I found a cup heater from Trolltech – great stuff.

Side note – in the picture, Tux the Linux mascot, Trolltech cup heater, Microsoft Natural keyboard, Apple hardware and HTC Android phone. Talk about Qt everywhere :-)

The Sun shines again

As all great projects, this one started with a Dremel and some destruction. The back side of my external SCSI hdd boxes from sun was to receive a make over. One thing can be said about the boxes – they are heavy and now I know why. There was quite a lot of steel to cut through, but the results where nice.

To fit the board in the box, I superglued a set of distances to the chassis. There is about 2-3mm of margin to fit the board in, so it was tight.

Then I fitted a 80W PicoPSU. This allowed me to move the main part of the power supply outside the box, as the PicoPSU is powered by a 12V DC power brick.

To get the power through, I had to make an extra hole in the plates for the motherboard’s connectors. That is how tight the fit was. No additional space on the back side to drill an additional hole.

The system is run from an 8GB CompactFlash card. Most cards can apparently be used as an PATA/IDE drive. As the CF-to-IDE converter had a floppy drive power connector, I had to build a cable for it. Also, notice the tape in the top right corner of the converter – it covers a really bright red LED.

And here is the real LED. It is green and it is original. Connected nicely with the HDD activity pins of the motherboard.

So, here it is again. A sun box has sparked into new life.

Status Update

It has been quite a while since I last blogged. As always, there is not a single reason for this, but the major one is that have been swamped with work. This text will be a small re-cap and a way for me to start with a fresh-ish slate this year.

First of all, the Qt in Education material is finally completed. I was at the München Qt DevDays and presented what we had then. Since then the slides and exercises have been completed and received a polish. There is already a small errata in the Qt DevNet wiki. I choose to interpret this as a Good Thing – people are using the material.

Just after the new year, a team from Pelagicore attended CES. I did not go there this year (small kids change your priorities) but worked hard on a set of Qt-based demos that we ran there. The demos (and Pelagicore as a company) are focused on in-vehicle infotainment, or IVI as it is commonly written. Of course there are a million things that I as an engineer want to polish or add, but as a whole the event was a success.

So, there it is, a new starts. Now I will try to blog more frequently.