serialport v4.0.0 Release Notes

Release Date: 2019-08-05 // over 4 years ago
    • ๐Ÿ—„ Requiring serialport now returns the SerialPort constructor function instead of a factory object. SerialPort.SerialPort is now deprecated.
    • SerialPort constructor now throws on argument errors immediately.
    • .write(writeCallback) now only calls it's callback once after the entire write operation, it used to be called for each write cycle and return the bytes written. This reduces the number of callbacks by hundreds of thousands over a megabyte at low bandwidth.
    • Disconnections now always attempt to close the port, and you'll always get a close event after a disconnect event
    • All callbacks are called in the context of the port, this now equals the port.
    • โœ‚ Removed openImmediately from the constructor's api, the functionality is now named autoOpen on the options object.
    • โœ‚ Removed extraneous flow control settings from the flowControl option, use the specific options to set these flags now.
    • โœ‚ Removed undocumented callbacks from the options object disconnectedCallback and dataCallback
    • ๐Ÿ“‡ Renamed serialportlist to serialport-list
    • ๐Ÿ“‡ Renamed serialportterm to serialport-term
    • โž• Added a contributors guide
    • โž• Added our first Arduino required integration tests
    • [unix] .drain and .set now properly report errors
    • ๐Ÿ”’ [unix] Ports are now locked by default with the new lock options matches windows default behavior
    • โšก๏ธ [windows] .update() now supports windows for changing baud rates
    • ๐Ÿ [windows] Fixed a bug where we weren't properly opening ports (provides better support virtual com ports too) thanks to @RogerHardiman
    • ๐Ÿ”’ [windows] known issue lock: false doesn't work (no change in behavior)