Difference between revisions of "YM2610 registers"

From NeoGeo Development Wiki
Jump to: navigation, search
m (Moved FM registers to dedicated page)
m
Line 18: Line 18:
  
 
The only writable registers that can also be read are the SSG ones.
 
The only writable registers that can also be read are the SSG ones.
 +
To read register X, write X to Z80 port 4, then read Z80 port 5.
  
 
{| class="regdef"
 
{| class="regdef"
Line 30: Line 31:
 
|$05
 
|$05
 
|{{8BitRegister|SSG register data|8}}
 
|{{8BitRegister|SSG register data|8}}
|Attempting to read non-SSG registers will fail.
+
|Attempting to read non-SSG registers will return 0.
 
|-
 
|-
 
|$06
 
|$06

Revision as of 20:23, 24 June 2017

Timers

See YM2610 timers.

SSG part

See SSG for details on this part's operation.

FM part

See FM for details on this part's operation.

ADPCM part

See ADPCM for details on this part's operation.

Reading

The only writable registers that can also be read are the SSG ones. To read register X, write X to Z80 port 4, then read Z80 port 5.

Z80 port Data Notes
$04
Bit 7 6 5 4 3 2 1 0
Def Busy -Timer B flagTimer A flag
When a timer expires and IRQ is enabled for the timer, the respective flag is set.
$05
Bit 7 6 5 4 3 2 1 0
Def SSG register data
Attempting to read non-SSG registers will return 0.
$06
Bit 7 6 5 4 3 2 1 0
Def ADPCM-B end -CH6 endCH5 endCH4 endCH3 endCH2 endCH1 end
When a channel has reached the end address and stops, the respective bit is set (unless masked).
$07 Not implemented Always returns $00