summaryrefslogtreecommitdiffstatshomepage
path: root/src/mess/machine/coco.c
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2014-10-28 09:02:23 +0100
committer Miodrag Milanovic <mmicko@gmail.com>2014-10-28 09:02:23 +0100
commit7c97788e2fea21f336cdaeb5bf1ab4ae83951a1a (patch)
tree202af49fc1afb5791a0c100eda5980cacbc94462 /src/mess/machine/coco.c
parentfc74c025939cce07d18c1c7a80556a6aa67fc0d4 (diff)
line endings (nw)
Diffstat (limited to 'src/mess/machine/coco.c')
-rw-r--r--src/mess/machine/coco.c46
1 files changed, 23 insertions, 23 deletions
diff --git a/src/mess/machine/coco.c b/src/mess/machine/coco.c
index 65b438ef1e5..d701d4f8baf 100644
--- a/src/mess/machine/coco.c
+++ b/src/mess/machine/coco.c
@@ -678,29 +678,29 @@ void coco_state::update_sound(void)
*/
UINT8 single_bit_sound = (m_pia_1->b_output() & 0x02) ? 0x80 : 0x00;
- /* determine the sound mux status */
- soundmux_status_t status = soundmux_status();
-
- /* the SC77526 DAC chip internally biases the AC-coupled sound inputs for Cassette and Cartridge at the midpoint of the 3.9v output range */
- bool bCassSoundEnable = (status == (SOUNDMUX_ENABLE | SOUNDMUX_SEL1));
- bool bCartSoundEnable = (status == (SOUNDMUX_ENABLE | SOUNDMUX_SEL2));
- UINT8 cassette_sound = (bCassSoundEnable ? 0x40 : 0);
- UINT8 cart_sound = (bCartSoundEnable ? 0x40 : 0);
-
- /* determine the value to send to the DAC */
- m_dac_output = (m_pia_1->a_output() & 0xFC) >> 2;
- UINT8 dac_sound = (status == SOUNDMUX_ENABLE ? m_dac_output << 1 : 0);
- m_dac->write_unsigned8(single_bit_sound + dac_sound + cassette_sound + cart_sound);
-
- /* determine the cassette sound status */
- cassette_state cas_sound = bCassSoundEnable ? CASSETTE_SPEAKER_ENABLED : CASSETTE_SPEAKER_MUTED;
- m_cassette->change_state(cas_sound, CASSETTE_MASK_SPEAKER);
-
- /* determine the cartridge sound status */
- m_cococart->cart_set_line(COCOCART_LINE_SOUND_ENABLE, bCartSoundEnable ? COCOCART_LINE_VALUE_ASSERT : COCOCART_LINE_VALUE_CLEAR);
-}
-
-
+ /* determine the sound mux status */
+ soundmux_status_t status = soundmux_status();
+
+ /* the SC77526 DAC chip internally biases the AC-coupled sound inputs for Cassette and Cartridge at the midpoint of the 3.9v output range */
+ bool bCassSoundEnable = (status == (SOUNDMUX_ENABLE | SOUNDMUX_SEL1));
+ bool bCartSoundEnable = (status == (SOUNDMUX_ENABLE | SOUNDMUX_SEL2));
+ UINT8 cassette_sound = (bCassSoundEnable ? 0x40 : 0);
+ UINT8 cart_sound = (bCartSoundEnable ? 0x40 : 0);
+
+ /* determine the value to send to the DAC */
+ m_dac_output = (m_pia_1->a_output() & 0xFC) >> 2;
+ UINT8 dac_sound = (status == SOUNDMUX_ENABLE ? m_dac_output << 1 : 0);
+ m_dac->write_unsigned8(single_bit_sound + dac_sound + cassette_sound + cart_sound);
+
+ /* determine the cassette sound status */
+ cassette_state cas_sound = bCassSoundEnable ? CASSETTE_SPEAKER_ENABLED : CASSETTE_SPEAKER_MUTED;
+ m_cassette->change_state(cas_sound, CASSETTE_MASK_SPEAKER);
+
+ /* determine the cartridge sound status */
+ m_cococart->cart_set_line(COCOCART_LINE_SOUND_ENABLE, bCartSoundEnable ? COCOCART_LINE_VALUE_ASSERT : COCOCART_LINE_VALUE_CLEAR);
+}
+
+
//-------------------------------------------------
// joystick_type - returns the type of joystick