A
ALuPin@web.de
Guest
Hi,
I have two modules A,B connected at their serial bidirectional port.
entity tb_testscenario is
end tb_testscenario;
architecture arch_tb_testscenario of tb_testscenario is
component A
port( ...
Data_io : inout std_logic;
...
end component;
component B
port( ...
Data_io : inout std_logic;
...
end component;
signal t_data : std_logic;
begin
ut1 : A
port map ( ...
Data_io => t_data,
...
);
ut2 : B
port map ( ...
Data_io => t_data,
...
);
end arch_tb_testscenario;
Now I want a third module C to insert a glitch while the bus is driven
'Z'.
The port map of C in the toplevel is the following:
ut3: C
port map ( Clk_i => t_clk,
Ena_i => t_ena,
Data_io => t_data
);
The component itself looks like the following:
entity C is
port( Clk_i, Ena_i : in std_logic;
Data_io : inout std_logic
);
end C;
architecture arch_C of C is
begin
p_inject: process
begin
wait until Clk_i='1';
Data_io <= 'Z';
if Ena_i='1' then
Data_io <= '0';
end if;
end process p_inject;
end arch_C;
This approach works so far.
How can I insert the glitch while modules A or B are driving data on
the bidirectional line ?
Thank you for your opinion.
Rgds
Andre
I have two modules A,B connected at their serial bidirectional port.
entity tb_testscenario is
end tb_testscenario;
architecture arch_tb_testscenario of tb_testscenario is
component A
port( ...
Data_io : inout std_logic;
...
end component;
component B
port( ...
Data_io : inout std_logic;
...
end component;
signal t_data : std_logic;
begin
ut1 : A
port map ( ...
Data_io => t_data,
...
);
ut2 : B
port map ( ...
Data_io => t_data,
...
);
end arch_tb_testscenario;
Now I want a third module C to insert a glitch while the bus is driven
'Z'.
The port map of C in the toplevel is the following:
ut3: C
port map ( Clk_i => t_clk,
Ena_i => t_ena,
Data_io => t_data
);
The component itself looks like the following:
entity C is
port( Clk_i, Ena_i : in std_logic;
Data_io : inout std_logic
);
end C;
architecture arch_C of C is
begin
p_inject: process
begin
wait until Clk_i='1';
Data_io <= 'Z';
if Ena_i='1' then
Data_io <= '0';
end if;
end process p_inject;
end arch_C;
This approach works so far.
How can I insert the glitch while modules A or B are driving data on
the bidirectional line ?
Thank you for your opinion.
Rgds
Andre