-
Notifications
You must be signed in to change notification settings - Fork 121
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
macOS fixes (#49) #133
macOS fixes (#49) #133
Conversation
we don't really care, but if we do - we'd need to make iossiospeed ioctl work
This reverts commit 3d6c1b2.
Now I fixed the compilation errors on iOS (in 103a023 ). There is a test failing on x86_64-apple-darwin which I have not investigated further. |
Thank you! This looks fine to me. Only that failing CI test left. |
Yes, I noticed that test, too. I have not dug too deeply but I started to have a look. It will be some days before I can get back to this - if someone wants to jump in, I guess the issue is fairly localized and I'd be grateful. There is various baud_rate handling stuff with various Actually, I just now noticed that the test also fails on my machine when compiled natively ( |
This is superseded by #142. |
Why was this closed? Those changes are still required to make baudrate setting work on M1/2/3 macs. |
@KaSroka does #142 (released in 4.3.0 AFAIK) fix the issue for you? What problem are you seeing? I was testing on an M1 mac when I made that PR and it Worked For Me. As stated in PR #142, however, I do not understand things deeply enough to know why it resolved my issue, so there could indeed still be something left to resolve. |
And to your question
Because (to the best of my understanding) #142 does the same thing, but much simpler. |
I'm still seeing problems with setting the baud rate on my M1 mac on latest version. When I have switched to this PR it worked like a charm. And the only thing I'm changing is the version of serialport crate. |
Can you please describe the steps to reproduce your problem? |
I'm opening serial port like this: let port = serialport::new(port_path, 115200)
.baud_rate(115200)
.open()
.unwrap(); On the v4.3.0 it results in my USB<>UART converter running on 9600 baud rate |
Thank you for this snippet @KaSroka! I tried to reproduce the issue of the baud rate not being actually used with
gives me the expected 19,200 baud on the wire. I acutally checked the data on the wire with a logic analyzer. I'm running this on an M1 Mac with a SiLabs CP2102N USB serial adapter. How does your setup looks like? Especialy, which serial adapter are you using? What does |
Hi, this PR updates the changes made by @berkus in #49 to v4.2.2.
The git history is messy because I simply merged @berkus' original patch through the git history and kept it working. I'm fine to rewrite the history if requested.
The remaining changes with main could be further cleaned up. In particular, the iOS code looks to me like it won't compile, but I have not tested it. As I did this work already I wanted to leave it here in the hopes it could be merged or could help someone.