i2c_pi_target.h 363 B

123456789101112131415
  1. #ifndef I2C_PI_TARGET_H
  2. #define I2C_PI_TARGET_H
  3. #include <stdbool.h>
  4. // I2C command codes
  5. #define CMD_GET_BATTERY_STATUS 0x01 // Request battery state
  6. #define CMD_GET_BATTERY_DATA 0x02 // Request battery data
  7. #define CMD_SET_BATTERY_LIMIT 0x03 // SET min/max voltage, cutoff current limits
  8. void pi_i2c_mcu();
  9. #endif