I'm completely new to VHDL and I wrote a code that's supposed to be a 16*4 RAM memory.I wrote a VHDL and VHDL testbench for it and I tried to add a user constraints file(ucf) to it and everything seems fine,except that It gives error on four of my pins.Here is my code:
NET "a<0>" LOC = "p51";
NET "a<1>" LOC = "p59";
NET "a<2>" LOC = "p48";
NET "a<3>" LOC = "p55";
NET "a<0>" LOC = "p51";
NET "a<1>" LOC = "p59";
NET "a<2>" LOC = "p48";
NET "a<3>" LOC = "p55";
NET "di<0>" LOC = "p66";
NET "di<1>" LOC = "p56";
NET "di<2>" LOC = "p57";
NET "di<3>" LOC = "p58";
NET "do<0>" LOC = "p78";
NET "do<1>" LOC = "p75";
NET "do<2>" LOC = "p64";
NET "do<3>" LOC = "p74";
The VHDL code:
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
use IEEE.NUMERIC_STD.ALL;
entity memory is
Port(
clk: in STD_LOGIC;
we: in STD_LOGIC;
a:inout integer RANGE 0 to 3; --read and write address-
di: in STD_LOGIC_VECTOR(3 downto 0);
do: out STD_LOGIC_VECTOR(3 downto 0)
);
end memory;
architecture Behavioral of memory is
TYPE mem IS ARRAY(0 TO 7) OF std_logic_vector(3 DOWNTO 0);
SIGNAL ram_block : mem ;
begin
process(clk)
begin
if(clk'event and clk='1') then
if(we='1') then
ram_block(a) <= di;
else
do <= ram_block(a);
end if;
end if;
end process;
end Behavioral;
And these are my errors:
ERROR:ConstraintSystem:59 - Constraint <NET "a<2>" LOC = "p48";>
[memoryPin.ucf(3)]: NET "a<2>" not found. Please verify that:
- The specified design element actually exists in the original design.
- The specified object is spelled correctly in the constraint source file. ERROR:ConstraintSystem:59 - Constraint <NET "a<3>" LOC = "p55";> [memoryPin.ucf(4)]: NET "a<3>" not found. Please verify that:
- The specified design element actually exists in the original design.
- The specified object is spelled correctly in the constraint source file. ERROR:ConstraintSystem:59 - Constraint <NET "a<2>" LOC = "p48";> [memoryPin.ucf(8)]: NET "a<2>" not found. Please verify that:
- The specified design element actually exists in the original design.
- The specified object is spelled correctly in the constraint source file. ERROR:ConstraintSystem:59 - Constraint <NET "a<3>" LOC = "p55";> [memoryPin.ucf(9)]: NET "a<3>" not found. Please verify that:
- The specified design element actually exists in the original design.
- The specified object is spelled correctly in the constraint source file.
I tried removing the entire 'a' pins from the ucf file,and the implement design seemed to work,however,as I said,I'm new to VHDL,and I don't quite understand the concept of the ucf file.I don't know if it is supposed to work correctly or not.I'd be glad if you helped.