MC9S08JM32 SCI question

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

MC9S08JM32 SCI question

710件の閲覧回数
Betadine
Contributor III

Hi All,

 

Is the first time I write the SCI code for RS232. The Processor Expert helps a lot, but I can´t understand a very simple question:

 

Why I must activate interrupts for sending and receiving more than one character?

I only can edit the buffer size once I activate the IRQs... why it´s linked?

 

Am I missing something?

 

Cheers.

ラベル(1)
0 件の賞賛
2 返答(返信)

275件の閲覧回数
peg
Senior Contributor IV

Hello,

 

This must be a limitation imposed by Processor Expert as there is no necessity to do so imposed at the chip level. As long as you can poll in less than a byte time you don't need receive interrupts and unless there is some timing requirement imposed by the other end of your link you don't need transmit interrupts.

0 件の賞賛

275件の閲覧回数
Betadine
Contributor III

Ok, I will make some tests... more clearly now

 

Receiving from the PC can be usefull to use the RxInterrupt in the MCU?

My program is very simple. PC says: "hey! send the data, and the MCU answers.

 

Independtly of stop and wait mode, I think it´s more gently to "wake up" the MCU through the interrupt instead of seeking the buffer constantly in the main loop.

So I think this is the common way to receive data from the PC...

 

Thanks

 

 

0 件の賞賛