On Thu, 5 Feb 2004 12:23:17 +0100, soltras wrote:
Thanks JC!
However I hardly understand your code:
1. Your putcharx(...) have int data in the argument. Is it char* or char?
2. Is DINT() necessary ? Is not enough IE1 &= ~UTXIE0
3. Are You AWARE that below code blocks main loop and UARTR0_RxBuf processing
in function like getcharx(int data), and all other stuff untill sending
completes. You will notice it when operation both uarts simultanously!
THE REASON is in a code: while (tmphead == UART0_TxTail);
I am looking for way around to fix it ( apart from increasing txbuffer) but so
far I am not sucessful. I am trying something like this:
while (tmphead == UART0_TxTail){
Do_everything_what_is_in_MainLoop();
I think the best and universal solution would be setjmp() to main loop and
after completing return back.
=====================================================================
If the queue is full and you cannot wait, why not just return a -1 and
let the foreground code try again later?
Regards
-Bill Knight
R O SoftWare