VHDL-Xilinx-Simulation (signal not connected to port) ?

Dec 24, 2003 1 Replies

Hi.



How to simulate (observe) signals not connected to port (Xiilinx ISE WebPack-ModelSim XE). For example signal counter in project test.vhd.



Best regards Jarek


-----test.vhd library IEEE; use IEEE.STD_LOGIC_1164.ALL; use IEEE.STD_LOGIC_ARITH.ALL; use IEEE.STD_LOGIC_UNSIGNED.ALL;



entity Test is Port ( clock: in std_logic; -- system clock (25 MHz) resetn: in std_logic; -- active low reset c_out: out std_logic); end Test;



architecture Behavioral of Test is



signal counter: std_logic_vector(3 downto 0); begin



COUNT: process (clock, resetn) begin if (resetn = '0') then counter '0'); elsif (clock'event and clock = '1') then counter resetn, c_out => c_out );



clock


To see the waveform "counter", try this:

vsim testbench -do "add wave sim:/testbench/uut/*; run 4 uS;"

To use "counter" in a testbench, you can package it, or bring it out to a port, or use modelsim signal spy.

-- Mike Treseler

Join the Discussion

Have something to add? Share your thoughts — no account required.

Didn't find your answer?

Ask the community — no account required