UK Vintage Radio Repair and Restoration Powered By Google Custom Search Vintage Radio and TV Service Data

Go Back   UK Vintage Radio Repair and Restoration Discussion Forum > Specific Vintage Equipment > Vintage Computers

Notices

Vintage Computers Any vintage computer systems, calculators, video games etc., but with an emphasis on 1980s and earlier equipment.

Closed Thread
 
Thread Tools
Old 27th Dec 2020, 8:41 pm   #1
twostickes
Triode
 
Join Date: Dec 2020
Location: Durham, County Durham, UK.
Posts: 20
Default MK14 Tape Interface

Hi, first post!

I'm working on testing a tape interface (SOC MK14) and had some old tapes with unnamed programs on from 70's / 80's but had an idea. If I recover the programs I would like to recreate some new tape files, for loading into my MK14. To do this I've written a utility program to convert Intel HEX formats into WAV files, and posted onto github " twostickes/MK14WAVwrite " if anyone is interested in using it or collaborating on it. There is an example already posted there, DUCK.HEX gets converted to duck_f12.wav. The .exe program is also there to convert other HEX files to WAVs. Its V1.0 and plenty of "to do" !
twostickes is offline  
Old 27th Dec 2020, 10:32 pm   #2
SiriusHardware
Dekatron
 
Join Date: Aug 2011
Location: Newcastle, Tyne and Wear, UK.
Posts: 11,484
Default Re: MK14 Tape Interface

Hi twostickes, welcome to the forum. I'm just up the railway line from you here.

As you may have noticed there are quite a few MK14 threads on this forum, some of them older and now closed. All of them have a lot of useful information in them if you have about 100 years to spare to read through them all.

I'm probably not clever enough to help you to refine your converter program directly but I do have a modern MK14 replica, an original MK14 and also an original MK14 tape interface PCB as well, so I may be able to help with some independent testing. I think fellow forum user Timbucus also has a cassette interface as well, possibly a homebrew version in his case.

As a new forum user your posts will be delayed by moderation at first, but that will eventually wear off after you have made a few more posts and you'll then be able to post in real time.

Maybe you can explain what you're using by way of hardware - original MK14? / Replica? and what it was that kick-started your interest in them originally - maybe you owned an original machine back in the day?
SiriusHardware is offline  
Old 27th Dec 2020, 11:58 pm   #3
Timbucus
Octode
 
Join Date: Mar 2019
Location: Barry, Vale of Glamorgan, Wales, UK.
Posts: 1,362
Default Re: MK14 Tape Interface

Welcome indeed

Sounds an interesting project - I have a repro tape interface (made on an exact PCB replica of the SoC one by Martin). I also coincidentally today have been using Karen's tape deck with built in tape interface - on her PIC MK14 but, I intend to hook it up to my machines.

I have cloned into the code - I use Linux but, it looks like it only has some library issues around sin and itoa - I will see tomorrow if I can record and reload the WAV you created at least until I get time to look at compiling the code locally.
Timbucus is offline  
Old 29th Dec 2020, 1:40 am   #4
SiriusHardware
Dekatron
 
Join Date: Aug 2011
Location: Newcastle, Tyne and Wear, UK.
Posts: 11,484
Default Re: MK14 Tape Interface

You should be able to miss out the recording step by just playing the .WAV file out of any digital device (phone? / tablet? / laptop? / desktop PC?) with a headphone socket, although the maximum level out from such devices will vary a lot from device to device and may not go 'loud' enough to drive the audio-in on the cassette interface PCB properly.

I would also use only one of the two stereo output channels plus GND, definitely do not connect the left and right headphone channel outputs together even if the .WAV file is mono.
SiriusHardware is offline  
Old 31st Dec 2020, 12:50 am   #5
twostickes
Triode
 
Join Date: Dec 2020
Location: Durham, County Durham, UK.
Posts: 20
Talking Re: MK14 Tape Interface

Hey guys thanks for these responses!
siriusHardware - yes just down the road!
I've trawled through the MK14 schematic revisions thread (book!) nice to see all the old MK14 is not dead yet, seems like it is still evolving!
I had a issue iv or v in 1979 cant quite remember which one. Also had tape and vdu. Screwed it all on a slab of chipboard, and made some side walls with another slab on top to place tape recorder and portable TV. It weighed a ton! Learned all my "bare metal" skill programming on it, as its called these days.
I have wrote an app (android) to emulate an MK14, but I was too slow and Studio, Java, etc keeps getting ahead of me , its now Kotlin, changed API's etc so I cant complete it, no time really!
So last year I bought some replica boards, VDU etc from Martin to build one up, for nostalgic reasons, I haven't quite built them up yet.
However I recently took the plunge and bought up two vintage MK14's (ii and v) but are not quite vintage. Cost a fortune! Hoping to put them back to vintage soon. They both came with vintage tape interfaces and have most vintage parts. One of them has the rapid keypad programmer, which I now use and can squirt a hex file over virtual COM port over USB and saves they keyboard. For vintage purposes I wanted to make up some tapes using software to convert intel HEX files (as outputted from TASM) direct to WAV files, so the WAVs can be stored and played back on a PC (or saved to real cassettes), hence this thread!
I have no idea if anyone else would have a use for it.
Ive thought of 1 improvement - I remember setting F0 high for a few seconds while recording on tape, to get rid of the AGC effect, before sending the data. So I might include a command line option to do this, ie the WAV will then have a 2 second "preamble".
Thanks for that awesome thread! I wish I found it years ago!
Hope 2021 is a better year for us all!
twostickes is offline  
Old 3rd Jan 2021, 5:14 pm   #6
SiriusHardware
Dekatron
 
Join Date: Aug 2011
Location: Newcastle, Tyne and Wear, UK.
Posts: 11,484
Default Re: MK14 Tape Interface

Hi twostickes. You deserve a medal for making it all the way through the 'MK14 revisions' thread and I'm afraid there are some more very long MK14 threads if you go looking for them. Most have been automatically closed since the last post in them was some time ago, but a polite request to the mods will get any closed thread re-opened if you want to add further input to any of them. We could probably do with a sticky post called 'MK14 threads' with links to all of the MK14 threads to date to make them easier to find.

I think I remember that MK14 which was sold with - I think - an Arduino based serial to keypad injection loader - did it come from Guisborough? (A detail I noticed since I happen, under normal circumstances, to go past that town twice every weekend).

We welcome any and all MK14 developments and projects including ways of getting code into the machines more easily than by typing the code in by hand as even the MK14's greatest fans would acknowledge that was a very tedious task, especially when the machine would forget everything the instant it was turned off. Back in the day, the cassette interface really was a lifesaver although you really needed the 'new' OS with the cassette routines in firmware to make life easy.

Regarding your F0 lead in trick for fooling the recorder AGC, forum member Gertk64 had the interesting idea of inverting the digital signals going between the MK14 and the cassette interface so that when in 'save' mode the cassette interface would produce a continuous tone which would occasionally be interrupted by silence, rather than producing silence occasionally interrupted by tone. That would cause the interface to emit a steady tone before it started to send actual data, and the steady tone would make the AGC adjust appropriately before the actual data started to be sent. The later ZX machines noticeably did have long steady lead-in tones on their cassette audio tones for exactly that purpose.

Elsewhere, there was a suggestion of superimposing an ultrasonic frequency tone on the outgoing audio from the interface which the recorder's amplifier would 'hear' and the AGC would adjust to, but which would not get recorded on the tape. I don't know if either of these suggestions has ever been taken beyond the theory stage.

Last edited by SiriusHardware; 3rd Jan 2021 at 5:34 pm.
SiriusHardware is offline  
Old 3rd Jan 2021, 10:59 pm   #7
twostickes
Triode
 
Join Date: Dec 2020
Location: Durham, County Durham, UK.
Posts: 20
Default Re: MK14 Tape Interface

Yes I think I got it from Guisborough I seem to remember something like that. That's about a 45 minute drive down the road, I always went past it on trips to Whitby and Scarborough before the lockdowns.

Yes Arduino keypad injection was supplied and which works really well, also had some info and programs on memory stick, it was a very nice touch and appreciated.

I'm pretty sure the inversion technique on the TI would work, not too sure about the HF tone technique, could have some variance on different machines?

The software I uploaded to GitHub could be improved with another command line option for example -i could be to invert the WAV stream. (But of course the TI would need to have an inversion function to decode it!).
twostickes is offline  
Old 4th Jan 2021, 4:49 pm   #8
Slothie
Octode
 
Join Date: Apr 2018
Location: Newbury, Berkshire, UK.
Posts: 1,287
Default Re: MK14 Tape Interface

I've been looking at the docs for the tape interface and it is clear that the timing is done with DLY statements so presumably if your MK14 is using a 4MHz crystal for the VDU then the timings will be different than if you use a 4.433619MHz crystal. I wonder how much of a difference it makes? Presumably just means the timings are 9.7% slower with a 4MHz crystal? I wonder if the difference between the '0' and '1' pulse lengths was enough to compensate so tapes could be read by machines with different crystals (although I'm not sure how much tape-swapping would have been going on back then).
Slothie is offline  
Old 4th Jan 2021, 10:02 pm   #9
twostickes
Triode
 
Join Date: Dec 2020
Location: Durham, County Durham, UK.
Posts: 20
Default Re: MK14 Tape Interface

Thanks slothie! Yes I wondered about that, my issue ii had the original large 4.433 colour burst xtal and the VDU calls for 4.0MHz. I seem to remember my original MK14 in '79 / '80 have a 4.0MHz small can, wrapped in grey plastic, as I also had the original vdu at the time. So there is a 10% change in recording speeds. Ive been guessing that the tolerance is fine since the protocol re-syncs every pulse, and there are barn-door limits in the sample positions, but you raise a valid point, maybe I should also have a command-line option on the hex-to-wav utility, for xtal speeds, and maybe if not specified, then plumb for middle average 4.2MHz!
Incidentally, the issue v MK14 i recently got had a 3.2768MHz xtal ! ie someone must have used it as some sort of timing, or maybe logging? Obviously a bit far to read my old 4.0MHz clocked tape pulses with any degree of accuracy, although there is marginal success. It is to be replaced with 4.0MHz for the replica vdu (if i get it to work)!
twostickes is offline  
Old 4th Jan 2021, 10:07 pm   #10
twostickes
Triode
 
Join Date: Dec 2020
Location: Durham, County Durham, UK.
Posts: 20
Default Re: MK14 Tape Interface

There was one other thing - I'm knocking up an interface board to plug onto the mK14 top edge connector, and will put on a button to create a manually operated preamble burst for the TI. The other thing is a 4.0MHz clock to connect to XIN of the 8060 to override any 4.433MHz xtal with 4.000MHz without having to unsolder it. The intention is to keep the MK14 in a vintage state as possible (although I know most were modded beyond belief in the day, so maybe those mods are vintage too?)
twostickes is offline  
Old 4th Jan 2021, 10:22 pm   #11
SiriusHardware
Dekatron
 
Join Date: Aug 2011
Location: Newcastle, Tyne and Wear, UK.
Posts: 11,484
Default Re: MK14 Tape Interface

I thought the seller of that machine made a really good effort of presentation, he posted a nice 'video advert' of it all working, as well. I thought it deserved to go for a decent price.

The experiments I tried in this thread,

https://vintage-radio.net/forum/showthread.php?t=154725

...in which a PC serial port was used to generate the 'tape in' data stream (bypassing the cassette interface altogether) suggested that in input mode the cassette interface routines have a pretty good tolerance for speed variation, as it worked first with the PC sending at a specially modified baud rate of 320 baud, and then just as well afterwards with the PC sending the data stream to the MK14 at the standard PC baud rate of 300 baud.

Maybe the thing to try might be to aim, as you have suggested, at a data rate half way between the 4.43Mhz clock rate and the 4.00MHz clock rate - with any luck that speed will be tolerated by machines with either clock crystal fitted.

I have a feeling, though, that data saved from a 4.43Mhz machine will probably load just fine on a 4.00Mhz machine.
SiriusHardware is offline  
Old 4th Jan 2021, 10:40 pm   #12
twostickes
Triode
 
Join Date: Dec 2020
Location: Durham, County Durham, UK.
Posts: 20
Default Re: MK14 Tape Interface

Hi SiriusHardware, thanks for pointing out that thread, it's really interesting to see what others have already tried.
twostickes is offline  
Old 5th Jan 2021, 12:05 am   #13
Timbucus
Octode
 
Join Date: Mar 2019
Location: Barry, Vale of Glamorgan, Wales, UK.
Posts: 1,362
Default Re: MK14 Tape Interface

I have one of each - I must give it a go just need to rig some way to hook the tape interface up to the VI
Timbucus is offline  
Old 5th Jan 2021, 10:32 am   #14
twostickes
Triode
 
Join Date: Dec 2020
Location: Durham, County Durham, UK.
Posts: 20
Default Re: MK14 Tape Interface

Thanks Timbucus!
twostickes is offline  
Old 5th Jan 2021, 12:32 pm   #15
Slothie
Octode
 
Join Date: Apr 2018
Location: Newbury, Berkshire, UK.
Posts: 1,287
Default Re: MK14 Tape Interface

Quote:
Originally Posted by Timbucus View Post
I have one of each - I must give it a go just need to rig some way to hook the tape interface up to the VI
You could wire some of the unused pads on the underside of the keyboard connectors to SenseA, SIN and Flag0 and use the keyboard edge connector you already have......
Slothie is offline  
Old 5th Jan 2021, 3:29 pm   #16
JohnBHanson
Heptode
 
Join Date: Aug 2009
Location: Worthing, Sussex, UK.
Posts: 661
Default Re: MK14 Tape Interface

Just a reminder - the xbeaver Z80 Gemini emulator has an assembler for scmp (masmx) and also you can download to a mk14 using device driver rt
-
use:-
device ins rt0
device pun rt2

"device map" will show the serial port addresses. Configure a serial port in
xbeaver.cfg with an 8250 at an address - this can either be a serial port - eg
"tty /dev/ttyUSB0" or a tape interface via the soundcard "tapeout mk14"
and then fire in intel hex file to the pun: device.

If this is of any interest to anyone - please let me know.
JohnBHanson is offline  
Old 5th Jan 2021, 4:14 pm   #17
SiriusHardware
Dekatron
 
Join Date: Aug 2011
Location: Newcastle, Tyne and Wear, UK.
Posts: 11,484
Default Re: MK14 Tape Interface

John, it would be good if you could do a 'quick start' step by step walkthrough of how to use your emulator to do that, perhaps in its own appropriately titled thread as with the other MK14 upload methods? It sounds like a very useful resource / method but obviously requires the user to have a little bit of familiarity with the emulator and the Gemini system it emulates.

My understanding (correct me if I am wrong) is that it uses Karen Orton's suggested method (from the thread linked to in #11) of sending the data out of a serial port and through a level-shifter directly to SenseB / SIN?
SiriusHardware is offline  
Old 5th Jan 2021, 6:21 pm   #18
Timbucus
Octode
 
Join Date: Mar 2019
Location: Barry, Vale of Glamorgan, Wales, UK.
Posts: 1,362
Default Re: MK14 Tape Interface

Quote:
Originally Posted by JohnBHanson View Post

If this is of any interest to anyone - please let me know.
Yes indeed I have for sometime been looking at NASCOM/GEMINI systems and keep getting pipped at the post - I assumed that was an emulator you were mentioning in the thread, so some info on it would be great - especially if the SC/MP assembler is there - I assume that is Z80 based is the source around?
Timbucus is offline  
Old 5th Jan 2021, 8:44 pm   #19
SiriusHardware
Dekatron
 
Join Date: Aug 2011
Location: Newcastle, Tyne and Wear, UK.
Posts: 11,484
Default Re: MK14 Tape Interface

Sorry, after a re-read of John's post #16 I realise that the output can be directed to a digital stream via a serial port or as an MK14 tape audio signal via the soundcard.

A specific walkthrough or set of steps for using it in either mode would be great, but ideally in its own specific thread to make it easier for people to locate.
SiriusHardware is offline  
Old 5th Jan 2021, 9:35 pm   #20
JohnBHanson
Heptode
 
Join Date: Aug 2009
Location: Worthing, Sussex, UK.
Posts: 661
Default Re: MK14 Tape Interface

OK - I will create a web page in due course......

Basically I wrote a cross-assembler for scmp which generates code for the
scmp microprocessor which is used in the mk14. This was part of me experimenting with the concept of an IDE back in about 1982. Basically it
comes with an inbuilt editor and was originally designed to run on a z80 tape
based system. I ported it to CP/M and the gemini system arround 1984 and
used it on my Alphatronic PC. Latter I cam to own a 80bus hard disk system
and it was ported to that - my cross assembler was then ported to that. Furhtermore a device driver was then written which allowed the output to the assembler (intel hex format) to be downloaded directly to the scmp via either an rs232 port or 1kHz modulated signal via a sound card.

Details are arround on the xbeaver download - (type shell) to get to a menu system but you have to dig to get to the methodology. In view of the surprising interest in mk14/scmp I am happy to produce a web page giving details.

PS - can someone email me some photos of mk14 to use on page please.
thanks.
JohnBHanson is offline  
Closed Thread

Thread Tools



All times are GMT +1. The time now is 6:02 am.


All information and advice on this forum is subject to the WARNING AND DISCLAIMER located at https://www.vintage-radio.net/rules.html.
Failure to heed this warning may result in death or serious injury to yourself and/or others.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright ©2002 - 2023, Paul Stenning.