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

AClient will not work on Windows #68

Open
RobertBaruch opened this issue Dec 30, 2018 · 3 comments
Open

AClient will not work on Windows #68

RobertBaruch opened this issue Dec 30, 2018 · 3 comments

Comments

@RobertBaruch
Copy link
Contributor

TLDR: Unless you're a Windows expert and know how to fix this, explicitly document that we do not support Windows.

AClient needs to open a COM port, but on Windows you need Administrator privilege to do that. And apparently even when you run a python script under Admin, it still refuses to open a com port, with error "Permission denied".

To test this, open a command prompt as admin (right click on command prompt, open as administrator), run python, and:

import os
os.open("\\.\COM", os.O_RDWR)

(Yes, you need all that backslash magic because Windows)

That will actually work. However, running otl866 will not, because otl866 is an exe, and I guess Windows trashes the permissions.

@JohnDMcMaster
Copy link
Owner

The core functions should abstract pexepect under the hood pretty well. I imagine we could write a generic pexpect replacement pretty easily just using pyserial read() and buffering it ourselves. The biggest drawback would be that we'd loose select and consume more CPU (at least on Windows)

@JohnDMcMaster
Copy link
Owner

Can we consolidate the other issues into this one? Seems like the core issue, and having the others open may make this difficult to track

@RobertBaruch
Copy link
Contributor Author

Well, I think this is really the only issue -- opening a COM port on Windows in Python via a script installed through setup.py -- and it's a bit of a tough nut to crack. Apparently even my Google-fu isn't good enough to find a workable solution to this one.

I've closed the other issue #67 .

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

No branches or pull requests

2 participants