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

OSX returns ports that cannot be opened by default #1084

Closed
reconbot opened this issue Feb 7, 2017 · 5 comments · Fixed by #1242
Closed

OSX returns ports that cannot be opened by default #1084

reconbot opened this issue Feb 7, 2017 · 5 comments · Fixed by #1242
Labels
feature-request Feature or Enhancement

Comments

@reconbot
Copy link
Member

reconbot commented Feb 7, 2017

SerialPort version: 5.x
Operating System and Hardware Platform: OSX

Summary of Problem

OSX SerialPort.list returns /dev/cu.xxx ports but tries to lock them by default and they cannot be locked. Only /dev/tty.xxx ports can be locked.

The code that find's the path of the port.

Thanks to #1070 and @lynndylanhurley for the report!

@dcyoung
Copy link

dcyoung commented May 2, 2017

I saw the comments about passing {lock:false} into the open options, but is there any workaround that permits the use of the SerialPort.list

If not, is there a way to catch or avoid this error when using SerialPort.list, even if we can't properly return the port?

@reconbot
Copy link
Member Author

@dcyoung this issue is requesting someone make serialport list do what you ask

@reconbot
Copy link
Member Author

reconbot commented Jul 17, 2017

I cannot find a way to do this in c++. I'm having a hard time finding docs on the functions we use. Maybe a string replace from /dev/cu. to /dev/tty. is in order, unless anyone has better ideas. =|

@reconbot
Copy link
Member Author

Figured it out, will have the tty ports in the next release.

@lynndylanhurley
Copy link

Fantastic work @reconbot 😃

reconbot referenced this issue Jul 22, 2017
For the record, tty's are `DialinDevice`s and cu's are `CalloutDevice`s

Thanks to @kishinmanglani for helping me solve this!

The closest we could come to docs. https://opensource.apple.com/source/IOSerialFamily/IOSerialFamily-7/IOSerialFamily.kmodproj/IOSerialKeys.h
@lock lock bot locked and limited conversation to collaborators Feb 5, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature-request Feature or Enhancement
Development

Successfully merging a pull request may close this issue.

3 participants