Looking for an automated way of converting a BASIC program done on a 48K Spectrum to one for the ZX81. It's obvious that some things cannot be done on the ZX81 but, having that in mind, is there any known tool that can automate the process and warn if something has to be changed if it's not possible on the ZX81? Thanks.
On Sun, 1 Nov 2009 19:19:41 -0800 (PST) da kidz on comp.sys.sinclair were rappin' to MC zxbruno:
> Looking for an automated way of converting a BASIC program done on a > 48K Spectrum to one for the ZX81. It's obvious that some things cannot > be done on the ZX81 but, having that in mind, is there any known tool > that can automate the process and warn if something has to be changed > if it's not possible on the ZX81? Thanks.
Yes, I have done this very thing. Obviously there's a bit of hand-editing involved.
The second part of the process used Chris Cowley's zxtext2p.
The first part needs a snapshot to text converter. I can't remember which one I used, but there is one which uses almost exactly the same codes (for graphics) as zxtext2p.
Gawd, I imagine it would be possible but there is a lot of problems, not the least that yoyou can only have one command per line of the zx 81.
The other way is possible of course, I used ZX Slowloader a lot in the early days to convert those ICL basic games to the speccy, then add sound graphics and colour to them.
9 hole golf was a bit boring though.
Brian
-- Brian Gaff - bria...@blueyonder.co.uk Note:- In order to reduce spam, any email without 'Brian Gaff' in the display name may be lost. Blind user, so no pictures please!
"zxbruno" <zxspectrum...@gmail.com> wrote in message
> Looking for an automated way of converting a BASIC program done on a > 48K Spectrum to one for the ZX81. It's obvious that some things cannot > be done on the ZX81 but, having that in mind, is there any known tool > that can automate the process and warn if something has to be changed > if it's not possible on the ZX81? Thanks.
"zxbruno" | Looking for an automated way of converting a BASIC program done on a | 48K Spectrum to one for the ZX81. It's obvious that some things cannot | be done on the ZX81 but, having that in mind, is there any known tool | that can automate the process and warn if something has to be changed | if it's not possible on the ZX81? Thanks. This tool had never been cooded... The reverse way, Zx81 to Spectrum can be done using "ZxTrans".
You had to use several tools:
Step 1: Binarys to TEXT. Convert the Zx Spectrum binary file to a text file. Zxtoken can convert a sna or a tape file to a text file.
Step 2: TEXT editing. Clear all Spectrum's specifics commands, like "PEN", "INK"... Add lines while a ":" character is present. Add lines numbers.(renume if the line is too big, or if the Spectrum line number is too closed. (1 print:print 2 go to 1 => 1 PRINT ; 2 PRINT ; 3 GOTO 1) Change "Go to" in "GOTO", "GO SUB" in "GOSUB", "Randomize" in "RAND"...
Step 3: Text to a zx81 binary file. ZxToken ... or the XuR. Both, can make a "P" file up to 16kb. But, in XuR, you had to initialize the ram card before loading a "TXT" file. The drag&drop on the XuR icon may hang the memory (up to 16kb). You had to open the Xur, go to "Reset memory" and select "32k"... or use the propers pokes to init cards. Go to "Specify tape & directory", click on "Set Ram to 32Kb", and double-click on your text file. A hardware reset will reinit the ram to 16kb. It's the same way to load a "P" file, up to 16kb. All illegals command will be converted in ascii codes... and can be removed in Zx81 Basic editor. If 32kb is short, you can "optimize" the basic code using the numerics replacement... or renume the basic programme. I had to code "SomeThings to Do" in 32kb, and optimize the basic codes to able to use it in 16kb... And in 16kb, users (me) can't list or change the basic program due to the D_file, to big to be expended in 16kb!!! But, dont optimize the Basic lenght before to be sure to be ready. All Gotos/sub will be changed to fixe functions (val"1200"... code"A") and make wake dificulte the basic reading. (LET value=CODE("R") ... ???) You will be able to save your basic program using SAVE"MYPROG"... But, don't forget to initialize the 32kb zx81's ram if you had to run it again...
You can make an audio wav in fast-load using the SAVE"MYPROG.FL".
Thank you for all the suggestions. I'm waiting for a reply from one gentleman who might also be able to help. If I receive more information I'll share it here. Thanks again.