From 9339ad96f383aef0d744dd013339dda0ce144a53 Mon Sep 17 00:00:00 2001 From: Benjamin Chausse Date: Mon, 5 May 2025 18:20:24 -0400 Subject: FIX DUMB ER DISPLAY --- .../sim_1/imports/verif/AppCombi_top_tb.vhd | 16 ++++++++-------- pb_APP_log_comb.srcs/sources_1/new/Mux.vhd | 14 +++++--------- 2 files changed, 13 insertions(+), 17 deletions(-) (limited to 'pb_APP_log_comb.srcs') diff --git a/pb_APP_log_comb.srcs/sim_1/imports/verif/AppCombi_top_tb.vhd b/pb_APP_log_comb.srcs/sim_1/imports/verif/AppCombi_top_tb.vhd index 493b77e..77804f0 100644 --- a/pb_APP_log_comb.srcs/sim_1/imports/verif/AppCombi_top_tb.vhd +++ b/pb_APP_log_comb.srcs/sim_1/imports/verif/AppCombi_top_tb.vhd @@ -102,14 +102,14 @@ architecture Behavioral of AppCombi_top_tb is constant char_5 : std_logic_vector(3 downto 0) := "0101"; constant char_6 : std_logic_vector(3 downto 0) := "0110"; constant char_7 : std_logic_vector(3 downto 0) := "0111"; - constant char_8 : std_logic_vector(3 downto 0) := "0000"; - constant char_9 : std_logic_vector(3 downto 0) := "0000"; - constant char_a : std_logic_vector(3 downto 0) := "0000"; - constant char_b : std_logic_vector(3 downto 0) := "0000"; - constant char_c : std_logic_vector(3 downto 0) := "0000"; - constant char_neg : std_logic_vector(3 downto 0) := "0000"; - constant char_e : std_logic_vector(3 downto 0) := "0000"; - constant char_r : std_logic_vector(3 downto 0) := "0000"; + constant char_8 : std_logic_vector(3 downto 0) := "1000"; + constant char_9 : std_logic_vector(3 downto 0) := "1001"; + constant char_a : std_logic_vector(3 downto 0) := "1010"; + constant char_b : std_logic_vector(3 downto 0) := "1011"; + constant char_c : std_logic_vector(3 downto 0) := "1100"; + constant char_neg : std_logic_vector(3 downto 0) := "1101"; + constant char_e : std_logic_vector(3 downto 0) := "1110"; + constant char_r : std_logic_vector(3 downto 0) := "1111"; ---------------------------------------------------------------------------- -- declaration d'un tableau pour soumettre un vecteur de test diff --git a/pb_APP_log_comb.srcs/sources_1/new/Mux.vhd b/pb_APP_log_comb.srcs/sources_1/new/Mux.vhd index 6202d38..c586c57 100644 --- a/pb_APP_log_comb.srcs/sources_1/new/Mux.vhd +++ b/pb_APP_log_comb.srcs/sources_1/new/Mux.vhd @@ -51,25 +51,21 @@ architecture Behavioral of Mux is constant char_E : STD_LOGIC_VECTOR(3 downto 0) := "1110"; -- E constant char_r : STD_LOGIC_VECTOR(3 downto 0) := "1111"; -- r (for "Er") - signal break : BOOLEAN := FALSE; - begin decide : process(ADCBin, Dizaines, Unites_ns, BTN, erreur, S2, Code_signe, Unite_s) begin -- HANDLE SWITCH {{{ if ( (S2 = pressed) or (erreur = '1')) then - break <= TRUE; -- Avoids double printing on 7seg DAFF1 <= char_E; DAFF0 <= char_r; - end if; -- }}} + else -- HANDLE BUTTONS {{{ - if break = FALSE then case (BTN) is when "00" => - DAFF0 <= Unites_ns; - DAFF1 <= Dizaines; + DAFF0 <= Unites_ns; + DAFF1 <= Dizaines; when "01" => -- impossible de buster "C" en hex -- encore moins avoir une deuxième décimale @@ -85,9 +81,9 @@ begin when others => DAFF1 <= char_E; DAFF0 <= char_r; - end case; + end case; + -- }}} end if; - -- }}} end process; -- cgit v1.2.3