소스 검색

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);