Hello,
I have a problem with Mipi Dsi driver for MX RT 1170, The system works fine when I need just to write to the display, but I can't receive data from the display. I create the dsi command in this way:
status_t MIPI_DSI_DCS_GetPowerMode(mipi_dsi_device_t *device, uint8_t *rxDataBuffer)
{
dsi_transfer_t dsiXfer = {0};
uint8_t txData;
dsiXfer.virtualChannel = device->virtualChannel;
dsiXfer.txDataType = kDSI_TxDataGenShortRdOneParam;
dsiXfer.txDataSize = 1;
dsiXfer.rxDataSize = 1;
dsiXfer.txData = &txData;
txData = (uint8_t)kMIPI_DCS_GetPowerMode;
dsiXfer.rxDataSize = 1;
dsiXfer.rxData = rxDataBuffer;
return device->xferFunc(&dsiXfer);
}
But the system get stuck in status_t DSI_TransferBlocking(MIPI_DSI_Type *base, dsi_transfer_t *xfer), in the while (true):
/* Wait for transfer finished. */
while (true)
{
/* Transfer completed. */
if (0U == (apb->PKT_STATUS & (uint32_t)kDSI_ApbNotIdle))
{
break;
}
/* Time out. */
if (0U != (base->host->RX_ERROR_STATUS &
((uint32_t)kDSI_RxErrorHtxTo | (uint32_t)kDSI_RxErrorLrxTo | (uint32_t)kDSI_RxErrorBtaTo)))
{
DSI_GetAndClearInterruptStatus(base, &intFlags1New, &intFlags2New);
return kStatus_Timeout;
}
}
apb->PKT_STATUS is always equal to 1 (kDSI_ApbNotIdle) and base->host->RX_ERROR_STATUS is always equal to 0.
I tried to read the RDDPM "Read Display Power".
There is something wrong in the command or maybe the configuration of the device?
Attached the debug data, thanks for your help!
Regards