#pragma once

#include <stdbool.h>
#include <stddef.h>

#include "esp_err.h"

typedef struct {
    float voltage_v;
    float current_ma;
    float power_mw;
} ina226_reading_t;

esp_err_t ina226_monitor_init(void);
bool ina226_monitor_ready(void);
size_t ina226_monitor_channel_count(void);
esp_err_t ina226_monitor_sample(ina226_reading_t *out_reading);
const ina226_reading_t *ina226_monitor_get_last(void);
