-
Notifications
You must be signed in to change notification settings - Fork 0
/
temperature.h
43 lines (32 loc) · 916 Bytes
/
temperature.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#ifndef TEMPERATURE_H
#define TEMPERATURE_H
#include "Arduino.h"
#include <Wire.h>
class Temperature{
private:
int thermoPin;
byte thermoAddr[8];
boolean thermoAddrSet;
int sumpThermoPin;
byte sumpThermoAddr[8];
boolean sumpThermoAddrSet;
int heaterPin;
int fanPin;
float minTemp;
float maxTemp;
boolean boundSet;
float fanTemp;
float heatTemp;
float getOWTemp(int pin, byte* address = NULL);
public:
Temperature(int thermo_pin);
void setThermoPin(int pin, byte* addr = NULL);
void setSumpThermoPin(int pin, byte* addr = NULL);
void setAlarmBound(float minTemperature, float maxTemperature);
void setFanPin(int pin, float startTemperature = 28.0);
void setHeaterPin(int pin, float startTemperature = 25.0);
float getTemperature();
float getSumpTemperature();
void run();
};
#endif