Joypad

From NeoGeo Development Wiki
Revision as of 05:47, 8 March 2011 by Furrtek (talk | contribs) (moved Joypads to Joypad)
Jump to navigation Jump to search

Need picture and clear bit definitions of registers.

Registers used to read the button's states directly:

  • REG_P1CNT ($300000), byte for DCBARLDU of player 1.
  • REG_P2CNT ($340000), byte for DCBARLDU of player 2.
  • REG_STATUS_B ($380000), byte for xxxx Select2 Start2 Select1 Start2.

A BIOS call can be used to read joypads more easily. The call sets values in the BIOS's RAM space which gives currently-pressed, state-change, and "repeat" values for both joypads.