UART and watchdog

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

UART and watchdog

2,400件の閲覧回数
FordFairlaneBen
Contributor I
Hi everyone:
I´m using the SCI transmitter to send and receive data at 9600baud. With the transmission I have no problem but when I try to receive I get the next problem:
I send 3 bytes from the PC and the MC9s08AW resets because of the watchdog. Why this happens?
Thank you very much.
Best regards
ラベル(1)
0 件の賞賛
返信
2 返答(返信)

909件の閲覧回数
mke_et
Contributor IV
Right away I'd look at your receive routine. If you're using a polled routine, make sure it gets out on a regular basis to kick the watchdog. If it's an interrupt routine, then look for where it's hanging and not exiting.
0 件の賞賛
返信

909件の閲覧回数
rocco
Senior Contributor II
Hi, Ford:

In addition to what mke_et said, make sure you are clearing the interrupt flag, if you are using interrupts.

Read the status register before reading the data register, or the interrupt flag will remain set, and you will loop through your ISR forever.
0 件の賞賛
返信