纯小白在写作业,可是map过不去?报错啊.求助! xilinx,ISE写期末作业,很简单的键盘译码.但是在map中过不去,貌似是键盘扫描程序有问题.贴在下面了,下面还有report,问题简单,大家不要笑,麻烦指出

来源:学生作业帮助网 编辑:作业帮 时间:2024/04/30 21:24:43

纯小白在写作业,可是map过不去?报错啊.求助! xilinx,ISE写期末作业,很简单的键盘译码.但是在map中过不去,貌似是键盘扫描程序有问题.贴在下面了,下面还有report,问题简单,大家不要笑,麻烦指出
纯小白在写作业,可是map过不去?报错啊.求助! xilinx,ISE

写期末作业,很简单的键盘译码.但是在map中过不去,貌似是键盘扫描程序有问题.贴在下面了,下面还有report,问题简单,大家不要笑,麻烦指出错误,谢谢!为什么被删了那么多信号呢?report中.

 

 

library IEEE;

use IEEE.STD_LOGIC_1164.ALL;

use IEEE.STD_LOGIC_ARITH.ALL;

use IEEE.STD_LOGIC_UNSIGNED.ALL;

ENTITY KEY_SCAN IS

PORT (

clk : IN std_logic:='0'; 

row : IN std_logic_vector(3 DOWNTO 0):="1111"; -- 键盘行向量

press : OUT std_logic:='0'; 

column : BUFFER std_logic_vector(3 DOWNTO 0); -- 输出列向量

code : BUFFER std_logic_vector(3 DOWNTO 0):="ZZZZ" -- 键盘编码0~f

); 

END KEY_SCAN;

ARCHITECTURE Behavioral OF KEY_SCAN IS

SIGNAL clk_scan : std_logic;

SIGNAL code_old : std_logic_vector(3 DOWNTO 0):="ZZZZ"; 

SIGNAL cnt_key : integer range 1 to 8; 
BEGIN

process(clk)

variable tt: integer:=0;

begin

tt:=tt+1;

if(tt=9) then tt:=1; end if; 

cnt_key<=tt;

end process;

process(clk,cnt_key)

begin

if(cnt_key<5)then

clk_scan<='1';

else

clk_scan<='0'; 

end if;

end process;

process(clk_scan)

variable t: integer:=0;

begin

if(clk_scan'EVENT and clk_scan='1')then

case t is

when 0=>column<="1110";

when 1=>column<="1101";

when 2=>column<="1011";

when 3=>column<="0111";

when others=>null;

end case;

t:=t+1;

if(t=4) then t:=0; end if; 

end if;

end process;

process(clk)

begin 

if(cnt_key>1 and cnt_key<5)then

case column is 

when "1110" =>

case row is

when "1110" =>code<= "0000";

when "1101" =>code<= "0001"; 

when "1011" =>code<= "0010";

when "0111" =>code<= "0011"; 

when OTHERS =>code<= "ZZZZ"; 

end case;

省略一部分译码

when OTHERS =>code<= "ZZZZ";

end case;

when OTHERS =>code<= "ZZZZ";

end case;

else

code<= "ZZZZ";

end if;

if(cnt_key=4) then

code_old<=code;

end if;

end process;

process(clk)

begin

if(code_old/=code and code/="ZZZZ") then

if(cnt_key=3) then

press<='1';

else

press<='0';

end if;

else

press<='0';

end if;

end process; 

END Behavioral;



这是report.

 

Section 1 - Errors

------------------

ERROR:MapLib:661 - LUT3 symbol "XLXI_4/_n0046131" (output signal=CHOICE875) has

input signal "XLXI_4/_n0034" which will be trimmed. See the trim report for

details about why the input signal will become undriven.

省略

 

Section 5 - Removed Logic

 

The signal "XLXI_4/t<1>" is unused and has been removed.

The signal "XLXI_4/code_old<2>" is unused and has been removed.

The signal "XLXI_4/code_old<0>" is unused and has been removed.

The signal "XLXI_4/key_scan__n0007<4>_cyo" is unused and has been removed.

 

省略

纯小白在写作业,可是map过不去?报错啊.求助! xilinx,ISE写期末作业,很简单的键盘译码.但是在map中过不去,貌似是键盘扫描程序有问题.贴在下面了,下面还有report,问题简单,大家不要笑,麻烦指出
这个这么长... 你把工程发我邮箱1962983818@qq.com 我看看

。。。。。

纯小白在写作业,可是map过不去?报错啊.求助! xilinx,ISE写期末作业,很简单的键盘译码.但是在map中过不去,貌似是键盘扫描程序有问题.贴在下面了,下面还有report,问题简单,大家不要笑,麻烦指出 map容器只能在main函数中使用吗?我在main函数外定义了个函数,想会用map容器,可是MS2010提示错误.急, 如何提高写作业效率我的作业总是写不快,虽然我无时无刻都在刷刷的写,可是写作业总是没有同学快!有什么办法么? 临近开学了,很多同学忙着完作业,我也很想帮你们,可是只笼统的写上个作业的名称,怎么帮你们啊?是谁在 我是一个初中生,平时在学校里作业写的很快,效率又高,可是一回到家,写作业速度就慢了很多……我是一个初中生,平时在学校里作业写的很快,效率又高,可是一回到家,写作业速度就慢了很多, 作业还差好多,可是我不想写,怎么办 不想写作业,可是马上就要开学了, 我不想写作业可是明天上学怎么办 暑假快结束了,可是还是不想写作业怎么办 英语翻译可是英语作业里就是这样写的啊 This is a map.对a map提问怎么写? 现在好困不想写作业怎么办,尤其是数学,可是我每天都按时写作业 我不想写寒假作业可是明天要返校交作业……写作业好痛苦有木有 “过不去”一般指无法通过的路,但有的时候也会说到“和某某过不去”,在这里面的“过不去”又是什么意思? 一天到晚都在写作业. 在床上写作业好吗? Map判断时的区别if(map.get(COL_SUC_RATE)!=null )和if(!map.get(COL_SUC_RATE).toString())和if(!map.get(COL_SUC_RATE).equals()) 解释一下这些分别是在判断什么?区别是什么?上面写错了:if(map.get(COL_SUC_RATE)!=null 是在java.util.Map Map.可以的话请写个例子