if (pcComm == 0x00)
{
if ((dataCount == 22) && (RcvData[18] == 0x39)) Status = 'F';
else if ((dataCount == 20) && (RcvData[18] == 0x3a)) Status = 'N';
else if ((dataCount == 13) && (RcvData[11] == 0x33)) Status = 'T';
}
or
this code
if ((PcComm == 0x01) && (dataCount == 20) && (RcvData[18] == 0x31)) printf(usb_cdc_putc, "Ok.");
but if i have both of them as shown above it does not work. ANY IDEAS?
Thanks and Regards,
Jai
dyeatman
Joined: 06 Sep 2003 Posts: 1934 Location: Norman, OK
Posted: Thu Jan 08, 2009 7:44 am
When you ask a question please be clear. What do you mean by "not working"?
Without knowing your answer I can already see a potential problem where you trying to PRINTF inside the timer routine. DOZENS of times we have said here to get out of an interrupt as quickly as possble. While in the interrupt routine do not transmit or print anything. It is even advised to avoid floatng point.
Why are you disablng the Timer interrupt in INT_RDA? If a Timer interrupt comes in during INT_RDA it won't be serviced until INT_RDA is completed.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum