# List the source files to be compiled
set(srcs
    "driver/meter_ade7758/meter_ade7758.c"
    "driver/meter_ade7758/ade7758.c"
    "driver/meter_orno/meter_orno513.c"
    "driver/meter_orno/meter_orno516.c"
    "driver/meter_orno/modbus_params.c"
    "driver/meter_zigbee/meter_zigbee.c"
    "src/meter_manager.c"
    "src/meter_events.c"
)

# List the include directories
set(includes
    "include"
    "driver/meter_ade7758"
    "driver/meter_orno"
    "driver/meter_zigbee"
)

# Register the component with the ESP-IDF build system
idf_component_register(SRCS "${srcs}"
                      INCLUDE_DIRS "${includes}"
                      PRIV_REQUIRES nvs_flash
                      REQUIRES esp_event esp-modbus spi_bus_manager network)
