-
Notifications
You must be signed in to change notification settings - Fork 50
Description
Hi,
I'm using xbee-api on my project, but I have a problem when the nodes (I'm using xbee-api for Arduino) send a information to controller (using node js). Sometimes (after a long time) I have a error:
Caught exception: RangeError: Trying to write outside buffer length - Line: undefined
RangeError: Trying to write outside buffer length
at RangeError ()
at checkInt (buffer.js:788:11)
at Buffer.writeUInt8 (buffer.js:794:5)
at XBeeAPI.parseRaw (/user/node_modules/xbee-api/lib/xbee-api.js:148:14)
at Object.parser (/user/node_modules/xbee-api/lib/xbee-api.js:119:10)
at Object.SerialPort.options.dataCallback (/user/node_modules/serialport/serialport.js:143:15)
at SerialPortFactory.SerialPort._emitData (/user/node_modules/serialport/serialport.js:312:20)
at afterRead (/user/node_modules/serialport/serialport.js:290:18)
at /user/node_modules/serialport/serialport.js:304:9
at Object.wrapper as oncomplete
I'm printing: console.log(S.b); console.log(S.offset); on file xbee-api.js, line 147, and after a long time values > 255 are received (495, 498, 499, 502, 495, 505, ...). Then I need to restart the application.
Thank's