As my machine code is *very* rusty, I've nipped to my local library and amazingly been able to borrow a copy of "Machine language programming made simple for your Sinclair" published my Melbourne House/Beam Software in 1981. It's aimed at owners of ZX80 and ZX81 computers.
On page 139 there is a "machine code editor" program...it's a hex loader wit some extra features. I'd like to use it and work through the book as the authors intended but I've come up against a weird problem. Line 200 of the program is:
200 LET V = 16* CODE (A$) + CODE (TL$(A$)) -476
The problem is TL$ of course is not recognised.
Is anyone familiar with this book? Was there a known typo and correction to this program? The only string used is A$, there is no variable TL either.
Machine Language book by Melbourne House
Re: Machine Language book by Melbourne House
Here is the program. It is for the ZX80 with the following page containing some additions for the ZX81.
- Attachments
-
- zx81m.JPG (59.37 KiB) Viewed 4720 times
Re: Machine Language book by Melbourne House
TL$ is a ZX80 only command, it returns the Whole string except the first character.
so that line is converting the first 2 characters of A$ from Hex to decimal.
on ZX81 you would use...
LET V = 16*CODE A$+CODE A$(2)-476
hth aNDY
so that line is converting the first 2 characters of A$ from Hex to decimal.
on ZX81 you would use...
LET V = 16*CODE A$+CODE A$(2)-476
hth aNDY
what's that Smell.... smells like fresh flux and solder fumes...
Re: Machine Language book by Melbourne House
Thanks, I was vaguely aware of TL$ being recognised by the ZX80. There's no alternative line given for the ZX81. I think I have an early hardback edition of the book, later editions seem to have one page more. Maybe they corrected this?
I'm still pleasantly surprised that the library had a copy. It was last out in 2002.
I'm still pleasantly surprised that the library had a copy. It was last out in 2002.
Re: Machine Language book by Melbourne House
double post. My laptop mouse button is playing up
Last edited by angus on Sat Mar 17, 2012 2:34 pm, edited 1 time in total.
Re: Machine Language book by Melbourne House
It's written ZX80 version in the second line of the scanned page in big letters.angus wrote: Is anyone familiar with this book? Was there a known typo and correction to this program? The only string used is A$, there is no variable TL either.
Have one book from E.Floegl with a machine code editor for 16 - has about 150 BASIC lines to enter.
Unfortunately I do not have a scanner.
Re: Machine Language book by Melbourne House
Umm...that's why I said it was a ZX80 program with modifications on the next page for the ZX81.
But there's no modification of line 200, which is why I needed Andy's help. Thanks
But there's no modification of line 200, which is why I needed Andy's help. Thanks