Video Thread

Thread resposible for retrieving video stream from drone socket port=5555.

Video Specs

The video can run on 25 fps (frame per second) with a latency of ~2ms. The video stream is acquired using tcp protocol, for integral data transmission. The video is then decoded using opencv, and viewed in real-time fashion. You can close the view window by pressing q. See the following example for retrieving a video stream from a drone connection instance:

drone = Drone() # create drone instance
drone.connect_video() # initialize video stream

Refer to the official documentation for more details.

Command Class

class dronevis.drone_connect.video.VideoThread(*args, **kwargs)

Implementation of BaseVideoInterface for real drone

__init__(closing_callback, operation_callback, model_name, ip_address='192.168.1.1')

Initialize drone instance

Parameters:
  • closing_callback (Callable) – Callback to be invoked after closing thread

  • operation_callback (Callable) – Callback to be invoked after each operation

  • model_name (str) – Computer vision model to run inference on the video stream

  • ip_address (str, optional) – IP address of the drone. Defaults to “192.168.1.1”.