Skip to content

Commit a31a233

Browse files
committed
stm32h7_cm4: audio: add cache handling check for CM7
1 parent 373e7c6 commit a31a233

File tree

1 file changed

+4
-0
lines changed
  • libraries/PDM/src/STM32H747_dfsdm

1 file changed

+4
-0
lines changed

libraries/PDM/src/STM32H747_dfsdm/audio.c

+4
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,9 @@ void HAL_DFSDM_FilterRegConvHalfCpltCallback(DFSDM_Filter_HandleTypeDef *hdfsdm_
6868
{
6969
xfer_status |= DMA_XFER_HALF;
7070
// Invalidate Data Cache to get the updated content of the SRAM
71+
#ifdef CORE_CM7
7172
SCB_InvalidateDCache_by_Addr((uint32_t*)&RecBuff[0],sizeof(RecBuff)/2);
73+
#endif
7274
}
7375
PDMIrqHandler(true);
7476
}
@@ -86,7 +88,9 @@ void HAL_DFSDM_FilterRegConvCpltCallback(DFSDM_Filter_HandleTypeDef *hdfsdm_filt
8688
{
8789
xfer_status |= DMA_XFER_FULL;
8890
// Invalidate Data Cache to get the updated content of the SRAM
91+
#ifdef CORE_CM7
8992
SCB_InvalidateDCache_by_Addr((uint32_t*)&RecBuff[PDM_BUFFER_SIZE/2],sizeof(RecBuff)/2);
93+
#endif
9094
}
9195
PDMIrqHandler(false);
9296
}

0 commit comments

Comments
 (0)