code: def stop(self):
          
          self.camera._get_config()['actions']['movie'].set(False)
          self.videofile = self.camera._wait_for_event(
              event_type=lib.GP_EVENT_FILE_ADDED)
          if self._old_captarget != "Memory card":
              self.camera.config['settings']['capturetarget'].set(
                  self._old_captarget)
docs: Stop the capture.