Quantcast
Channel: Forums - Recent Threads
Viewing all articles
Browse latest Browse all 262198

UART Bytes missing with ISR

$
0
0

It seems that every hundred bytes or so, I miss a single byte from a uart packet that comes in through the ISR RX routine.  

I know that the transmission to the CC2540 is good because I am probing it with a secondary UART->RS232 converter that is showing the correct data. 

I was wondering if anyone has seen this issue before.

My RX Routine looks like: 

HAL_ISR_FUNCTION( halUart0RxIsr, URX0_VECTOR )
{

URX0IF = 0;
jcBuffer[jcCount++] = U0DBUF;


//find a carriage return
if(U0DBUF== '\r'){

     isrCfg.uartCB(HAL_UART_ISR-1, HAL_UART_RX_CR);
}else if(U0DBUF== '>'){
     len=0;
     isrCfg.uartCB(HAL_UART_ISR-1, HAL_UART_RX_ARROW);
     jcCount = 0;
}
}

Could this be a problem with a possible bad internal clock in the CC2540 that is timing the UART port properly?  Is there anything else i can dig into to find the root cause of this problem?


Viewing all articles
Browse latest Browse all 262198

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>