forked from kranfix/rs232
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
implementing new read and write methods.
Version 2 uses a read/write worker in the RS232 wrapper class. Because of this the old methods are now split out. They still exist in case immediate read/write is wanted or for the implementation of other custom wrapper classes. All preexsiting read functions were unified into a retrieveFirstMatch method. This one takes a regex pattern and performs a regex_search on the buffer. The first result is returned and the buffer is set to whatever is left after the match (result.suffix()). This drastically simplifies the code and the other functions will likely get updated the same way. There is also a function to get the full buffer without needing to perform a regex search.
- Loading branch information
Showing
6 changed files
with
478 additions
and
245 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.