Tello-Python
Tello-Python copied to clipboard
Python 3 (again)
Any thoughts to migrate the Tello-Python code to Python 3.X
I managed to migrate the H264 that it can be used with Python 3.X on my Raspberry PI. The rest is straightforward. So if someone could help to build the H264 dll or pyc from my fork could be helpful.
See my gist. udp video stream can be encoded by opencv:
https://gist.github.com/f41ardu/b75da46dae383e5c835295600deef604
I'm a beginner, but I would like to help. I want this project to be in python 3 for my project.
Stay tuned. I've nearly finalised it either on Raspberry x86 implementation. The implementation on my native Raspberry isn't completed yet. Be aware, video performance on a Raspberry PI3+ isn't perfect. But I assume that it will work on Linux, too. See my fork for further details.
Update: Test on Raspberry PI 3B. Videoperformance is slwo and I got still decoding errors:
[h264 @ 0x25a8c50] error while decoding MB 52 12, bytestream -7 [h264 @ 0x25a8c50] concealing 1977 DC, 1977 AC, 1977 MV errors in P frame [h264 @ 0x25a8c50] left block unavailable for requested intra mode [h264 @ 0x25a8c50] error while decoding MB 0 41, bytestream 1998 [h264 @ 0x25a8c50] concealing 289 DC, 289 AC, 289 MV errors in P frame [h264 @ 0x25a8c50] error while decoding MB 55 39, bytestream -8 [h264 @ 0x25a8c50] concealing 354 DC, 354 AC, 354 MV errors in P frame
Public comment from Ho.Yan in Zendesk ticket #31175:
Dear Developer,
Thank you for contacting DJI.
This question you can contact RYZE Tello's technical support: [email protected]
Warm Regards, DJI Developer Support
Hi,
Thanks for trying to port this to Python 3.X. I tried to install the original 2.7 version but received a warning that 2.7 is no longer supported (as of Jan 1st 2020, apparently). I'd like to get video_test up and running. I can help test for you but I'm probably not as good a Python programmer as yourself! :)
I saw @f41ardu that you are experiencing the decode problems - does this mean that the video_test isn't working yet in Python 3.X please? To be honest I don't think I really need video but would more likely need a still image from the stream...
Thanks again. WW.
I should have also mentioned that the 'one click install' couldn't install openCV either - not sure if that's related to Python 2.7 or something else. I haven't tried a manual install just yet though. Cheers, WW.
My fork works fine using Python3, only on PI 3+ is somewhat slow. But there is a wrong path in my README for the boost lib for Raspberry. Stay tuned I'll update soon. Do we have information on the performance in Ubuntu or ???
udp video stream can be encoded by opencv:
https://gist.github.com/f41ardu/b75da46dae383e5c835295600deef604
No need to use the h264 lib any longer. Migration to Phyton3 could become fairly easy.
So can we run this with Python3 or not? I'm sure I can manage. But any official support would be appreciated.
Any update on a Python3 version or progress of one we could create a PR. It looks a bit like this repo is abandoned by DJI.
very latancy with video stream how remove the latency?
(The last update was two years ago, so maybe no one is interested in this,) The easiest way to play Tello videos with the lowest latency using Python 3 is to use the h264decoder: https://github.com/DaWelter/h264decoder
If you are using windows you will need to replace some of the code. Here is a guide I wrote. https://github.com/meekworth/pylwdrone/issues/10#issuecomment-2396154826
Replace import libh264decoder
in tello.py with import h264decoder
.