diff --git a/firmware/application/portapack.cpp b/firmware/application/portapack.cpp index 7d93bd40..d4d73cd3 100644 --- a/firmware/application/portapack.cpp +++ b/firmware/application/portapack.cpp @@ -21,6 +21,7 @@ #include "portapack.hpp" #include "portapack_hal.hpp" +#include "portapack_dma.hpp" #include "portapack_persistent_memory.hpp" #include "hackrf_hal.hpp" @@ -161,9 +162,14 @@ void init() { radio::init(); touch::adc::init(); + + LPC_CREG->DMAMUX = portapack::gpdma_mux; + gpdma::controller.enable(); } void shutdown() { + gpdma::controller.disable(); + display.shutdown(); radio::disable(); diff --git a/firmware/baseband/baseband.cpp b/firmware/baseband/baseband.cpp index 284b9471..198f1087 100644 --- a/firmware/baseband/baseband.cpp +++ b/firmware/baseband/baseband.cpp @@ -35,8 +35,6 @@ static void init() { audio::dma::configure(); audio::dma::enable(); - LPC_CREG->DMAMUX = portapack::gpdma_mux; - gpdma::controller.enable(); nvicEnableVector(DMA_IRQn, CORTEX_PRIORITY_MASK(LPC_DMA_IRQ_PRIORITY)); }