Blog

Software

AN.

Blog

Adventures in Teletext Recovery

7 May 2019 | Updated 29 May 2022

Before I had Internet access at home, I used to use teletext to get my fix of Digitiser and chess pages. Sometimes a horoscope for my amusement. Using it was as simple as a telephone: type in a 3 digit number, wait a bit and up popped the page of text. It was not a fast medium, and prone to interference, but it worked well. Later on, I would use Freeview's MHEG-5 digital text to revise for my GCSEs.

I always thought that the pages I'd seen were lost to history. After all, there is no offical archive of teletext pages, and I always thought video recorders cropped off the relevant lines from the picture. (Pressing text while watching a videotape does nothing, you see.) But that's not correct! The teletext lines are indeed recorded onto tape, but the fidelity of VHS isn't high enough for the teletext decoder to work out the data.

Thanks to modern PCs, TV capture cards and most importantly of all Alistair Buxton's vhs-teletext software, it is now possible to capture the teletext lines from VHS tape and recover the pages. My nostalgia compels me to try and get some history!

This post is going to be part what-I-did and part tutorial for anyone else looking to do the same.

Installing the Software

vhs-teletext needs Python 3, VBI recordings (the part of the picture with teletext data), and ideally Linux. I decided to install Ubuntu 19.04 as it had the latest version of Python, supported my capture card, and worked on the computer I was intending to capture with.

After installing Ubuntu and cloning the repository from Github, installing the software needed the following commands:

sudo apt install python3-setuptools python3-numpy python3-scipy python3-opengl sudo python3 setup.py install

Getting a Capture Card

Attempt One: Compro C100 [SAA7134]

I already had a capture card with a Philips SAA7134 chip, so I thought I'd try that first. The VBI device /dev/vbi0 was available, and I could see the video picture itself via mplayer. However, all my attempts to record VBI data with this card failed. I suspect it's down to a configuration issue, and I might've been able to modify the SAA7131 file to work with my SAA7134 until...

Attempt Two: Pinnacle MiroVideo [bt848]

I decided to get my hands on a Brooktree 848 based capture card. Alistair uses a bttv card, so this seemed to be the easiest way to get up and going. I bought it, removed the Compro C100 and inserted this one.

The card also exposed /dev/vbi0, but I could not get a picture at all through mplayer. It was just a green screen. I learned through dmesg that the bttv driver was attempting to autodetect the card I have, without success. Luckily, it is possible to tell it which one I have with a configuration file. So, in my installation of Ubuntu 19.04, I created a bttv.conf file with these contents:

options card=1 tuner=0 radio=0

One reboot later, I had a picture and VBI data as well. I switched from using composite video to S-Video in order to get a sharper picture. Although my VCR does not transmit any colour information through S-Video, teletext doesn't use it. It improved the results considerably.

Capturing the VBI

Use this command to start recording the VBI data to a file:

teletext record -d /dev/vbi0 > your_file.vbi

(If you have more than one capture card installed, the device might not be vbi0.)

It's a good idea to capture a few seconds, then inspect the file to make sure you are actually getting something. CTRL-C stops it. You can inspect the recorded VBI data with the command:

teletext vbiview your_file.vbi

This will bring up a window that shows you the recorded VBI lines, two fields at once and stretched vertically for easier viewing. Areas highlighted in green are recognised as potentially being teletext data, red is not. Here are some examples from my recordings:

Blank VBI.

Blank. There are several possible explanations for this: a problem with the capture card, the input source is wrong, or the video tape you're capturing doesn't have any teletext on it. (e.g. a recording from Freeview.)

Garbage VBI.

Teletext data is possibly there, but the signal is all over the place. Check the main video - you will probably find it is noisy. Make sure the tape is OK, the heads are clean and the tracking is correct.

Misaligned VBI.

Better, but still not quite right. One of the heads is not reading that bit of the tape perfectly. If you attempt to decode this, you will not get any complete pages.

Valid VBI.

The data is there and all aligned correctly.

If all is good, then you can make a longer capture. Although even a few seconds can yield a whole bunch of pages (one half page per field at 50 fps can add up fast), a 10 minute capture is a good minimum. Recording the whole programme might help the decoding process even more, at a larger time cost.

Decoding the Pages

Once you have the VBI file, decoding the data can be done with this command:

teletext deconvolve your_file.vbi > your_file.t42

Be warned, this is the slowest part of the whole process. It seems it can be sped up with a CUDA compatible graphics card, but I don't have one.

When the decoding is done, you can try to make the stream more accurate. Teletext pages are repeated over and over again. By comparing all given instances of a particular page, a "most likely" version can be generated. This is why a long recording can be better. The command to do this is:

teletext squash your_file.t42 > your_file_squashed.t42

If you want to get an overview of the pages within your decoded t42 file, you can filter out all the first/header rows:

teletext filter -r 0 your_file.t42

And to view a page, you can use:

teletext filter -p 100 your_file.t42

Every single version of the page within the stream will be shown.

Interesting Finds

Here is a selection of some pages I thought were amusing.

Digitiser front page. Digitiser article.

I did find one complete Digitiser set during this experiment. You can find more Digitiser content at Super Page 58.

Westcountry region teletext index page. Local birthday greetings.

I completely forgot about the old ITV Westcountry region branding and idents.

BBC diet clinic. BBC stop and search procedures.

Pages from BBC's internal teletext service Telfax were occasionally broadcast within data packets alongside Ceefax.

Oracle animated steam train test page. Mysterious teletext log page 6AA.

An Oracle test page testing 'hold' graphics, and a Teletext status log. I don't know what it means.

Sauce index page. Preview of Babylon 5.

The front page of the short-lived teen magazine Sauce, and a 4-Tel preview of Babylon 5.

CBBC Studio 9 index page. Blue Peter index page.

CBBC: Studio 9 and Blue Peter.

All teletext page contents are © their relevent owners (BBC, Oracle, and Teletext).

This was a nostalgic experience, and there are at least 400 more hours of tape to sift through. Even the gaps between two different recorded programmes can uncover lost pages, so everything must be watched. I might revisit this topic with more screens in the future.

 

Updates!

I originally wrote this article in 2019, when I was still relatively new to teletext recovery. I have checked over the instructions, and they are still valid for the current version of vhs-teletext.

I have also added a few more screens to this page, but you can find lots more from a wide variety of services in The Teletext Archaeologist's archive.

Return to Blog Index

2024

2023

2022

2021

2020

2019

2018

© Andrew Nile 2018-2024. Privacy