Hey Daniel,
Okay, I've gone through the registers (see my post regarding that distraction) and I can't see why the FreeRTOS UART Receive is shutting down.
I've reviewed the following UART registers:
C1, C2, C3, C4, C5
S1, S2
D
MA1, MA2
ED
MODEM
IR
PFIFO, CFIFO, SFIFO, TWFIFO, TCFIFO
and other than the RXEDGIF bit in S2 being different (when the first read works this bit is set, if it doesn't the bit is reset - what's interesting is that this bit becomes set on subsequent reads which is strange).
I don't want to get into too much of the BT Module I'm communicating with but I think I need to explain what's happening. The issue is that straight from the box the module runs at 19,200bps and I want to run it normally at 921,600bps. I can set the datarate of the module that is set in EEPROM (so later boots are at full speed) but for the first boot it is at 19,200bps.
On boot, I do a test communication at 921,600bps as this is the datarate the module will be running at every time except the first time - if I get a good reply packet then I just continue with the rest of the application.
If I don't get a good reply, I cycle power on the unit and change the Kinetis baud rate to 19,200bps and then go through a process where I set the baud rate to 921,600bps. Since RTOS_UART_Receive is no longer working, this process can't go forwards.
I must point out that I am porting code from MQX, so I know this process and BT Module works.
Can you suggest where I should be looking for the error that stops FreeRTOS receives?
Thank you.