Skip to content

Commit

Permalink
Merge pull request #194 from 22ist1p/i44p-patch-1
Browse files Browse the repository at this point in the history
Fix inablility to receive video stream if VS_PORT was changed on init
  • Loading branch information
M4GNV5 authored Oct 9, 2023
2 parents f087cdb + 8494729 commit fa752af
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions djitellopy/tello.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,8 @@ class Tello:

# Video stream, server socket
VS_UDP_IP = '0.0.0.0'
VS_UDP_PORT = 11111
DEFAULT_VS_UDP_PORT = 11111
VS_UDP_PORT = DEFAULT_VS_UDP_PORT

CONTROL_UDP_PORT = 8889
STATE_UDP_PORT = 8890
Expand Down Expand Up @@ -585,13 +586,15 @@ def streamon(self):
"""Turn on video streaming. Use `tello.get_frame_read` afterwards.
Video Streaming is supported on all tellos when in AP mode (i.e.
when your computer is connected to Tello-XXXXXX WiFi ntwork).
Currently Tello EDUs do not support video streaming while connected
to a WiFi-network.
Tello EDUs support video streaming while connected to a
WiFi-network via SDK 3.
!!! Note:
If the response is 'Unknown command' you have to update the Tello
firmware. This can be done using the official Tello app.
"""
if self.DEFAULT_VS_UDP_PORT != self.vs_udp_port:
self.change_vs_udp(self.vs_udp_port)
self.send_control_command("streamon")
self.stream_on = True

Expand Down

0 comments on commit fa752af

Please sign in to comment.