I got interested in writing my own code to parse tape cassette formats for a few platforms. I did OK with both Spectrum and Apple 2 tapes based on info I could find online.
Speccy and Apple 2 seem to be relatively similar, both using frequency modulation where I can measure the intervals between the places the sound wave crosses 0, with different sized intervals representing things such as leader tone, sync pulse, and 0 bits and 1 bits.
But I've had no such luck with TRS-80 tape audio. I'm focusing on Model 1 Level 2 BASIC saved in .wav format for starters.
I can find info on the layout of the bytes in the tape data, but I can't find detailed info on how the bits are encoded as audio, but it seems use a technique somewhat different to what Apple and Sinclair used.
How can I parse the audio? I'm basically asking the same as has been asked about the Apple ][ in this question.
Here's part of the waveform of a very tiny program with a bit of the leader and all of the data loaded in Audacity:
.casor a tool to convert the former to the latter. MAME only supports
.wavand the current version trs80gp seems to produce bad
.casfiles. I sent a message to the author/maintainer. I forget if that waveform is a save of the null program, just doing
CSAVEwith no program lines, or if it's the program that's just