Once upon a time I owned an Olivetti Prodest PC128, a microcoputer with a Motorola 6809E 1 MHz processor, 128 kB of RAM and a cassette driver, and I spent many years playing and programming with it. Some months ago, I found an emulator for PC of the Thomson MO6 that, I discovered, was the same computer. The emulator, DCMO6, has been made by a french programmer, Daniel Coulom (http://dcmo6.free.fr) and it works perfectly. I'd like to thank him very much for his work!
Soon I wanted a way to transfer old data to the emulator; not commercial games, who were saved in strange ways, and that I'm sending to Daniel who can convert them, but normal basic programs and, especially, the ton of stuff saved by me in old days.
Having no knowledge about serial lines, printer ports, etc... I found a way using only the video signal: making the PC128 fill some screens with patterns reproducing a memory area, capturing these images with tv-card on PC and analyzing them.
So I exhumed the microcomputer, I tried to implement that idea and, unbelievable!!!, after some adjustments it worked, and amused me very much!
On PC, you must capture images in form of 24 bit bitmaps, named with a prefix and an index starting from 1, with the same number of digits for every index. Most drivers provide facilities to do this automatically. Screens are ready for capture when outer frame is red. PC program asks you some parameters; for example, if you saved your images as
you will enter:
Prefix name: c:\test\p
Number of digits in number: 3
Number of frames: 25
If recognition goes fine, the program will create a cassette image ready for the emulator, with a binary memory image file (the kind you load with LOADM) named BIN.BIN. You must enter the name for the image file you want to create, the load address and the execution address. Like you can see, the program can transfer an arbitrary area of memory, and nothing else. This is a powerful way to transfer almost everything.
For example, let's see how to export a Basic program. Since you cannot load 2 programs at the same time (you know, merging them is not an elegant solution...), you must do some steps, here's a possible way:
xxxx 'EEEEENNNNNDDDDDIt will be useful to find the end of the program in memory.
FOR I=&H6000 TO &H9FFF:BANK 1:A=PEEK(I):BANK 6:POKE I,A:NEXT(by now let's copy all the bank for semplicity, even if it takes several minutes).
BANK 1:LOADMMagically, you have the Basic program in memory! Now you can save it in another virtual cassette in normal BAS mode.
Hint 1: a simple trick: I used bank 5 as a "parking zone" for the "export" program, so I had not to reload it from cassette every time. If you do this, don't execute the program you are going to export, because it can alter arbitrary memory in banks.
Hint 2: copying many times a program from bank 1 to bank 6, the memory after its end may be filled with a previous, longer program. Pay attention to the memory dump to determine the real end.
Hint 3: if you have a protected program, at the end of this file I describe a method to remove protection using only Basic instructions. Let's go, we're talking about abandonware, don't report me to the Police! (by the way, this is the only microcomputer I remember that allowed you to save protected programs, but, you know who created the Basic interpreter...)
Hint 4: exporting a compressed image (a .MAP file) is as easy as copying it in a piece of memory, splitting 16 bits integers in 2 bytes.
The software is made of 2 parts:
"bcc32 -A -j1 -WC mo6export.cpp".Although I included a compiled version, you MUST recompile it, because you must set a pair of geometric values strictly dependant on your tv-card. Read sources for more details. Otherwise, I'm quite sure it will not work.
If there is anyone else out there who would try this, I'l be happy to hear from you. Suggestions, comments and all other kind of things are welcome!Michele Alessandrini, email@example.com
Here's the solution: when you make a "NEW" command, the protection disappears with the program; but the program is not erased from memory, only 1 byte at the beginning of the listing is set to 0. So, perform these steps:
BANK 1:FOR I=24580 TO &H9FFF: IF PEEK(I)=0 THEN POKE 24578,I-24576 ELSE NEXT