Chip123 科技應用創新平台

 找回密碼
 申請會員

QQ登錄

只需一步,快速開始

Login

用FB帳號登入

搜索
1 2 3 4
查看: 3924|回復: 1
打印 上一主題 下一主題

[問題求助] 錯誤訊息

[複製鏈接]
跳轉到指定樓層
1#
發表於 2007-7-20 09:03:08 | 只看該作者 回帖獎勵 |倒序瀏覽 |閱讀模式
使用軟體:MAX+plus 26 T2 X5 `4 k# ]/ S) [/ v/ q2 H

& o5 {9 h7 D6 ^, A7 q" Y, ~( m錯誤訊息:warning Line 101:File c:\documents and setting\adminstrator\桌面\anew.vhd:
5 }, f* U! d& z7 ~Fuond multiple assignmengs to the same singal or signal bit"cutting0"in a Process Statement-
* Z$ X& U' C+ N3 konly the lase assignment will take effect* c5 R* g, e; K/ q; L
程式說明:, g3 J4 n# `' F2 z+ J
entity anew is
* T8 L7 E2 k$ M% r        port (
7 Z" S  C$ }, x0 k4 `                clock:in std_logic;/ q& [' u5 ^: |  _6 _+ n3 w
                enable:in std_logic;( w! C9 a4 B) a: v- g: M9 _
                direction:in std_logic;
6 Y8 j, ^2 c/ @4 Z                selection:in std_logic_vector(1 downto 0);
' V( Y: V* R3 }9 Z7 L                cutting:out std_logic_vector(3 downto 0);; m# d+ q$ s. I/ f
                phase:out std_logic_vector(3 downto 0));5 P$ J8 p* f/ I( z
end anew;
! H7 h2 }& v6 `3 B4 \; n4 Q  _3 `  U6 i4 n8 r5 {: X
architecture wena of anew is
  J% B; x- n; O5 [2 `/ _9 ybegin
1 r  V& A: L9 t1 v8 Y        process(clock,enable,direction,selection)  y" ^. g7 }% y3 L6 E" b/ R( S8 T
   0 d8 J9 K6 g7 G' Z/ A& h/ V$ V. U7 g
        variable countcut2:integer range 0 to 3;
4 c* n6 M+ J9 w/ L) }  q3 H        variable countcut3:integer range 0 to 7;
8 c' u8 V, W' y. L$ {        variable countcut4:integer range 0 to 15;
/ C7 f& S: ~; N" {: |0 r        variable countphase:integer range 0 to 7;
+ E( j. \! s( R1 @* F' F        cutting
8 ?1 r0 p6 K1 p- G宣告的四個variable均是對同一個輸出而設定
1 `% M0 ]% n8 _: B5 K7 L) [如果 variable countcut1:integer range 0 to 3;則輸出到cutting(1 downto 0)
# K  Y! @  J' G如果 variable countcut2:integer range 0 to 3;則輸出到cutting(2 downto 0)
# a4 x: z/ L+ ]3 s5 n0 e. R) L% e如果 variable countcut3:integer range 0 to 3;則輸出到cutting(3 downto 0)
- e) k( d$ L7 t- T以上的指定是用 : case  is  when ...
7 g* P( }2 x; [- t但四種狀態是個別發生3 h  ^+ |& ~( P. x. S1 C) G

) s8 s4 N: N, a出現的訊息說不能重覆設定不然只以最後一個設定為準
+ F* ~% U: g! W3 b  h$ Q7 p* G
+ z# F; [0 y) s' w. E請問有什麼方法可以解決此問題嗎
  f# a( v: _, Z8 N3 _$ P  ?/ D" V$ ~因為不想設定這麼多支接角(epm7032)- o- w4 {! b# v- q
也有試過將cutting:out std_logic_vector(3 downto 0);, {2 g- c7 ]! x9 b" C0 c
再分成用alias的子集合..但也不行
/ |: Z7 `! g6 d3 q3 s1 m$ z, P: Z1 v
麻煩前輩指導
分享到:  QQ好友和群QQ好友和群 QQ空間QQ空間 騰訊微博騰訊微博 騰訊朋友騰訊朋友
收藏收藏 分享分享 頂 踩 分享分享
2#
發表於 2007-7-21 04:05:48 | 只看該作者
雖然不是很懂你的問題, 不過我想你可能試著對一個在相同的時間上io port給予不同的值, 在實際的電路會造合成器翻譯時的困擾
2 v7 y  J8 B, T- n4 k如果同一個io port會有各種不同的輸出時, 最好是把case寫清楚, 而且最好是寫 full case
2 h" `1 L; L! }9 b# F7 H; B( }' @5 h" W
另外alias只是為了增加程式的易讀或好維護時用, alias指令並不會直接影響合成器輸出的結果
您需要登錄後才可以回帖 登錄 | 申請會員

本版積分規則

首頁|手機版|Chip123 科技應用創新平台 |新契機國際商機整合股份有限公司

GMT+8, 2025-2-24 12:38 AM , Processed in 0.158010 second(s), 18 queries .

Powered by Discuz! X3.2

© 2001-2013 Comsenz Inc.

快速回復 返回頂部 返回列表