2021-08-23 06:33 AM
FUNC 1) HAL_SPI_Transmit(ILI9341_SPI_Handle,&data,1,100);
The output waveform is observed with SCLK / MOSI PIN.
FUNC 2) HAL_SPI_Transmit_DMA(ILI9341_SPI_Handle,&data,1);
Output waveform does not appear with SCLK / MOSI PIN.
After executing HAL_SPI_Transmit_DMA once
(check function)
HAL_SPI_StateTypeDef err;
err = HAL_SPI_GetState(ILI9341_SPI_Handle);
while(err != HAL_SPI_STATE_READY){
err = HAL_SPI_GetState(&hspi1);
}
The result continues to return err (HAL_SPI_STATE_BUSY_TX).
Below is a picture of CUMEMX setup.
//======================== PS
HAL_ADC_Start_DMA(&hadc1,&adc_dma_buffer[0], 4);
Also, it doesn't work.
What did I miss, where did I go wrong?
Solved! Go to Solution.
2021-08-23 10:19 AM
Ensure MX_DMA_Init is called before MX_SPI_Init.
2021-08-23 10:19 AM
Ensure MX_DMA_Init is called before MX_SPI_Init.
2021-08-23 09:53 PM
Wow!
Previously, the project was applied in order in hal, but as TDK said, it was changed.
Really thankful.
It works normally now.