1
0
mirror of https://github.com/cc65/cc65.git synced 2024-06-15 02:29:32 +00:00

Merge pull request #1828 from ZeroByteOrg/x16_ym

Fixed YM2151 struct to match HW behavior
This commit is contained in:
Bob Andrews 2022-08-09 00:50:08 +02:00 committed by GitHub
commit 0c8366c1e9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 5 deletions

View File

@ -538,11 +538,11 @@ NMIVec := $0318
; YM2151 audio chip
.struct YM2151
.org $9F40
.union
STATUS .byte
ADDR .byte
.endunion
.union
DATA .byte
STATUS .byte
.endunion
.endstruct
; X16 Emulator device

View File

@ -285,11 +285,11 @@ struct __vera {
/* Audio chip */
struct __ym2151 {
unsigned char reg; /* Register number for data */
union {
unsigned char reg; /* Register number for data */
unsigned char data;
unsigned char status; /* Busy flag */
};
unsigned char data;
};
#define YM2151 (*(volatile struct __ym2151 *)0x9F40)