config.h 567 B

1234567891011121314151617181920212223242526272829
  1. #include <stdint.h>
  2. #ifndef CONFIG_H_
  3. #define CONFIG_H_
  4. #define I2C_TX_MAX_PACKET_SIZE (8)
  5. #define I2C_RX_MAX_PACKET_SIZE (8)
  6. #define NUM_SLOTS (4)
  7. #define BATTERY_THRESHOLD (50)
  8. #define TEMPERATURE_MAX_C (60)
  9. #define MAX_CYCLES (2)
  10. #define TARGET_MCU_ADDRESS (0x48)
  11. typedef struct{
  12. uint8_t txBuffer[I2C_TX_MAX_PACKET_SIZE];
  13. uint8_t txLen;
  14. uint8_t txCount;
  15. }txPacket;
  16. typedef struct{
  17. uint8_t rxBuffer[I2C_RX_MAX_PACKET_SIZE];
  18. uint8_t rxLen;
  19. uint8_t rxCount;
  20. }rxPacket;
  21. extern txPacket tx_packet;
  22. extern rxPacket rx_packet;
  23. #endif