msg = "\r\n\n\nHello World!\0";
scia_msg(msg);
scia_msg(msg);
msg = "\r\nYou will enter a character, and the DSP will echo it back! \n\0";
scia_msg(msg);
scia_msg(msg);
for(;;)
{
msg = "\r\nEnter a character: \0";
scia_msg(msg);
{
msg = "\r\nEnter a character: \0";
scia_msg(msg);
// Wait for inc character
while(SciaRegs.SCIFFRX.bit.RXFFST !=1) { } // wait for XRDY =1 for empty state
while(SciaRegs.SCIFFRX.bit.RXFFST !=1) { } // wait for XRDY =1 for empty state
// Get character
ReceivedChar = SciaRegs.SCIRXBUF.all;
ReceivedChar = SciaRegs.SCIRXBUF.all;
// Echo character back
msg = " You sent: \0";
scia_msg(msg);
scia_xmit(ReceivedChar);
msg = " You sent: \0";
scia_msg(msg);
scia_xmit(ReceivedChar);
LoopCount++;
}
}
我实验之后的结果为:
发送第一段字符时,会按照程序运行,再发送一段字符时,不会按照程序进行
我需要发送一串字符,他会循环接收这串字符,而不是单纯的一个字节,
这段程序具体的含义是什么?为什么只能接收一次呢?

