kelly / node-i2c

Node.js native bindings for i2c-dev. Plays well with Raspberry Pi and Beaglebone.
Other
216 stars 91 forks source link

Fixed res type for read byte to handle 0xFF #48

Closed ianmetcalf closed 9 years ago

ianmetcalf commented 9 years ago

i2c_smbus_read_byte returns a signed 32 bit interger, not 8 bit.

Reading the byte 0xFF currently causes a Segmentation Fault, this fixes that.

kelly commented 9 years ago

good catch!