menu "ESPP I2C Component Configuration"

choice
    prompt "I2C API Selection"
    default ESPP_I2C_USE_NEW_API

config ESPP_I2C_USE_LEGACY_API
    bool "Use legacy I2C API (i2c.hpp)"
    help
      Use the deprecated ESP-IDF legacy I2C driver through i2c.hpp.
      This is only intended for older environments that still require the
      legacy driver.

config ESPP_I2C_USE_NEW_API
    bool "Use new I2C API (i2c.hpp, i2c_master.hpp, i2c_slave.hpp)"
    help
      Use the ESP-IDF master/slave bus APIs. In this mode, i2c.hpp keeps the
      familiar address-based espp::I2c helpers for compatibility while also
      exposing explicit device handles via add_device().

      This API is available on ESP-IDF >= 5.4.0 and is required for ESP-IDF
      6.0 and later.

endchoice

if ESPP_I2C_USE_LEGACY_API
config ESPP_I2C_LEGACY_API_DISABLE_DEPRECATION_WARNINGS
    bool "Disable deprecation warnings for legacy I2C API"
    default n
    help
      Disable deprecation warnings for the legacy I2C API (i2c.hpp).
      This is useful if you are using the legacy API and do not want to see warnings about its deprecation.
      Note that this may hide important warnings about future compatibility.

endif

endmenu
