VOOZH about

URL: https://qiita.com/fuzzball/items/403402e3ea395b905348

⇱ [PC-6001] PSG制御 #Z80 - Qiita


👁 Image
4

Go to list of users who liked

3

Share on X(Twitter)

Share on Facebook

Add to Hatena Bookmark

@fuzzball

[PC-6001] PSG制御

4
Last updated at Posted at 2013-04-26

I/O

ポート番号 内容
$A0 レジスタ指定ポート
$A1 出力データ
$A2 入力データ

read/write

BIOS使わない

; read
 ld a,register ; レジスタ番号
 out ($A0),a
 in a,($A2)

; write
 ld a,register ; レジスタ番号
 out ($A0),a
 ld a,data
 out ($A1),a

BIOS使う

; write
 ld a,register
 ld e,data
 call $1BC5

; read & write
 ld a,register
 ld e,data
 call $1BBE
 ; Dreg = 書き込み前のデータ
  • readは無い

レジスタ

register PC-6001 AY-3-8910 Operation
$00 - \$05 R0 - R5 R0 - R5 Tone Generator Control
$06 R6 R6 Noise Generator Control
$07 R7 R7 Mixer Control-I/O Enable
$08 - \$0A R8 - R10 R10 - R12 Amplitude Control
$0B - \$0C R11 - R12 R13 - R14 Envelop Period Control
$0D R13 R15 Envelop Shape/Cycle Control
  • PC-6001は10進表記
  • AY-3-8910は8進表記
4

Go to list of users who liked

3
0

Go to list of comments

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4

Go to list of users who liked

3