mirror of
https://github.com/holub/mame
synced 2025-04-18 22:49:58 +03:00
gamecom: reworked audio channels 0 and 1 a bit (still doesn't sound anything like the real thing)
This commit is contained in:
parent
13d091c38f
commit
2b7764aa4a
@ -8,8 +8,9 @@ Various improvements by Robbbert.
|
||||
Todo:
|
||||
- Fix cpu and system problems that prevent the games from working fully.
|
||||
- RS232 port
|
||||
- Sound ports 1,2,3 (DAC sound partially works)
|
||||
- CPU speed can be adjusted by the games.
|
||||
- Sound ports 1,2 do not sound anything like the real thing
|
||||
- Sound port 3 (noise channel)
|
||||
- Sound dac port (mostly works but is the wrong speed in some places)
|
||||
|
||||
Game Status:
|
||||
- Inbuilt ROM and PDA functions all work
|
||||
@ -272,6 +273,12 @@ static MACHINE_CONFIG_START( gamecom, gamecom_state )
|
||||
MCFG_SOUND_ADD("dac", DAC, 0)
|
||||
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 1.00)
|
||||
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 1.00)
|
||||
MCFG_SOUND_ADD("dac0", DAC, 0)
|
||||
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 0.10)
|
||||
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 0.10)
|
||||
MCFG_SOUND_ADD("dac1", DAC, 0)
|
||||
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "lspeaker", 0.10)
|
||||
MCFG_SOUND_ROUTE(ALL_OUTPUTS, "rspeaker", 0.10)
|
||||
|
||||
/* cartridge */
|
||||
MCFG_GENERIC_CARTSLOT_ADD("cartslot1", generic_linear_slot, "gamecom_cart")
|
||||
|
@ -218,6 +218,8 @@ public:
|
||||
, m_p_nvram(*this,"nvram")
|
||||
, m_maincpu(*this, "maincpu")
|
||||
, m_dac(*this, "dac")
|
||||
, m_dac0(*this, "dac0")
|
||||
, m_dac1(*this, "dac1")
|
||||
, m_cart1(*this, "cartslot1")
|
||||
, m_cart2(*this, "cartslot2")
|
||||
, m_bank1(*this, "bank1")
|
||||
@ -279,6 +281,8 @@ private:
|
||||
required_shared_ptr<UINT8> m_p_nvram;
|
||||
required_device<cpu_device> m_maincpu;
|
||||
required_device<dac_device> m_dac;
|
||||
required_device<dac_device> m_dac0;
|
||||
required_device<dac_device> m_dac1;
|
||||
required_device<generic_slot_device> m_cart1;
|
||||
required_device<generic_slot_device> m_cart2;
|
||||
required_memory_bank m_bank1;
|
||||
|
@ -29,7 +29,7 @@ TIMER_CALLBACK_MEMBER(gamecom_state::gamecom_sound0_timer_callback)
|
||||
{
|
||||
bool which_half = BIT(m_sound0_cnt, 0);
|
||||
UINT8 sb = m_sound.sg0w[m_sound0_cnt >> 1];
|
||||
m_dac->write_unsigned8((which_half ? sb >> 4 : sb & 15)^8);
|
||||
m_dac0->write_signed8(which_half ? sb & 0xf0 : sb << 4);
|
||||
m_sound0_cnt++;
|
||||
}
|
||||
}
|
||||
@ -49,7 +49,7 @@ TIMER_CALLBACK_MEMBER(gamecom_state::gamecom_sound1_timer_callback)
|
||||
{
|
||||
bool which_half = BIT(m_sound1_cnt, 0);
|
||||
UINT8 sb = m_sound.sg1w[m_sound1_cnt >> 1];
|
||||
m_dac->write_unsigned8((which_half ? sb >> 4 : sb & 15)^8);
|
||||
m_dac1->write_signed8(which_half ? sb & 0xf0 : sb << 4);
|
||||
m_sound1_cnt++;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user