From a0f3a4516598e0b81bf24964d001a4ba72748ad4 Mon Sep 17 00:00:00 2001
From: Jean-Noel Bazin <jn.bazin@imt-atlantique.fr>
Date: Tue, 22 Apr 2025 16:33:05 +0200
Subject: [PATCH] correction utilisation switch dans fir.vhd

---
 src/hdl/fir.vhd | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/hdl/fir.vhd b/src/hdl/fir.vhd
index 52ee06e..36aa3ea 100644
--- a/src/hdl/fir.vhd
+++ b/src/hdl/fir.vhd
@@ -48,9 +48,9 @@ begin  -- myarch
 prc : process (config_sw(4 downto 0), din) is
   variable w : integer;
   begin  -- process prc
-    w:=to_integer(unsigned(config_sw(4 downto 1))); -- number of removed bits
+    w:=to_integer(unsigned(config_sw(3 downto 0))); -- number of removed bits
     D_in <= (others=> '0');
-    if(config_sw(0)='1') then
+    if(config_sw(4)='1') then
         D_in(15 downto w) <= din(dwidth-1 downto dwidth-16+w); -- truncate
     else
         if(din(dwidth-16+w-1)='1') then
-- 
GitLab