void ISR78_DSPI0ISR(void)
{
volatile uint32_t DSPI_SR_Value;
receive_dspi_data0 = (uint16_t)DSPI_0.POPR.R;
DSPI_SR_Value = DSPI_0.SR.R;
DSPI_0.SR.R = DSPI_SR_Value | DSPI_SR_RFDF;
if(DSPI_0.SR.B.RXCTR == 0x0) {
receive_flag0 = 1;
}
}
In above code I am trying to read the DSPI status register and checking RXCTR value but I never get RXCTR value greater than zero even if I have received frame. I can see the RXCTR value in JTAG debugger window but when I take value DSPI_0.SR.R in variable I cant see the RXCTR value, it is always zero in the value stored in variable.
Please help