[Coco] 64K Coco mode and the MC6883
Arthur Flexser
flexser at fiu.edu
Tue Mar 28 18:03:56 EDT 2023
The method does have the drawback of changing the string length to 126, which could create problems if the string is used later in the program. One of those things that can cause a real headache trying to figure out why unpredictable results occurred. Executing via EXEC (256*MS +LS) would be better programming technique.
Art
________________________________
From: Coco <coco-bounces at maltedmedia.com> on behalf of Allen Huffman via Coco <coco at maltedmedia.com>
Sent: Tuesday, March 28, 2023 4:11 PM
To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
Cc: Allen Huffman <alsplace at pobox.com>
Subject: Re: [Coco] 64K Coco mode and the MC6883
Note: This message originated from outside the FIU Faculty/Staff email system.
> On Mar 28, 2023, at 2:46 PM, Sean Conner via Coco <coco at maltedmedia.com> wrote:
>
> Some of the details of BASIC programming on the Coco have escaped me (it's
> been 33 years since I did any), and I'm leary of just poking the code
> randomly into memory, so when I saw the method of using a string to store
> the code, it seemed like a perfectly good way of doing this for a one-off
> type of operation. I would not do this for a longer running program.
>
> -spc
It’s a very cool trick. I do not think I ever used it, but I wish I would have done that for my ALLRAM BBS PCLEAR0 code, rather than POKEing it to the screen and EXEC 1024 on startup.
The string can be up to 255, so I suppose it’s fair game for any code that fits in the size.
And, you can’t have a 0 in the assembly or the string will be truncated. There was discussion about the Tandy came WAR (card game) and how it did some embedded assembly for the title screen. Someone disassembled the code, and it did something that was a bit less efficient, but someone explained it was to avoid the 0 being in the string where the program was stored.
(I am trying to paste the article here but it keeps getting inlined; a feature I don’t know how to disable yet.)
Look on subethasoftware.com for the Attract Screen article, part 6, which has the code and explains the problem with 0 in the string.
Ah yes, the compare to the end was two bytes further than the end of the screen so it was comparing against $601 I guess instead of $600.
--
Coco mailing list
Coco at maltedmedia.com
https://pairlist5.pair.net/mailman/listinfo/coco
More information about the Coco
mailing list