mirror of
https://github.com/Gehstock/Mist_FPGA.git
synced 2026-02-04 07:32:37 +00:00
YM2149: fix stereo mixing
This commit is contained in:
@@ -62,7 +62,7 @@ library ieee;
|
||||
|
||||
entity YM2149 is
|
||||
generic (
|
||||
MIXER_VOLTABLE : std_logic := '0'
|
||||
MIXER_VOLTABLE : std_logic := '0'
|
||||
);
|
||||
port (
|
||||
-- data bus
|
||||
@@ -586,11 +586,12 @@ begin
|
||||
vol_r <= vol_r + dac_amp;
|
||||
when "00" => -- Channel A
|
||||
if I_STEREO = '0' then
|
||||
vol_mixer_l <= vol_l + dac_amp;
|
||||
else
|
||||
vol_mixer_l <= vol_l;
|
||||
vol_r <= vol_r + dac_amp;
|
||||
end if;
|
||||
vol_mixer_r <= vol_r + dac_amp;
|
||||
vol_l <= vol_l + dac_amp;
|
||||
when "11" =>
|
||||
vol_mixer_l <= vol_l;
|
||||
vol_mixer_r <= vol_r;
|
||||
when others => null;
|
||||
end case;
|
||||
end if;
|
||||
@@ -667,12 +668,12 @@ begin
|
||||
ADDR_B => vol_table_in_r,
|
||||
DATA_B => vol_table_out_r
|
||||
);
|
||||
end generate; -- VOLTABLE
|
||||
end generate; -- VOLTABLE
|
||||
|
||||
NO_VOLTABLE: if MIXER_VOLTABLE = '0' generate
|
||||
vol_table_out_l <= (others => '0');
|
||||
vol_table_out_r <= (others => '0');
|
||||
end generate;
|
||||
end generate;
|
||||
|
||||
-- mixed audio output
|
||||
|
||||
|
||||
Reference in New Issue
Block a user