Skip to navigation

Elite on the BBC Micro

Utility routines: LYN [Elite-A, Docked]

Name: LYN [Show more] Type: Subroutine Category: Utility routines Summary: Clear most of a row of pixels
Context: See this subroutine in context in the source code References: This subroutine is called as follows: * CLYNS calls LYN

Set pixels 0-233 to the value in A, starting at the pixel pointed to by SC. Arguments: A The value to store in pixels 1-233 (the only value that is actually used is A = 0, which clears those pixels) Returns: Y Y is set to 0 Other entry points: SC5 Contains an RTS
.LYN LDY #233 \ Set up a counter in Y to count down from pixel 233 .EE2 STA (SC),Y \ Store A in the Y-th byte after the address pointed to \ by SC DEY \ Decrement Y BNE EE2 \ Loop back until Y is zero .SC5 RTS \ Return from the subroutine