[Coco] Tandy Color Computer 3 RND Function
Allen Huffman
alsplace at pobox.com
Sat Mar 28 16:09:40 EDT 2020
> On Mar 28, 2020, at 2:51 PM, richec <rcrislip at neo.rr.com> wrote:
>
> On Fri, 27 Mar 2020 23:13:49 -0500
> Allen Huffman <alsplace at pobox.com <mailto:alsplace at pobox.com>> wrote:
> <snip?
>> project, porting the same code over including the bugs so it’s 100%
>> compatible :)
> 8-)) That's funny, loved the humor
I wish it were a joke! When I was going through the Extended Color BASIC unravelled disassembly, I noticed something. The parser will grab a character, then decided what to do with it. Certain things will then be followed by a check for a modifier.
A modifier is what comes after, like V for volume will have a number after it. O for octave will have a number after it.
For notes of A-F, it checks for a “#” or “+” to make it a sharp, or “-“ to make it a flat. I noticed that the way it did it, it allowed to sharp and flat anything, even though on a piano those notes don’t exist.
Notes go:
C - C#/Eb - E - F - F#/Gb - G - G#/Ab - A - A#/Bb - B - C
…and so on. There is no such thing as an E-sharp or an F-flat, or a B-sharp or a C-flat.
But the CoCo PLAY command allows:
PLAY “E# F”
Those play the same notes.
PLAY “F- E”
Those play the same notes.
You can’t do a “B#” or “C-", since the note range stops there (C D E F G A B) so it will return ?FC ERROR for those.
So in case anyone ever wrote music using E# or F flat, my code plays it.
— A
More information about the Coco
mailing list