瀏覽代碼

Disable ADC and timer

Noticed if ADC interrupt wasn't properly disabled
there appeared issues with other applications.
anfractuosity 2 年之前
父節點
當前提交
62637e6efc
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      scenes/scope_scene_run.c

+ 4 - 0
scenes/scope_scene_run.c

@@ -544,6 +544,10 @@ void scope_scene_run_on_enter(void* context) {
 
     furi_hal_bus_disable(FuriHalBusTIM2);
 
+    // Disable ADC interrupt and timer
+    LL_ADC_DisableIT_OVR(ADC1);
+    LL_TIM_DisableCounter(TIM2);
+
     // Stop DMA and switch back to original vector table
     LL_DMA_DisableChannel(DMA1, LL_DMA_CHANNEL_1);