Shop OBEX P1 Docs P2 Docs Learn Events
Tape Loading? — Parallax Forums

Tape Loading?

speewavespeewave Posts: 11
edited 2012-04-04 08:34 in Propeller 1
Being born way after data was on cassette, I was always kinda interested in how tape loading worked for old computers. so i wanted to try it on a propeller for the heck of it :nerd:, see if it's something i could actually just go and try, but i'd thought i'd double check if my methods for doing it are good while i wait for the parts to experiment (should get my QS board by the weekend :thumb:)

Anyway, Heres the process i had for loading data (just basic, if i get it to work, i'll add a bit more to it (checksums and all that good stuff)

- Make a program
- Convert it to raw data <use audacity>
- copy it to a cassette or play it from an ipod or something

- Get Audio from Tape (dumb question, do i need an ADC chip since the analog signal is digital data?)
- Stream data in to a section of RAM?
- Execute the Data.

So i was wondering, does this sound like it'll work?, is there any thing i should probably consider before doing this?

Thanks in advance for your help

Comments

  • pinedustpinedust Posts: 19
    edited 2012-04-03 20:11
    This gives me flashbacks of my TI 94/A days in the early 80s. I want to try it, why, hehe, why not?
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2012-04-03 20:59
    The circuitry shown is unnecessary as you can feed the signal from the Prop as an analog waveform via the normal RC analog output circuit into the MIC of the tape recorder and forget about converting in an external program. As for the audio out I would just feed that from the SPKR through a current limit resistor and coupling capacitor straight into a Prop pin while relying on it's 1.5V switching threshold by biasing that with a couple of resistors. So 4 resistors and 2 capacitors should be all that you need. However the old program loader cassette was never all that reliable and I would imagine that you could never expect to "stream" the data directly in and expect it to be error free. The best way would be to packet the data along with appropriate headers and checksums/CRCs and also repeat those same packets so that if an error was encountered in one then it is possible that the next one might be read error-free. Of course you could go further and employed some ECC codes to help recover a bad read but unlike a disk driver there is no way to reread a bad read.

    The old MPF circuit is interesting in that it had to buffer the output of the comparator because the 8255 I/O used "latching" inputs which would try to pull-up or down the input without the use of external resistors. I never used them but they were so popular but were always so sensitive to glitches and lacked output drive. The transistor was only required for the internal speaker/led.
  • AribaAriba Posts: 2,690
    edited 2012-04-03 21:11
    The Propeller inputs are designed for analog usage, they have a sharp threshold at ~1.45V, so I would try a simple circuit like the attached first.
    I've found the output can be just a resistor because there is anyway a capacitor at the Line input.

    Andy

    PropCassette.gif
    294 x 173 - 1K
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2012-04-03 21:38
    Take a look at the Bell 202 Modem object in the OBEX. I think it will do everything you want, and it includes a schematic for how to send and receive the signals.

    -Phil
  • Heater.Heater. Posts: 21,230
    edited 2012-04-03 22:46
    Back in the day this was done by recording a particular tone on the tape to represent a "0" bit bit in the data and a different tone for a "1" bit. From wikipedia we see that In the Kanasas standard it was "A '0' bit is represented as four cycles of a 1200 Hz sine wave, and a '1' bit as eight cycles of 2400 Hz"

    Back in 1981 we did this using a 6809 processor using just a UART chip and some timers. No nice sine waves recorded just slightly smoothed square wave.

    Have a search for "kansas city standard" or CUTS "Computer Users Tape Standard".
  • Cluso99Cluso99 Posts: 18,069
    edited 2012-04-03 23:10
    Memories... CUTS.
    Cut my teeth on these thing (pun intended). Back in 1976-1977 the Motorola MC6800 D1 & D2 boards were used with tape to record the program. Perhaps it is worth looking at the circuit used on the D2. My boards went to the trash just over 10 years ago. However, I have a friend who had borrowed my D1 & D2s and has bought some D2s recently. He found the circuits on the web.

    Of course, using an iPod would be cheating beause those tapes were so poor on quality and so were the transport mechanisms.
  • Toby SeckshundToby Seckshund Posts: 2,027
    edited 2012-04-04 03:26
    Sadness states that, I have thought of such stuff too. I still hang on to a couple of 3.5" Floppy drives just in case ... (not that I could find any disks now!)

    On a TV programme recently one of the boffins said that the only reliable long term data storage would be punched paper tape. I haven't got any of that, anymore ...
  • Jay KickliterJay Kickliter Posts: 446
    edited 2012-04-04 05:27
    On a TV programme recently one of the boffins said that the only reliable long term data storage would be punched paper tape. I haven't got any of that, anymore ...

    I've had an idea for long term data storage. Etched sheet metal, similar to a solder stencil. You could use a flatbed scanner, or the equivalent in the future, to retrieve the bits. A sheet of Monel will hold those bits for a very long time.
  • BeanBean Posts: 8,129
    edited 2012-04-04 05:50
    Sadness states that, I have thought of such stuff too. I still hang on to a couple of 3.5" Floppy drives just in case ... (not that I could find any disks now!)

    On a TV programme recently one of the boffins said that the only reliable long term data storage would be punched paper tape. I haven't got any of that, anymore ...

    I recently found a 8" floppy at work. I couldn't bring myself to throw it away.
    I'm saving the 8" floppy, a couple 5 1/4" floppies and a couple 3 1/2" disks to show my son when he grows up.

    Bean
  • cavelambcavelamb Posts: 720
    edited 2012-04-04 08:34
    Andy,

    MUCH better!
Sign In or Register to comment.