mirror of
https://github.com/Threnklyn/esphome-dev.git
synced 2026-05-19 12:43:28 +02:00
356efdb92c6f61de86f4bbb8204cfae8b51fbab7
* Add initial support for multiple devices Re-introduce support for multiple I2C devices (it was suppressed in https://github.com/trvrnrth/esphome-bsec-bme680/commit/df37a7635f6acc3f7520f257d2645eda10b863a5). Devices are identified by their I2C address, and the BME680 can only have the 0x76 or 0x77 address, so this adds support for a maximum of two devices. * Reintegrate commitebf13a0bReintegrate commit https://github.com/esphome/esphome/commit/ebf13a0ba0a48453c2cc80bfc942d6a588859233 which was lost in my changes (I were working on old files) * wrong commit * wrong commit * Reintegrate commitebf13a0bReintegrate commit https://github.com/esphome/esphome/commit/ebf13a0ba0a48453c2cc80bfc942d6a588859233 which was lost due to me working on old files * Reintroduce newlines at end of files * Reintroduce newlines at end of files * Adhere to codebase standards Obey the "All uses of class members and member functions should be prefixed with this-> to distinguish them from global functions in code review" rule of the Codebase Standards * Fix formatting according to clang-format * Perform the BSEC library reinitialization+snapshot only when more than one device is present * Fix formatting according to clang-format * Degrade abort message in restore_state_() from warning to verbose This always happen at initial setup, so it's not a really useful message; when some real problems arise, we'll have a more useful warning from snapshot_state_() Co-authored-by: Trevor North <trevor@freedisc.co.uk> * Reduce peak stack usage to avoid bootloops on ESP8266 Achieved mainly by moving the work_buffer needed by the BSEC library to the heap, as a single global work buffer shared by all instances. ::set_config_ has been reverted to a code path similar to the original, as that reduces peak stack usage enough to be OK on ESP8266 even without moving the work_buffer to the heap. * Fix formatting according to clang-format * Add support for devices with the same i2c address Devices are now identified using their index in the BME680BSECComponent::instances member, which became a vector. This allows adding two devices with the same i2c address (which should be placed on different i2c buses). Since a BME680 can only have an address of 0x76 or 0x77, a maximum of 2 devices could be added before this commit. Now there is no theoretical limit on the number of devices which could be added. * Fix formatting according to clang-format * Fix formatting according to clang-format --------- Co-authored-by: Trevor North <trevor@freedisc.co.uk> Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com>
ESPHome

Documentation: https://esphome.io/
For issues, please go to the issue tracker.
For feature requests, please see feature requests.
Description
ESPHome is a system to control your ESP8266/ESP32 by simple yet powerful configuration files and control them remotely through Home Automation systems.
Languages
C++
69%
Python
30.7%
C
0.2%
