Open byteit101 opened 5 years ago
Bump, JRuby 9.2.8.0 is released :)
Yea, sorry, 1/3 of the JRuby PRs didn't make it into .8. Will work on the other items now though
JRuby 9.2.9.0 is released :)
Sorry for bumping, but can we check if this can be merged now?
@deadprogram
Right, I think the only thing left was the windows jenkins run having issues. Unfortunately, I haven't had easy access to windows machines recently.
(Note this PR is still WIP, and should NOT be merged until this check list is finished)
This PR ditches the FFI calls to open & close in favor of using IO::for_fd so that we can use normal IO blocking & nonblocking methods. It still requires a bit of funkyness on windows, but it is working with MRI, and JRuby 9.2.8.0.dev + patches. This will fix #25 for the blocking, and will fix #36 as IO#flush works correctly out of the box now.
As part of this, I did some clean up of the API, and unfortunately this has some breaking changes for exceptions and return types. I went the safe way to minimize harm, but I still bumped the version to be cautious. Not sure if that's a good idea or not? Feedback greatly appreciated on that.
Third, I added lots of yard doc to all methods.
Fourth, I added a SerialPort class that enables compatibility on par with what the readme suggested already existed, but didn't quite.
Fifth, I added support for the HUPCL flag (Windows via
DtrControl
) to fix #15.Serial#reconfigure(hupcl: true|false)
orSerialPort#hupcl= true|false
Sixth, I added a bunch more tests for HUPCL & general API stuff. Unfortunately I couldn't figure out a way to do this without a second program, so 1/3 of the tests now depend on an arduino project, though they are skipped if not detected.
That's all for now. The patches for JRuby are jnr/jnr-enxio:master and https://github.com/jruby/jruby/pull/5774 branch https://github.com/byteit101/jruby/tree/winio)