letscontrolit / ESPEasy

Easy MultiSensor device based on ESP8266/ESP32
http://www.espeasy.com
Other
3.28k stars 2.22k forks source link

Allow multiple instances of I2C plugins to support multiplexer #3224

Closed TD-er closed 4 years ago

TD-er commented 4 years ago

To support the I2C multiplexer, it is even more important to allow multiple instances of a plugin. So every I2C plugin should be adapted to use a data struct like this: struct P028_data_struct : public PluginTaskData_base

See P028_BME280 as an example.

Todo:

tonhuisman commented 4 years ago

You can remove P095 from the list, as that's actually a SPI-connected device. And P037 should be P036.

TD-er commented 4 years ago

Added a test build, containing all the changes mentioned in this issue. See: https://github.com/letscontrolit/ESPEasy/pull/3226#issuecomment-684707482

TD-er commented 4 years ago

As it appeared the latest test builds may not have been using the actual changes, I made a new test build for this PR: