Shop OBEX P1 Docs P2 Docs Learn Events
Digitizing old computer cassette tapes — Parallax Forums

Digitizing old computer cassette tapes

blittledblittled Posts: 681
edited 2013-10-18 16:22 in Propeller 1
I have an old fussy Timex Sinclair 1000 and a small collection of tapes and I cannot get the TS1000 to load my tapes. I was wondering if the ADC on the Activity Board could sample the audio output of a cassette player, condition/capture it, then either through a RC filter or the DAC feed it into the audio input of the TS1000? Eventually I would like to do the reverse and capture the saved output so I can read and store files on an SD card rather than on a cassette player. I do have the documentation on the serial protocol/timing of the serial I/O of the TS1000 and I know it would be fairly easy to write PASM to convert the serial I/O.

Comments

  • Beau SchwabeBeau Schwabe Posts: 6,566
    edited 2013-09-05 06:01
    Wonder if this would work?

    http://www.epanorama.net/sff/Computer/Misc/Computer%20Tape%20Conditioner.pdf

    Looking at the schematic, it looks like it could be greatly simplified if you just want the RAW output... the 7432 is an OR gate and could be removed, the 74368 is an inverting buffer that could be eliminated, where the inversion could be compensated in the input polarity switch. .... That said you could most likely directly read the audio with the Propeller..... or at the most have a very basic pre-amp just before the Propeller.
  • Dave HeinDave Hein Posts: 6,347
    edited 2013-09-05 06:23
    You could digitize the tape to a wave file by capturing it through the sound port on your computer. You could then write a program on your PC/Mac/Linux box that converts the wave file to a digital file. Or post the wave file to the forum and run a contest to see who can decode it first. That way, you get the digital data, and the winner gets the honor of being the first to decode it. :)
  • prof_brainoprof_braino Posts: 4,313
    edited 2013-09-05 06:58
    Is this just for the fun of digitizing those exact tapes, or do you just want to reach the goal of saving the stuff in a modern format?

    My brother was in a similar situation when he switched from cassettes to floppies. He knew what was on most of the cassettes, but the data had faded from just being old and low quality tapes. It was easier to find stuff already out on the net for most of it. He just re-typed the code for most of the rest. The remainder, that ended us getting lost, were just experiments that didn't work anyway.

    It think his whole box of tapes ended us on one floppy, and the whole collection of floppies eventually ended up on one CD. Then he lost the CD. :)
  • ercoerco Posts: 20,256
    edited 2013-09-05 07:14
    @Braino: Are you sure?



    Sounds more like MY brother, losing the CD after all that. :)
  • blittledblittled Posts: 681
    edited 2013-09-05 08:16
    Thanks Beau that article may be helpful. Maybe I am reinventing the wheel. There are many tools which can convert the ZX81 tape signal into digital format (.p files) or back into .wav files. In fact there is a simple IDE for writing ZX81 programs on a PC and many write a program on an emulator such as EightyOne, first then convert it and record it on cassette. I just thought it be nice to have a player/recorder that didn't require a PC and used modern storage options. But that too has been done with the ZXpander that reads and stores into a SD card.
  • Bob Lawrence (VE1RLL)Bob Lawrence (VE1RLL) Posts: 1,720
    edited 2013-09-08 08:05
    Did you try cleaning the read heads on the Timex Sinclair 1000 cassette unit?

    I remember back in the Commodore days I used a regular cassette drive with a few parts on a breadboard to convert the audio to TTL digital and it worked great. Although I don't remember the chip/s
    It was a chip like a 7414: HEX Inverter Schmitt Trigger.


    Here's what they used on the Commodore systems back then.
    http://en.wikipedia.org/wiki/Commodore_Datasette

    Inside the tape device the read head signal is fed into an operational amplifier (1) whose output signal is DC-filtered. Op-amp (2) amplifies and feeds an RC-filter. Op-amp (3) amplifies the signal again followed by another DC-filter. Op-amp (4) amplifies the signal into clipping the sine formed signal. The positive and negative rails for all op-amps are wired to +5V DC and GND. The clipped signal therefore fits into the TTL electrical level window of the schmitt trigger step that in turn feeds the digital cassette port.[7]


  • blittledblittled Posts: 681
    edited 2013-09-09 08:49
    I found out that my TS1000 wasn't that fussy. I am so used to putting phono plugs on my various Propeller boards for audio that I plugged phono plugs into the TS1000 which fit but I found out that 1/8" mono plug needs to be used. Once I made the switch it worked great!

    Thanks for the suggestion Bob that may be the easiest way to digitized the audio. I was thinking of using ADC but a Schmitt Trigger would be easier.
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2013-09-10 08:58
    So you are playing wav files back from the Propeller to the TS1000? cool beans :)

    Jeff
  • blittledblittled Posts: 681
    edited 2013-10-17 13:23
    I used an Activity Board and a 16 x 2 back lit serial LCD and I have made a project that reads a .p (ZX81 file) from a SD and convert it to an audio format the ZX81 understands. The LCD and two momentary switches are used to navigate through the SD card using Kye's fat engine and select a file. I modified the transmitting half of the FullDuplexSerial object to create audio pulses to send to the ZX81. So far every file I tried reads into the ZX81 with no problem. Now I need to figure out how to take the audio out of the ZX81 and convert it back to .p files
  • kwinnkwinn Posts: 8,697
    edited 2013-10-17 20:43
    After looking at the writeup from the link Beau posted I would think it should not be too hard to do. Use a comparator (or schmitt trigger) to produce a square wave from the casette output, input that to a prop pin, and measure the time between the center of each pulse. A second pulse approximately 1000uS later would be a 1 bit, otherwise it is a 0 bit. Easy timing for a PASM program to handle.
  • blittledblittled Posts: 681
    edited 2013-10-18 05:03
    kwinn, I agree but it is a little trickier than detecting a pulse being high or low. The ZX81 produces 4 pulses in a 300 uS cycle for a low bit and 9 pulses for a high bit with a 1300 us pause between bits. So rather than a check every 1000 uS you should wait for a transition from low to high, measure the timing from the last transition to see if it is a pause or not. If it is then start counting pulses and if not increment the pulse count.
  • kwinnkwinn Posts: 8,697
    edited 2013-10-18 16:22
    blittled wrote: »
    kwinn, I agree but it is a little trickier than detecting a pulse being high or low. The ZX81 produces 4 pulses in a 300 uS cycle for a low bit and 9 pulses for a high bit with a 1300 us pause between bits. So rather than a check every 1000 uS you should wait for a transition from low to high, measure the timing from the last transition to see if it is a pause or not. If it is then start counting pulses and if not increment the pulse count.

    My mistake. I thought the signal was like the one in the link Beau posted, a clock pulse followed by the data (pulse for one, no pulse for zero). What you describe is a bit more complex, but it can still be decoded by counting pulses and measuring the time between them, something the propeller excels at.
Sign In or Register to comment.