Many years ago, I tried the OTLA software (link) and after plenty of fiddling with audiocard settings: it worked!

I was amazed at the 'tape' loading speed. This is close to 20 kilobits/s: witchcraft.

A few weeks ago I tried to figure out how they did it and if it would be possible to create these files myself.

It would be nice if you could 'auto-OTLA' .cas files to the MSX.

OTLA uses a few tricks to speed-up tape loading:

- It uses coding for bit patterns '00','01','10' and '11'
- Does not use start/stop bits
- Uses a much higher (maximum) frequency of around 20kHz

Normal MSX tape routines use 11 bits to encode a byte (single startbit, 8 data bits and 2(!) stopbits).

Given a maximum frequency f, a '1' is encoded as 2 cycles of frequency f, and a '0' is encoded as one cycle of f/2.

This means that all bits have the same length:

In OTLA, this is not the case. Here the patterns are encoded with different number of samples. An example:

Now let's encode a byte with value 11100100b

On the MSX:

Using OTLA (msb first):

For MSX encoding: 44 samples and for OTLA: 14 samples.

So OTLA is ~70% faster using the same maximum frequency.

With OTLA, the bits do not have the same length. Files with lot's of '11' patterns will

be 'longer' than files with lot's of '00' patterns.

A short (not representative) check on my MSX files showed that the '00' pattern occurs

almost twice as much as the rest. If this is true, OTLA would be even a bit faster.

There are some issues however with the OTLA software:

It seems to incorrectly calculate the length of the file (one byte less).

Due to the way the samples are created, the file can have a DC offset.

The poke -1 value is not optional. You need to provide it.

Also, the MSX loader program is not that well documented. That's the next task.