Allow choosing the RF Band on LR1121 modules (#3078)
[ExpressLRS.git] / src / lib / THERMAL / thermal.h
blob28f5efb69cab41ff3db57df2d58841306901dc2c
1 #pragma once
3 #include "targets.h"
5 typedef enum
7 THERMAL_STATUS_FAIL = 0,
8 THERMAL_STATUS_NORMAL = 1
9 } Thermal_Status_t;
11 class Thermal
13 private:
14 uint8_t temp_value;
16 public:
17 void init();
18 void handle();
19 uint8_t read_temp();
20 void update_threshold(int index);
21 uint8_t getTempValue() { return temp_value; }
24 #define THERMAL_FAN_DEFAULT_LOW_THRESHOLD 35
25 #define THERMAL_FAN_DEFAULT_HIGH_THRESHOLD 50
27 #define THERMAL_FAN_ALWAYS_ON_LOW_THRESHOLD 0xFF
28 #define THERMAL_FAN_ALWAYS_ON_HIGH_THRESHOLD 0xFD
30 #define THERMAL_FAN_OFF_LOW_THRESHOLD 0x7D
31 #define THERMAL_FAN_OFF_HIGH_THRESHOLD 0x7F