Skip to navigation


Keyboard: DKS2

[Commodore 64 version]

Name: DKS2 [Show more] Type: Subroutine Category: Keyboard Summary: Read the joystick position
Context: See this subroutine in context in the source code References: No direct references to this subroutine in this source file

This routine is not used in this version of Elite. It is left over from the BBC Micro version.
.DKS2 LDA KTRAN+7,X ; Fetch either the joystick X value or joystick Y value ; from the key logger buffer, depending on the value of ; X (i.e. fetch either KTRAN+8 or KTRAN+0) EOR JSTE ; The high byte A is now EOR'd with the value in ; location JSTE, which contains $FF if both joystick ; channels are reversed and 0 otherwise (so A now ; contains the high byte but inverted, if that's what ; the current settings say) RTS ; Return from the subroutine