Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Preparation in order to support multiple OS #9

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

SumolX
Copy link

@SumolX SumolX commented May 16, 2024

Tested on MacOS even though currently the ch341 driver has not been updated by WCH these changes will allow us to eventually add support for when WCH releases an update. The main issues here was the overshadowing of the built-in module called "download" and having the UI thread moved to the main thread is required by macOS and potentially other operating systems.

@SumolX
Copy link
Author

SumolX commented May 16, 2024

These changes allow for initial support for Issues #7 however it is still heavily depended on WCH releasing a compatible driver update which I was notified by them its on their roadmap this year.

@@ -357,7 +357,7 @@ def create_downloading_firmware_window(self):
self.downloading_window_status = 1
self.downloading_window.overrideredirect(True)

self._main_window.attributes('-disable', True)
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unknown Tinker option. Supported options are as follows:

_tkinter.TclError: bad attribute "-disable": must be -alpha, -fullscreen, -modified, -notify, -titlepath, -topmost, -transparent, or -type

@SumolX SumolX changed the title Support multiple os Preparation in order to support multiple OS May 16, 2024
@nerdCopter
Copy link

how may i test on Linux? (commands?)

@nerdCopter
Copy link

nerdCopter commented Jul 21, 2024

stalls and does nothing. (Debian 12, Python 3)
image

@SumolX
Copy link
Author

SumolX commented Jul 21, 2024

At the moment only windows works but the refactoring allows the code to run on other OS but lacks the programming functionality until ch341 is ported to work on macOS and if someone is willing to perform the same porting of ch341 for Linux and tie into the application hooks.

but the issue you are running into is new. I wonder if TCL used by the app compatible with your version? Try an older version of TCL.

@nerdCopter
Copy link

At the moment only windows works but the refactoring allows the code to run on other OS but lacks the programming functionality until ch341 is ported to work on macOS and if someone is willing to perform the same porting of ch341 for Linux and tie into the application hooks.

i have not tested, but this fork has Linux ch341 port: https://github.com/FiorixF1/hdzero-programmer

@nerdCopter
Copy link

nerdCopter commented Aug 17, 2024

the aforementioned fork seemed to have worked. it flashed, i have to assume successfully; uncertain how to check version/commit SHA of powered on VTX.

EDIT: before the recent commits/SYNC from upstream, it worked, now with recent commits i cannot get the fork to run successfully. the fork works at commit git checkout 573ae74 for me (use old README , but /dev/ch34x_pis0 not /dev/ch341_pis0 and furthermore execute with sudo).
cc: @FiorixF1 (maybe he can enable issues on his repo)

@FiorixF1
Copy link

FiorixF1 commented Aug 23, 2024

Commit 3b1d0df of https://github.com/FiorixF1/hdzero-programmer works both on Windows and Linux.

On Linux you can read and write to VTXs. Monitor and Event RX have not been tested and probably they do not work because they use some functions that I don't find in the Linux driver.

UPDATE: I didn't think it could be possible, but I managed to make the communication work also with the monitor. I can change settings and flash firmware to it.
34568d6 includes this update and probably it works also with the Event RX (but I can't test because I don't have one).

@JesseFPV
Copy link

JesseFPV commented Sep 4, 2024

At the moment only windows works but the refactoring allows the code to run on other OS but lacks the programming functionality until ch341 is ported to work on macOS and if someone is willing to perform the same porting of ch341 for Linux and tie into the application hooks.

but the issue you are running into is new. I wonder if TCL used by the app compatible with your version? Try an older version of TCL.

Would this driver version not work? I see other projects have success with it.
LilyGO/LILYGO-T-OI#3 (comment)

@nerdCopter

This comment was marked as off-topic.

@wilderk
Copy link

wilderk commented Oct 12, 2024

@nerdCopter - I put in a pull request to the fork https://github.com/FiorixF1/hdzero-programmer to handle multiple device numbers because on Linux the device number can vary. It has been merged. Flashing should work smoother for you now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants