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

Calling setUsesRTSCTSFlowControl: while port is open causes an error later #104

Open
armadsen opened this issue Jun 12, 2016 · 0 comments
Open
Assignees
Labels
Milestone

Comments

@armadsen
Copy link
Owner

Presumably affects setUsesDTRDSRFlowControl: and setUsesDCDOutputFlowControl: too. The basic issue here is that these setters call -close, then subsequently call -open again. This used to work fine, but when I switched to using a dispatch_source for reading from the port, I made it so that -close asynchronously triggers the actual closure by cancelling the dispatch_source which in turn calls -reallyClosePort. So, here -close is called, then -open is called before -reallyClosePort is called.

Closing and reopening the port was done originally to work around what I assumed was a bug in (at least some) USB to serial drivers. Testing should be done to see if this is really still necessary. If it is, perhaps I can make it so that there's an optionally synchronous variant of close.

@armadsen armadsen added the bug label Jun 12, 2016
@armadsen armadsen added this to the 2.0.3 milestone Jun 12, 2016
@armadsen armadsen self-assigned this Jun 12, 2016
@armadsen armadsen changed the title Calling setUsesRTSCTSFlowControl: while port is open causes an error Calling setUsesRTSCTSFlowControl: while port is open causes an error later Jun 12, 2016
@armadsen armadsen modified the milestones: 2.0.3, 2.1 Jun 14, 2019
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

1 participant