From e2192d5b4dea9b14697084e3027fbd812d5d1612 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Thu, 1 Dec 2016 20:58:40 +1100 Subject: [PATCH] HAL_PX4: report user bus number not system bus number --- libraries/AP_HAL_PX4/I2CDevice.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/AP_HAL_PX4/I2CDevice.cpp b/libraries/AP_HAL_PX4/I2CDevice.cpp index 1c24eecd21..606af46311 100644 --- a/libraries/AP_HAL_PX4/I2CDevice.cpp +++ b/libraries/AP_HAL_PX4/I2CDevice.cpp @@ -101,7 +101,7 @@ I2CDevice::I2CDevice(uint8_t bus, uint8_t address) : _px4dev(_busnum), _address(address) { - set_device_bus(_px4dev.map_bus_number(bus)); + set_device_bus(bus); set_device_address(address); asprintf(&pname, "I2C:%u:%02x", (unsigned)bus, (unsigned)address);