Browse Source

HAL_PX4: fixed bug in instantiation of I2C bus threads

we ended up with a thread per device instead of a thread per bus!
mission-4.1.18
Andrew Tridgell 8 years ago
parent
commit
f04b186879
  1. 2
      libraries/AP_HAL_PX4/I2CDevice.cpp
  2. 2
      libraries/AP_HAL_PX4/I2CDevice.h

2
libraries/AP_HAL_PX4/I2CDevice.cpp

@ -23,6 +23,8 @@ namespace PX4 { @@ -23,6 +23,8 @@ namespace PX4 {
uint8_t PX4::PX4_I2C::instance;
DeviceBus I2CDevice::businfo[I2CDevice::num_buses];
/*
constructor for I2C wrapper class
*/

2
libraries/AP_HAL_PX4/I2CDevice.h

@ -67,7 +67,7 @@ public: @@ -67,7 +67,7 @@ public:
private:
static const uint8_t num_buses = 2;
DeviceBus businfo[num_buses];
static DeviceBus businfo[num_buses];
uint8_t _busnum;
PX4_I2C _px4dev;

Loading…
Cancel
Save