Skip to content

Commit f5e6b7d

Browse files
committed
Move files to SRCWrapper Library.
1 parent 6804f8e commit f5e6b7d

File tree

2 files changed

+36
-13
lines changed

2 files changed

+36
-13
lines changed

Diff for: cores/arduino/stm32/dma.c renamed to libraries/SrcWrapper/dma.c

+36
Original file line numberDiff line numberDiff line change
@@ -667,6 +667,42 @@ void DMA2_Channel8_IRQHandler()
667667
}
668668
#endif
669669

670+
671+
/* Combined handlers
672+
DMA1_Ch2_3_DMA2_Ch1_2_IRQn
673+
DMA1_Ch4_7_DMA2_Ch3_5_IRQn
674+
DMA1_Channel2_3_IRQn
675+
DMA1_Channel4_5_6_7_IRQn
676+
DMA1_Channel4_5_IRQn
677+
DMA2_Channel4_5_IRQn
678+
*/
679+
680+
#if defined(DMA1_Channel2) && defined(DMA1_Channel3) && defined(DMA2_Channel1) && defined(DMA2_Channel2)
681+
/**
682+
* @brief DMA1 and DMA2 hander for channels 2,3 and 1,2
683+
* @param None
684+
* @retval None
685+
*/
686+
void DMA1_Ch2_3_DMA2_Ch1_2_IRQHandler()
687+
{
688+
if (dma_handles[DMA1_CHANNEL2_INDEX] != NULL) {
689+
HAL_DMA_IRQHandler(dma_handles[DMA1_CHANNEL2_INDEX]);
690+
}
691+
692+
if (dma_handles[DMA1_CHANNEL3_INDEX] != NULL) {
693+
HAL_DMA_IRQHandler(dma_handles[DMA1_CHANNEL3_INDEX]);
694+
}
695+
696+
if (dma_handles[DMA2_CHANNEL1_INDEX] != NULL) {
697+
HAL_DMA_IRQHandler(dma_handles[DMA2_CHANNEL1_INDEX]);
698+
}
699+
700+
if (dma_handles[DMA2_CHANNEL1_INDEX] != NULL) {
701+
HAL_DMA_IRQHandler(dma_handles[DMA2_CHANNEL2_INDEX]);
702+
}
703+
}
704+
#endif
705+
670706
#ifdef DMA1_Stream0
671707
void DMA1_Stream0_IRQHandler()
672708
{

Diff for: cores/arduino/stm32/dma.h renamed to libraries/SrcWrapper/dma.h

-13
Original file line numberDiff line numberDiff line change
@@ -46,19 +46,6 @@ extern "C" {
4646

4747
#include <stm32_def.h>
4848

49-
/**
50-
* @brief This function will get the interrupt number for a DMA
51-
* @param dma_handle : dma channel or strea
52-
* @retval None
53-
*/
54-
IRQn_Type get_dma_interrupt(
55-
#if defined(STM32F2xx) || defined(STM32F4xx) || defined(STM32F7xx)
56-
DMA_Stream_TypeDef
57-
#else
58-
DMA_Channel_TypeDef
59-
#endif
60-
*instance);
61-
6249
/**
6350
* @brief This function will store the DMA handle in the appropriate slot
6451
* @param dma_handle : dma handle

0 commit comments

Comments
 (0)