From 8b76ccd312f16a7a8b6ff865bd0a3f9894fa7d44 Mon Sep 17 00:00:00 2001 From: Gyorgy Szombathelyi Date: Thu, 22 Apr 2021 11:35:25 +0200 Subject: [PATCH] Time Pilot 84: update filters --- .../Konami TimePilot84/rtl/Filters/tp84_lpf_heavy.v | 12 ++++++------ .../Konami TimePilot84/rtl/Filters/tp84_lpf_light.v | 2 +- .../Konami TimePilot84/rtl/Filters/tp84_lpf_medium.v | 12 ++++++------ 3 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_heavy.v b/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_heavy.v index 3fa1908f..9bbcc8ab 100644 --- a/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_heavy.v +++ b/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_heavy.v @@ -27,13 +27,13 @@ module tp84_lpf_heavy( input signed [15:0] in, output signed [15:0] out); - reg [9:0] div = 64; //Sample at 12.228/64 = 192000Hz + reg [9:0] div = 73; //Sample at 14/73 ~ 192000Hz //Coefficients computed with Octave/Matlab/Online filter calculators. //or with scipy.signal.bessel or similar tools - //0.0083012547, 0.0083012547 - //1.0000000, -0.98339749 + //0.0050118701, 0.0050118701 + //1.0000000, -0.98997626 reg signed [17:0] A2; reg signed [17:0] B2; reg signed [17:0] B1; @@ -41,9 +41,9 @@ module tp84_lpf_heavy( wire signed [15:0] audio_post_lpf1; always @ (*) begin - A2 = -18'd32223; - B1 = 18'd272; - B2 = 18'd272; + A2 = -18'd32440; + B1 = 18'd164; + B2 = 18'd164; end iir_1st_order lpf6db(.clk(clk), diff --git a/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_light.v b/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_light.v index ed080194..9bc387ea 100644 --- a/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_light.v +++ b/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_light.v @@ -27,7 +27,7 @@ module tp84_lpf_light( input signed [15:0] in, output signed [15:0] out); - reg [9:0] div = 64; //Sample at 12.228/64 = 192000Hz + reg [9:0] div = 73; //Sample at 14/73 ~ 192000Hz //Coefficients computed with Octave/Matlab/Online filter calculators. //or with scipy.signal.bessel or similar tools diff --git a/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_medium.v b/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_medium.v index bd24665d..584b675f 100644 --- a/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_medium.v +++ b/Arcade_MiST/Konami TimePilot84/rtl/Filters/tp84_lpf_medium.v @@ -27,13 +27,13 @@ module tp84_lpf_medium( input signed [15:0] in, output signed [15:0] out); - reg [9:0] div = 64; //Sample at 12.228/64 = 192000Hz + reg [9:0] div = 73; //Sample at 14/73 ~ 192000Hz //Coefficients computed with Octave/Matlab/Online filter calculators. //or with scipy.signal.bessel or similar tools - //0.0047326727, 0.0047326727 - //1.0000000, -0.99053465 + //0.0055103045, 0.0055103045 + //1.0000000, -0.98897939 reg signed [17:0] A2; reg signed [17:0] B2; reg signed [17:0] B1; @@ -41,9 +41,9 @@ module tp84_lpf_medium( wire signed [15:0] audio_post_lpf1; always @ (*) begin - A2 = -18'd32457; - B1 = 18'd155; - B2 = 18'd155; + A2 = -18'd32406; + B1 = 18'd181; + B2 = 18'd181; end iir_1st_order lpf6db(.clk(clk),