mirror of
https://github.com/holub/mame
synced 2025-07-05 09:57:47 +03:00
k005289.c: correct comments, name functions after pin names on schematic (nw)
This commit is contained in:
parent
4b75237697
commit
73debc51f4
@ -6,7 +6,7 @@
|
||||
Namco Sound, Amuse by Cab, Nemesis schematics and whoever first
|
||||
figured out SCC!
|
||||
|
||||
The 005289 is a 2 channel sound generator, each channel gets it's
|
||||
The 005289 is a 2 channel sound generator. Each channel gets its
|
||||
waveform from a prom (4 bits wide).
|
||||
|
||||
(From Nemesis schematics)
|
||||
@ -18,10 +18,17 @@
|
||||
|
||||
The second channel is the same as above except port B is used.
|
||||
|
||||
The 005289 has no data bus, so data values written don't matter.
|
||||
The 005289 has 12 address inputs and 4 control inputs: LD1, LD2, TG1, TG2.
|
||||
It has no data bus, so data values written don't matter.
|
||||
When LD1 or LD2 is asserted, the 12 bit value on the address bus is
|
||||
latched. Each of the two channels has its own latch.
|
||||
When TG1 or TG2 is asserted, the frequency of the respective channel is
|
||||
set to the previously latched value.
|
||||
|
||||
There are 4 unknown pins, LD1, LD2, TG1, TG2. Two of them look to be
|
||||
the selector for changing frequency. The other two seem unused.
|
||||
The 005289 itself is nothing but an address generator. Digital to analog
|
||||
conversion, volume control and mixing of the channels is all done
|
||||
externally via resistor networks and 4066 switches and is only implemented
|
||||
here for convenience.
|
||||
|
||||
***************************************************************************/
|
||||
|
||||
@ -205,19 +212,19 @@ WRITE8_MEMBER( k005289_device::k005289_control_B_w )
|
||||
}
|
||||
|
||||
|
||||
WRITE8_MEMBER( k005289_device::k005289_pitch_A_w )
|
||||
WRITE8_MEMBER( k005289_device::ld1_w )
|
||||
{
|
||||
m_freq_latch[0] = 0x1000 - offset;
|
||||
}
|
||||
|
||||
|
||||
WRITE8_MEMBER( k005289_device::k005289_pitch_B_w )
|
||||
WRITE8_MEMBER( k005289_device::ld2_w )
|
||||
{
|
||||
m_freq_latch[1] = 0x1000 - offset;
|
||||
}
|
||||
|
||||
|
||||
WRITE8_MEMBER( k005289_device::k005289_keylatch_A_w )
|
||||
WRITE8_MEMBER( k005289_device::tg1_w )
|
||||
{
|
||||
m_stream->update();
|
||||
|
||||
@ -225,7 +232,7 @@ WRITE8_MEMBER( k005289_device::k005289_keylatch_A_w )
|
||||
}
|
||||
|
||||
|
||||
WRITE8_MEMBER( k005289_device::k005289_keylatch_B_w )
|
||||
WRITE8_MEMBER( k005289_device::tg2_w )
|
||||
{
|
||||
m_stream->update();
|
||||
|
||||
|
@ -33,10 +33,10 @@ protected:
|
||||
public:
|
||||
DECLARE_WRITE8_MEMBER( k005289_control_A_w );
|
||||
DECLARE_WRITE8_MEMBER( k005289_control_B_w );
|
||||
DECLARE_WRITE8_MEMBER( k005289_pitch_A_w );
|
||||
DECLARE_WRITE8_MEMBER( k005289_pitch_B_w );
|
||||
DECLARE_WRITE8_MEMBER( k005289_keylatch_A_w );
|
||||
DECLARE_WRITE8_MEMBER( k005289_keylatch_B_w );
|
||||
DECLARE_WRITE8_MEMBER( ld1_w );
|
||||
DECLARE_WRITE8_MEMBER( ld2_w );
|
||||
DECLARE_WRITE8_MEMBER( tg1_w );
|
||||
DECLARE_WRITE8_MEMBER( tg2_w );
|
||||
|
||||
private:
|
||||
void make_mixer_table(int voices);
|
||||
|
@ -385,11 +385,11 @@ ADDRESS_MAP_END
|
||||
static ADDRESS_MAP_START( sound_map, AS_PROGRAM, 8, nemesis_state )
|
||||
AM_RANGE(0x0000, 0x3fff) AM_ROM
|
||||
AM_RANGE(0x4000, 0x47ff) AM_RAM
|
||||
AM_RANGE(0xa000, 0xafff) AM_DEVWRITE("k005289", k005289_device, k005289_pitch_A_w)
|
||||
AM_RANGE(0xc000, 0xcfff) AM_DEVWRITE("k005289", k005289_device, k005289_pitch_B_w)
|
||||
AM_RANGE(0xa000, 0xafff) AM_DEVWRITE("k005289", k005289_device, ld1_w)
|
||||
AM_RANGE(0xc000, 0xcfff) AM_DEVWRITE("k005289", k005289_device, ld2_w)
|
||||
AM_RANGE(0xe001, 0xe001) AM_READ(soundlatch_byte_r)
|
||||
AM_RANGE(0xe003, 0xe003) AM_DEVWRITE("k005289", k005289_device, k005289_keylatch_A_w)
|
||||
AM_RANGE(0xe004, 0xe004) AM_DEVWRITE("k005289", k005289_device, k005289_keylatch_B_w)
|
||||
AM_RANGE(0xe003, 0xe003) AM_DEVWRITE("k005289", k005289_device, tg1_w)
|
||||
AM_RANGE(0xe004, 0xe004) AM_DEVWRITE("k005289", k005289_device, tg2_w)
|
||||
AM_RANGE(0xe005, 0xe005) AM_DEVWRITE("ay2", ay8910_device, address_w)
|
||||
AM_RANGE(0xe006, 0xe006) AM_DEVWRITE("ay1", ay8910_device, address_w)
|
||||
AM_RANGE(0xe086, 0xe086) AM_DEVREAD("ay1", ay8910_device, data_r)
|
||||
@ -401,12 +401,12 @@ ADDRESS_MAP_END
|
||||
static ADDRESS_MAP_START( gx400_sound_map, AS_PROGRAM, 8, nemesis_state )
|
||||
AM_RANGE(0x0000, 0x1fff) AM_ROM
|
||||
AM_RANGE(0x4000, 0x87ff) AM_RAM AM_SHARE("gx400_shared")
|
||||
AM_RANGE(0xa000, 0xafff) AM_DEVWRITE("k005289", k005289_device, k005289_pitch_A_w)
|
||||
AM_RANGE(0xc000, 0xcfff) AM_DEVWRITE("k005289", k005289_device, k005289_pitch_B_w)
|
||||
AM_RANGE(0xa000, 0xafff) AM_DEVWRITE("k005289", k005289_device, ld1_w)
|
||||
AM_RANGE(0xc000, 0xcfff) AM_DEVWRITE("k005289", k005289_device, ld2_w)
|
||||
AM_RANGE(0xe000, 0xe000) AM_DEVWRITE("vlm", vlm5030_device, data_w)
|
||||
AM_RANGE(0xe001, 0xe001) AM_READ(soundlatch_byte_r)
|
||||
AM_RANGE(0xe003, 0xe003) AM_DEVWRITE("k005289", k005289_device, k005289_keylatch_A_w)
|
||||
AM_RANGE(0xe004, 0xe004) AM_DEVWRITE("k005289", k005289_device, k005289_keylatch_B_w)
|
||||
AM_RANGE(0xe003, 0xe003) AM_DEVWRITE("k005289", k005289_device, tg1_w)
|
||||
AM_RANGE(0xe004, 0xe004) AM_DEVWRITE("k005289", k005289_device, tg2_w)
|
||||
AM_RANGE(0xe005, 0xe005) AM_DEVWRITE("ay2", ay8910_device, address_w)
|
||||
AM_RANGE(0xe006, 0xe006) AM_DEVWRITE("ay1", ay8910_device, address_w)
|
||||
AM_RANGE(0xe030, 0xe030) AM_WRITE(gx400_speech_start_w)
|
||||
|
Loading…
Reference in New Issue
Block a user