File tree Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Expand file tree Collapse file tree 1 file changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -191,11 +191,12 @@ esp_err_t ll_cam_deinit(cam_obj_t *cam)
191191 esp_intr_free (cam -> dma_intr_handle );
192192 cam -> dma_intr_handle = NULL ;
193193 }
194- gdma_disconnect (cam -> dma_channel_handle );
195- gdma_del_channel (cam -> dma_channel_handle );
196- cam -> dma_channel_handle = NULL ;
197- // GDMA.channel[cam->dma_num].in.link.addr = 0x0;
198-
194+ if (cam -> dma_channel_handle ) {
195+ // gdma_disconnect(cam->dma_channel_handle); // not needed since code never calls gdma_connect() to connect channel to peripheral
196+ gdma_del_channel (cam -> dma_channel_handle );
197+ cam -> dma_channel_handle = NULL ;
198+ // GDMA.channel[cam->dma_num].in.link.addr = 0x0;
199+ }
199200 LCD_CAM .cam_ctrl1 .cam_start = 0 ;
200201 LCD_CAM .cam_ctrl1 .cam_reset = 1 ;
201202 LCD_CAM .cam_ctrl1 .cam_reset = 0 ;
You can’t perform that action at this time.
0 commit comments