26/2-96
            .--.                                .--.        .--.       
  ___      /    \      --The BBC Tape Utility--/    \      /    \___ 
     \    /      \    /                              \    /
      `__'        `__'                                `--'

This is my first release of the BBC Tape Utility. If you should find
any bugs or if you have suggestions or improvements then please send
me an email. <os@imm.dtu.dk>


DESCRIPTION
===========

The BBC tape utility  runs on a Linux system with a digital audio 
device, such as /dev/dsp. It can be used to load and save BBC-format
tape files. Both loading and saving can be used realtime while the
tape runs. You can also read and write WAV-format files on your 
hard disk, for example if you wish to do some non-realtime filtering. 
Decoding files from harddisk is approximately 18 times faster than
when decoding from tape (at least on my P100), and the process uses
little cpu time.


INSTALLATION
============

The installation is very easy. Compile the file bbc-save.c with

 gcc bbc-save.c -lm -o bbc-save
 
This should generate a executable file bbc-save used to encode files. 
To use the load utility you have to generate a symbolic link with

 ln -s bbc-save bbc-load
 
The symbolic link should then work as the decoder. Note that the 
filenames has to be bbc-save and bbc-load for the program to
work.


THE COMMANDS
============

bbc-load [options] [filename]
bbc-save [options] tape-filename load-address exec-address [filename]

options             | Description              | default value
--------------------------------------------------------------
-d device           | use another device file. | /dev/dsp
-f freq Hz          | sample frequency.        | 44100
-r baud-rate        | baud rate of file.       | 1200
-s block-size       | block size of file.      | 256
-b start/stop bits  | start and stop bits.     | 0/1
-w wav-file         | use wav file.            |

NOTE: '-' can is used as a wav-filename to specify in-/output
      from/to stdin/stdout. This utility is meant to be used with
      the programs sox and vrec to filter noicy data.


To test the saver and the loader you could convert this file to
a wav file and pipe it directly to the loader with

 cat README | bbc-save -w - readmefile 0xbbc 0xcaffe | bbc-load -w -

which should print this document to stdout.

You can also try other baud-rates, for example 600. Also non standart
baud rates will work. I succeded using up to 5500 baud with a sampling
frequency 44100 Hz, this was using only the WAV files and no tape.
I will suspect no sane person will try use this program to backup a 
harddisk :-)


KNOWN BUGS
==========

Problems of freeing shared memory. This might be connected to my second
problem which is how to stop the program nicely without killing someone. 
Sometimes the processes hang, and you have to shoot them down manually.

Propably a laat of spelingeors.


FURTHER PROJECTS
================

 o  A decoder/encoder for transfearing data over short wave radio.
 
 o  A multitrack harddisk recording system. ( like SAW+, but better :)
 
If you are interested in any of these subjects and/or have suggestions,
then please contact me. 
 

THANKS
======

Robert Schmidt <robert@idt.unit.no> for information on the BBC tape 
  format and for some audio samples from some of his old (and USED)
  tapes. Check out his The BBC LIVES html page 
  <http://www.idt.unit.no/~robert/bbc/bbc.html>

The BBC Micro Emulator mailing list and the people who are working
  hard on their own BBC emulators. 

---------

Ole Stauning <os@imm.dtu.dk>
