| * QEMU Apple Sound Chip emulation |
| * Apple Sound Chip (ASC) 344S0063 |
| * Enhanced Apple Sound Chip (EASC) 343S1063 |
| * Copyright (c) 2012-2018 Laurent Vivier <laurent@vivier.eu> |
| * Copyright (c) 2022 Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> |
| * SPDX-License-Identifier: GPL-2.0-or-later |
| ASC_TYPE_ASC = 0, /* original discrete Apple Sound Chip */ |
| ASC_TYPE_EASC = 1 /* discrete Enhanced Apple Sound Chip */ |
| #define ASC_FIFO_OFFSET 0x0 |
| #define ASC_FIFO_SIZE 0x400 |
| #define ASC_REG_OFFSET 0x800 |
| #define ASC_REG_SIZE 0x60 |
| #define ASC_EXTREG_OFFSET 0xf00 |
| #define ASC_EXTREG_SIZE 0x20 |
| typedef struct ASCFIFOState { |
| uint8_t fifo[ASC_FIFO_SIZE]; |
| MemoryRegion mem_extregs; |
| uint8_t extregs[ASC_EXTREG_SIZE]; |
| MemoryRegion mem_extregs; |
| /* Time when we were last able to generate samples */ |
| uint8_t regs[ASC_REG_SIZE]; |
| #define TYPE_ASC "apple-sound-chip" |
| OBJECT_DECLARE_SIMPLE_TYPE(ASCState, ASC) |