Re: 使用timer中斷 如何知道usart有接收?
|
||||
---|---|---|---|---|
版主
|
RCIF 只是用來判斷是否UART的接收中斷,若不是還可以判斷其它的中斷其耗找出是誰產生的中斷。
發表於: 2007/9/13 15:23
|
|||
|
Re: 使用timer中斷 如何知道usart有接收?
|
||||
---|---|---|---|---|
新會員
|
參照:
所以是判斷RCIF是否為1來判斷是不是接收中斷嗎?
發表於: 2007/9/12 17:52
|
|||
|
Re: 使用timer中斷 如何知道usart有接收?
|
||||
---|---|---|---|---|
版主
|
低優先權的基本設定看起來是沒有錯。
一個中斷進入點 (例如 : 高優先權) 可以支援好幾種周邊中斷,只要進入中斷後立即檢查各周邊的中斷其耗就可以知道是誰發生了中斷。
發表於: 2007/9/11 10:05
|
|||
|
Re: 使用timer中斷 如何知道usart有接收?
|
||||
---|---|---|---|---|
新會員
|
已經知道為什麼不能用高優先中斷了,原來是程式別的地方已經有在使用,所以我現在想要使用低優先權中斷,以下是我的中斷前置設定
IPEN=1 RCIP=0 RCIE=1 GIEH=1 GIEL=1 這樣設定對嗎?
發表於: 2007/9/10 20:11
|
|||
|
Re: 使用timer中斷 如何知道usart有接收?
|
||||
---|---|---|---|---|
資深會員
|
為何不用RCIF中斷?
發表於: 2007/9/10 19:10
|
|||
|
使用timer中斷 如何知道usart有接收?
|
||||
---|---|---|---|---|
新會員
|
之前有試過用高優先權中斷來判斷是否有接收資料,但是link一直無法過
所以現在想使用timer定時產生中斷來檢查usart是否有接收到資料,請問怎樣才可以知道usart有接收到資料呢?
發表於: 2007/9/10 18:35
|
|||
|