Hi.
I use for my aplication a comunication rs-232 whith a microcontroler.
At one moment I must receve from microcontroler datas in a large quatites(8000 bytes) and some bytes are lost. I divided this information in
packeges of 100 bytes but even so I lose data(10 bytes). The data loses apairs randomly and I have no idea why this hapens.
For receiving the data I use these functions:
InstallComCallback (comport, LWRS_RXCHAR, 0, (int)EventChar[0],SerialaCallback, 0);
void CVICALLBACK SerialaCallback (int portNo,int eventMask, void *callbackData)
{
if(strLen!=0)
{
strLen = GetInQLen (comport);
status=ComRd (comport, readBuf,strLen);
status=FlushInQ (comport);
switch(strLen)
{
case 8: Fmt (Str
ing, "%s<%1x[b1w2p0]",readBuf);
SetCtrlVal (autopont, AutoPont_TBOX_RECEPTION, String);
break;
}
}
}
Thanks.