Skip to content

Many fixes to handling continuous/multiple socket connections. #8

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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

MatthewMenze
Copy link

…FOR FULL FUNCTIONALITY. DEVICE CURRENTLY SHIPS WITH OBSOLETE FIRMWARE.

  • Added 2056 byte read and backlog buffers (can probably be made smaller)
  • Added a 1000uS window on read operations from module (can probably be made smaller)
  • Increased memory allocation to response/command variables in various functions to avoid out of bound memory writes.
  • Added bufferedPoll(), this replaces poll() functionality, but iterates over buffer and handles each event
  • Added some error handling to socketOpen()
  • Added some error handling to socketCloser()
  • Added error handling to socketWrite(), to not write in case of error.
  • Added delay before responding in socketWrite(), according to ublox specification
  • Added socketWriteUDP() function, to properly write UDP packets according to ublox spec.
  • Added error catching to socketRead()
  • Added socketGetLastError() function that requests last socket error from module, for debugging
  • Added expectedError parameter to waitForResponse() to allow function to exit without error without running entire timeout if it can
  • Added backlog buffering to waitForResponse()
  • Added backlog pruning to waitForResponse()
  • Improved error codes returned from waitForResponse()
  • Added backlog buffering and pruning to sendCommandWithResponse()
  • Added backlog buffering to sendCommand
  • Removed code that dumped read data in send command
  • Created function pruneBacklog() that parses backlog and prunes non-actionable events, reducing future processing time in poll, and reducing buffer size needs.
  • Added value to error enumeration to signify when module has returned an error from a command.

Matthew Menze added 2 commits May 16, 2020 11:01
…FOR FULL FUNCTIONALITY. DEVICE CURRENTLY SHIPS WITH OBSOLETE FIRMWARE.

- Added 2056 byte read and backlog buffers (can probably be made smaller)
- Added a 1000uS window on read operations from module (can probably be made smaller)
- Increased memory allocation to response/command variables in various functions to avoid out of bound memory writes.
- Added bufferedPoll(), this replaces poll() functionality, but iterates over buffer and handles each event
- Added some error handling to socketOpen()
- Added some error handling to socketCloser()
- Added error handling to socketWrite(), to not write in case of error.
- Added delay before responding in socketWrite(), according to ublox specification
- Added socketWriteUDP() function, to properly write UDP packets according to ublox spec.
- Added error catching to socketRead()
- Added socketGetLastError() function that requests last socket error from module, for debugging
- Added expectedError parameter to waitForResponse() to allow function to exit without error without running entire timeout if it can
- Added backlog buffering to waitForResponse()
- Added backlog pruning to waitForResponse()
- Improved error codes returned from waitForResponse()
- Added backlog buffering and pruning to sendCommandWithResponse()
- Added backlog buffering to sendCommand
- Removed code that dumped read data in send command
- Created function pruneBacklog() that parses backlog and prunes non-actionable events, reducing future processing time in poll, and reducing buffer size needs.
- Added value to error enumeration to signify when module has returned an error from a command.
…ted rough stack of code to listen for UDP packets. Still needs some cleanup.
PaulZC added a commit to sparkfun/SparkFun_u-blox_SARA-R5_Arduino_Library that referenced this pull request Oct 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant