大家好,
这是关于ps2鼠标协议的一个例子。
最高实体:
en
tity mouse_led是
港口 (
clk,reset:in std_logic;
ps2d,ps2c:inout std_logic;
led:out std_logic_vector(7 downto 0)
);
结束mouse_led;
和我的constratints:
顶部的限制
#CLK声明并连接到C9 50 MHz时钟
NET“clk”PERIOD = 20.0ns HIGH 50%;
NET“clk”LOC =“C9”|
IOSTANDARD = LVTTL;
NET“重置”LOC =“K17”|
IOSTANDARD = LVTTL |
拉下;
#
#PS2 PINS
NET“ps2c”LOC“G14”|
IOSTANDARD = LVCMOS33 |
SLEW = SLOW |
DRIVE = 8;
NET“ps2d”LOC“G13”|
IOSTANDARD = LVCMOS33 |
SLEW = SLOW |
DRIVE = 8;
##################################### OUTPUTS ############
#################
#LED引脚
#
NET“led”LOC =“F9”|
IOSTANDARD = LVTTL |
SLEW = SLOW |
DRIVE = 8;
NET“led”LOC =“E9”|
IOSTANDARD = LVTTL |
SLEW = SLOW |
DRIVE = 8;
NET“led”LOC =“D11”|
IOSTANDARD = LVTTL |
SLEW = SLOW |
DRIVE = 8;
NET“led”LOC =“C11”|
IOSTANDARD = LVTTL |
SLEW = SLOW |
DRIVE = 8;
NET“led”LOC =“F11”|
IOSTANDARD = LVTTL |
SLEW = SLOW |
DRIVE = 8;
NET“led”LOC =“E11”|
IOSTANDARD = LVTTL |
SLEW = SLOW |
DRIVE = 8;
NET“led”LOC =“E12”|
IOSTANDARD = LVTTL |
SLEW = SLOW |
DRIVE = 8;
NET“led”LOC =“F12”|
IOSTANDARD = LVTTL |
SLEW = SLOW |
DRIVE = 8;
#
#文件结束
#
翻译失败:
警告:ConstraintSystem:176 - 在文件中:contraints.ucf(8):语法错误。
确保先前的约束规范以';'终止。
警告:ConstraintSystem:176 - 在文件中:contraints.ucf(9):语法错误。
确保先前的约束规范以';'终止。
为什么?
我不明白。
针脚不在。
这是一个问题吗?
这是我第一次尝试输入引脚。
以上来自于谷歌翻译
以下为原文
Hi all,
this is an example on ps2 mouse protocol.
The top entity :
entity mouse_led is port ( clk, reset: in std_logic; ps2d, ps2c: inout std_logic; led: out std_logic_vector(7 downto 0) );end mouse_led;
and my constratints:
Constraints for top# CLK declared and connected to C9 50 MHz clockNET "clk" PERIOD = 20.0ns HIGH 50%;NET "clk" LOC = "C9" | IOSTANDARD = LVTTL;NET "reset" LOC = "K17" | IOSTANDARD = LVTTL | PULLDOWN;## PS2 PINSNET "ps2c" LOC "G14" | IOSTANDARD = LVCMOS33 | SLEW = SLOW | DRIVE = 8;NET "ps2d" LOC "G13" | IOSTANDARD = LVCMOS33 | SLEW = SLOW | DRIVE = 8;##################################### OUTPUTS ############################## LED pins #NET "led<7>" LOC = "F9" | IOSTANDARD = LVTTL | SLEW = SLOW | DRIVE = 8;NET "led<6>" LOC = "E9" | IOSTANDARD = LVTTL | SLEW = SLOW | DRIVE = 8;NET "led<5>" LOC = "D11" | IOSTANDARD = LVTTL | SLEW = SLOW | DRIVE = 8;NET "led<4>" LOC = "C11" | IOSTANDARD = LVTTL | SLEW = SLOW | DRIVE = 8;NET "led<3>" LOC = "F11" | IOSTANDARD = LVTTL | SLEW = SLOW | DRIVE = 8;NET "led<2>" LOC = "E11" | IOSTANDARD = LVTTL | SLEW = SLOW | DRIVE = 8;NET "led<1>" LOC = "E12" | IOSTANDARD = LVTTL | SLEW = SLOW | DRIVE = 8;NET "led<0>" LOC = "F12" | IOSTANDARD = LVTTL | SLEW = SLOW | DRIVE = 8;## End of File#
The translation fail for :
WARNING:ConstraintSystem:176 - In file: contraints.ucf(8): Syntax error. Ensure that the previous constraint specification was terminated with ';'.
WARNING:ConstraintSystem:176 - In file: contraints.ucf(9): Syntax error. Ensure that the previous constraint specification was terminated with ';'.
Why ? I don't understand it. The pins are inout. Is this a problem ? This is my first attempt on input pins.
0