Repository: incubator-mynewt-core Updated Branches: refs/heads/develop b7c8714b8 -> 8d757705f
BNO055 driver - fix multiple length read issue Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/commit/8d757705 Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/tree/8d757705 Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/diff/8d757705 Branch: refs/heads/develop Commit: 8d757705fe2627b766da621cce2d01d4e5bad687 Parents: b7c8714 Author: Vipul Rahane <[email protected]> Authored: Thu Mar 2 18:56:30 2017 -0800 Committer: Vipul Rahane <[email protected]> Committed: Thu Mar 2 18:57:17 2017 -0800 ---------------------------------------------------------------------- hw/drivers/sensors/bno055/src/bno055.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/8d757705/hw/drivers/sensors/bno055/src/bno055.c ---------------------------------------------------------------------- diff --git a/hw/drivers/sensors/bno055/src/bno055.c b/hw/drivers/sensors/bno055/src/bno055.c index 4b9f32c..6773650 100644 --- a/hw/drivers/sensors/bno055/src/bno055.c +++ b/hw/drivers/sensors/bno055/src/bno055.c @@ -240,7 +240,7 @@ bno055_readlen(uint8_t reg, uint8_t *buffer, uint8_t len) }; /* Clear the supplied buffer */ - memset(buffer, 0, 22); + memset(buffer, 0, len); /* Register write */ rc = hal_i2c_master_write(MYNEWT_VAL(BNO055_I2CBUS), &data_struct,
