Skip to content
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

Bugfix issue #7 on crc checksum failure #11

Merged
merged 15 commits into from
Dec 31, 2014
Merged

Bugfix issue #7 on crc checksum failure #11

merged 15 commits into from
Dec 31, 2014

Conversation

jquast
Copy link
Collaborator

@jquast jquast commented Dec 29, 2014

(Pull PR #8 and PR #10 first for smaller diff)

When a CRC checksum failure occurs and NAK is sent,

  1. we should purge any awaiting stdin as suggested by
    ymodem.txt and documented therein, i would suppose
    this may only be for ymodem, which has a kind of
    readahead buffer, though. For xmodem local testing
    piped with lrzsz, no data is purged.
  2. we should read the next start-of-header block, as
    is usually done when the checksum is valid -- this
    causes our 'seq1' to be SOH or STX, and seq2 fails
    1's complement and subsequent failures about unexpected
    sequence occur, otherwise.

As this is a bug, I have proposed bumping version to 0.4.0.

This implements travis-ci integration, yet untested. I will have to clone the
repository to allow travis-ci access for testing.  Once I added tox support,
I added python3 testing -- which immediately failed.  I spent some time adding
python3 support.  Some of it may incur some small overhead.  We can address
these if we decide on a new API for YMODEM (multi-file, file-like iface) support.

Additionally, debug logging is less verbose in the case of not logging each
successful checksum -- and more verbose in the case of indicating each and
every step through the transfer.  These were decorated as I went with the
python3 porting process.
…html

URLS at the top for the TXT documents fail, because the docs/ are not
provided with a source distribution
When a CRC checksum failure occurs and NAK is sent,

1. we should purge any awaiting stdin as suggested by
   ymodem.txt and documented therein, i would suppose
   this may only be for ymodem, which has a kind of
   readahead buffer, though.  For xmodem local testing
   piped with lrzsz, no data is purged.

2. we should read the next start-of-header block, as
   is usually done when the checksum is valid -- this
   causes our 'seq1' to be SOH or STX, and seq2 fails
   1's complement and subsequent failures about unexpected
   sequence occur, otherwise.
@coveralls
Copy link

Coverage Status

Changes Unknown when pulling de55d20 on fixing-crcfails into * on master*.

@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 75af6ba on fixing-crcfails into * on master*.

@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 471e4df on fixing-crcfails into * on master*.

@coveralls
Copy link

Coverage Status

Changes Unknown when pulling 42b026c on fixing-crcfails into * on master*.

tehmaze added a commit that referenced this pull request Dec 31, 2014
Bugfix issue #7 on crc checksum failure
@tehmaze tehmaze merged commit 3d7fbfa into master Dec 31, 2014
@tehmaze
Copy link
Owner

tehmaze commented Dec 31, 2014

Thanks again Jeff!

@jquast jquast deleted the fixing-crcfails branch December 31, 2014 17:43
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.

3 participants