Skip to navigation

Elite on the BBC Micro and NES

Dashboard: ECBLB

[BBC Micro cassette version]

Name: ECBLB [Show more] Type: Subroutine Category: Dashboard Summary: Light up the E.C.M. indicator bulb ("E") on the dashboard
Context: See this subroutine in context in the source code Variations: See code variations for this subroutine in the different versions References: This subroutine is called as follows: * ECMOF calls ECBLB
.ECBLB LDA #7*8 \ The E.C.M. bulb is in character block number 7 \ with each character taking 8 bytes, so this sets the \ low byte of the screen address of the character block \ we want to draw to LDX #LO(ECBT) \ Set (Y X) to point to the character definition in LDY #HI(ECBT) \ ECBT. The LDY has no effect, as we overwrite Y with \ the jump to BULB-2, which writes the high byte of SPBT \ into Y. This works as long as ECBT and SPBT are in \ the same page of memory, so perhaps the BNE below got \ changed from BULB to BULB-2 so they could remove the \ LDY, but for some reason it didn't get culled? Who \ knows... BNE BULB-2 \ Jump down to BULB-2 (this BNE is effectively a JMP as \ A will never be zero)