Skip to content

Changed code from PR #17 from 64 bytes to 32 bytes #29

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

Merged
merged 2 commits into from
May 16, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletions adafruit_gps.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,12 +187,9 @@ def _parse_sentence(self):
# pylint: disable=len-as-condition
# This needs to be refactored when it can be tested.

# Only continue if we have at least 64 bytes in the input buffer
# I've commented this out for now as not all sentences are 64 bytes long
"""
if self._uart.in_waiting < 64:
# Only continue if we have at least 32 bytes in the input buffer
if self._uart.in_waiting < 32:
return None
"""

sentence = self._uart.readline()
if sentence is None or sentence == b'' or len(sentence) < 1:
Expand Down