Harmony Configured SPI Receive Always Returns 0
I've used the MPLAB Harmony Configurator to setup SERCOM6 as SPI on an ATSAME54P20A. Whenever I use the following Harmony API to send/receive:
SERCOM6_SPI_WriteRead(&txBuffer, txSize, &rxBuffer, rxSize);
The receive buffer always returns all 0's. Now I have verified that the SPI slave device is responding and that signals other than 0 are making it onto the MISO pin.
I have attached my SPIConfig.PNG which shows the settings. I've attached SPIConfig2.PNG which shows the SPI Driver and project graph setup.
SERCOM6_SPI_Initialize() is called during start-up from SYS_Initialize.
The init appears to set the pin properly:
/* Configure Data Out Pin Out , Master Mode,
* Data In and Pin Out,Data Order and Standby mode if configured
* and Selection of the Clock Phase and Polarity and Enable the SPI Module
SERCOM6_REGS->SPIM.SERCOM_CTRLA = SERCOM_SPIM_CTRLA_MODE_SPI_MASTER | SERCOM_SPIM_CTRLA_DOPO_PAD0 | SERCOM_SPIM_CTRLA_DIPO_PAD3 | SERCOM_SPIM_CTRLA_CPOL_IDLE_HIGH | SERCOM_SPIM_CTRLA_CPHA_TRAILING_EDGE | SERCOM_SPIM_CTRLA_DORD_MSB | SERCOM_SPIM_CTRLA_ENABLE_Msk ;
Transmissions are working fine but the receive data is always 0. This has been tried on multiple pieces of hardware as well so I don't believe it is a hardware issue. I've included BusSIgnals.PNG that shows the signals on the MCU pin.
Is there a configuration I am overlooking? A bug in the framework? Some errata that I'm overlooking?
Guidance on how to resolve this would be greatly appreciated.