SPRUJ17H March 2022 – October 2024 AM2631 , AM2631-Q1 , AM2632 , AM2632-Q1 , AM2634 , AM2634-Q1
Table 13-60 lists the receive-only procedure using the interrupt method.
Step | Register/Bit Field/Programming Model | Value |
---|---|---|
Configure the channel according to the mode. | See Table 13-32. | |
Start the channel. | MCSPI_CHCTRL_0/1/2/3[0] EN | 1 |
Enable the interrupt for the receiver register. | MCSPI_IRQENABLE[2] RX_FULL_ENABLE | 1 |
Wait for interrupt. | ||
Read the status register. | MCSPI_IRQSTATUS[2] RX_FULL | 1 |
Disable the interrupt if no more data is expected. | MCSPI_IRQENABLE[2] RX_FULL_ENABLE | 0 |
Stop the channel if no more data is expected. | MCSPI_CHCTRL_0/1/2/3[0] EN | 0 |
Read the receiver register. | MCSPI_RX_0/1/2/3 | 0x- |