garrows/browser-serialport

Failure to connect to port

ClausM opened this issue · 1 comments

When I start my chrome app

  1. sometimes I get a failure to connect error
  2. and sometimes I get a malformed header error
    connection failure

Are there ways to intercept these errors? Or if I am not asking the question correctly, please tell me what information to provide?

Is this a general question about Chrome Serial API? You need to do what the error says, you haven't checked the chrome.runtime.lastError for your error and handled appropriately. See for an example https://github.com/garrows/browser-serialport/blob/master/index.js#L192-L200