Skip to content

v1.0.7

Choose a tag to compare

@onexs-xsi onexs-xsi released this 28 Feb 03:20
· 6 commits to main since this release
  1. Add M5Unified I2C_Class driver support for both Arduino and ESP-IDF platforms — New begin(m5::I2C_Class*, ...) overloads (with and without hardware interrupt) allow initializing M5IOE1 using an M5Unified I2C_Class instance; the caller retains I2C bus ownership and lifecycle.

  2. Add compile-time feature detection for I2C backends — Introduce M5IOE1_HAS_I2C_MASTER, M5IOE1_HAS_I2C_BUS, and M5IOE1_HAS_M5UNIFIED_I2C macros to auto-detect available I2C drivers based on IDF version, header availability, and CONFIG_I2C_BUS_BACKWARD_CONFIG.

  3. Add M5GFX/M5Unified coexistence conflict detection — Emit compile-time errors or silently disable i2c_bus mode when M5GFX/M5Unified is present, preventing runtime abort() from i2c_driver_install() vs i2c_new_master_bus() conflicts.

  4. Improve the log system with per-module tags and additional log levels — Split monolithic M5IOE1 tag into M5IOE1_I2C, M5IOE1_GPIO, M5IOE1_ADC, M5IOE1_PWM, M5IOE1_LED, M5IOE1_AMP, M5IOE1_IRQ, M5IOE1_SYS; add LOG_D (debug) and LOG_V (verbose) levels; prefix Arduino log output with severity indicators [I]/[W]/[E]/[D]/[V]; force LOG_LOCAL_LEVEL = ESP_LOG_VERBOSE for ESP-IDF builds.

  5. Optimize I2C retry with configurable delay — Add M5IOE1_I2C_RETRY_DELAY_MS (default 50ms) alongside existing M5IOE1_I2C_RETRY_COUNT, replacing hard-coded minimal delays.

  6. Rename I2C helper functions with platform prefix — Rename M5IOE1_I2C_READ_BYTE → M5IOE1_I2C_ARDUINO_READ_BYTE (and all similar helpers); add new M5IOE1_M5UNIFIED_* wrapper set for I2C_Class communication.

  7. Add snapshot domain bitmask enum — New m5ioe1_snapshot_domain_t enum with GPIO, PWM, ADC, AW8737A, and ALL domains for selective snapshot verification.

  8. Optimize i2c-related internal functions — Refactor I2C initialization, read/write paths, and conditional compilation guards for i2c_master and i2c_bus backends; move Arduino polling/interrupt task handles from static globals to instance members for multi-instance support.

  9. Add M5Unified as optional CMake dependency — Use idf_component_optional_requires(PRIVATE M5Unified) so M5IOE1 auto-links M5Unified when present without hard dependency.

  10. Add include-order guidance and i2c_bus restriction notes in README — Document that M5Unified.h must be included before M5IOE1.h on ESP-IDF ≥ 5.3.0 to avoid i2c_config_t conflicts; note that i2c_bus mode is unsupported when M5GFX/M5Unified is present; recommend begin(&M5.In_I2C, addr, freq) instead.

  11. Update clang-format configuration and CI action — Revise .clang-format rules and update clang-format-check.yml workflow.

  12. Bump library version from 1.0.6 to 1.0.7 — Update version in idf_component.yml, library.json, and library.properties.