[Coco] ASM Coders - please help!
robert.gault at worldnet.att.net
Mon Aug 28 23:47:10 EDT 2006
David Roper wrote:
> CLRSCRN ldy HSCLEN
> ldx HRESSCRN
> CLRLOOP clr ,X+
> leay -1,Y
> bne CLRLOOP
> ENDLOOP jmp ENDLOOP
> HRESSCRN equ $2000
> HSCLEN equ $2000
> end START
> What I end up seeing (in MESS, at least) is a screen of alternating
> vertical black and green lines.. and not much else
> I'm missing something, or messed something up, or generally on the wrong
> track *somewhere*, and I'm sure someone out there will have much more
> luck explaing where, and why I've gone wrong!
> Any takers to place me under their wing?
> Kind regards,
Here's the problem. Note the ldx and ldy values which are equivalent to
That is not what you wanted or need. What you actually will get is
unknown since the contents of $2000-$2001 will vary depending on what is
present on the hi-res graphics screen.
You really need
because regX is a pointer to the start of the screen and regY is a counter.
And by the way, the value for regY is not large enough to clear the
entire screen if that was intended. A 320x200x16 screen requires $7D00
More information about the Coco