MC9S08JM32 SCI question

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

MC9S08JM32 SCI question

1,234 次查看
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 回复数

799 次查看
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 项奖励
回复

799 次查看
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 项奖励
回复