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

persisting/new issues with mDNSCheck() #59

Closed
ubidefeo opened this issue Sep 3, 2016 · 5 comments
Closed

persisting/new issues with mDNSCheck() #59

ubidefeo opened this issue Sep 3, 2016 · 5 comments
Labels

Comments

@ubidefeo
Copy link

ubidefeo commented Sep 3, 2016

hi @gepd
I'm still having issues on Mac with how detection of port and board is handled in mDNSCheck().

I've placed some debugging code in there to see where it halts, and it's clearly the regExp failing something.
Unluckily I'm clueless about regExp, so I don't know what fails there.
Sure thing is if I execute search(r"[\d{3}\.]{3}", PORT) with PORT='/dev/tty.usbserial-A900adQQ' (my USB Serial port) in a Python console I get nothing.

I temporarily fixed it by just commenting out the return False so I can at least move on and work, but I think a better solution needs to be found here.
The previous fix based on if worked, but maybe not for everyone.
In my opinion, searching for the presence of tty, cu., COM (case insensitive) followed by a number might fix it for all the cases I'm aware of.

thanks for your attention
u.

@gepd
Copy link
Owner

gepd commented Sep 3, 2016

Sorry about that @ubidefeo

Can you try replacing the if for this line?

if(search(r"^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$", PORT) is not None and "esp" not in MCU.lower()):

(Remember to restart ST after the change)

It should not show the error this time

@gepd gepd added the Bug label Sep 3, 2016
@ubidefeo
Copy link
Author

ubidefeo commented Sep 3, 2016

worked like a charm, mister :)
I'm gonna have to learn some regExp at some time

thank you

@ubidefeo
Copy link
Author

ubidefeo commented Sep 3, 2016

by the way, about having to restart ST all the time, isn't there some way to tell ST to just reload a plugin?
it's silly that if you're patching/testing you have to restart the whole shebang.
I haven't looked into plugin dev yet because my Python skills are quite poor :)

@gepd
Copy link
Owner

gepd commented Sep 3, 2016

To avoid restart everytime I use this plugin: https://github.com/randy3k/PackageReloader
It's very useful!

@ubidefeo
Copy link
Author

ubidefeo commented Sep 3, 2016

ace!

@gepd gepd closed this as completed Sep 3, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants