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

write binding tests and cleanup #808

Merged
merged 1 commit into from
May 17, 2016
Merged

write binding tests and cleanup #808

merged 1 commit into from
May 17, 2016

Conversation

reconbot
Copy link
Member

@reconbot reconbot commented May 15, 2016

  • Fix bug where write callback was being called multiple times when write operations blocked
  • [windows] refactored write code to be less complex
  • added arduino required integration tests

@@ -364,7 +364,7 @@ The `buffer` parameter accepts a [`Buffer` ](http://nodejs.org/api/buffer.html)

**_callback (optional)_**

Called once the write operation returns. The callback should be a function that looks like: `function (error, bytesWritten) { ... }`
Called once the write operation returns. The callback should be a function that looks like: `function (error) { ... }`
Copy link
Member Author

@reconbot reconbot May 15, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've removed the bytes written argument from the callback as it was usually a lie because the callback was called over and over and reported on each write. It should always match the length of the bytes you gave it to write. It's possible to put this back but not easy and not useful?

@reconbot
Copy link
Member Author

You can test this branch by changing your package.json to include {"serialport": "voodootikigod/node-serialport#write-bindings"} or installing it from the command line by typing npm install voodootikigod/node-serialport#write-bindings

@reconbot reconbot force-pushed the write-bindings branch 2 times, most recently from 4d38b39 to a8451c3 Compare May 16, 2016 16:44
 - Fix bug where write callback was being called multiple times when write operations blocked
 - [windows] refactored write code to be less complex
 - [unix] refactored write code to be less complex
 - added arduino required integration tests
@reconbot reconbot changed the title @wip write binding tests and cleanup write binding tests and cleanup May 17, 2016
@reconbot reconbot merged commit 4b984e8 into master May 17, 2016
@reconbot reconbot deleted the write-bindings branch May 17, 2016 01:33
@reconbot reconbot added this to the 4.0 milestone May 23, 2016
reconbot added a commit that referenced this pull request Jul 24, 2018
- Fix bug where write callback was being called multiple times when write operations blocked
 - [windows] refactored write code to be less complex
 - [unix] refactored write code to be less complex
 - added arduino required integration tests
@lock lock bot locked as resolved and limited conversation to collaborators Jan 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant