@@ -18,8 +18,9 @@ uint8_t* boardInfo();
18
18
TCTempProbeClass::TCTempProbeClass (PinName tc_cs_pin,
19
19
PinName ch_sel0_pin,
20
20
PinName ch_sel1_pin,
21
- PinName ch_sel2_pin)
22
- : MAX31855Class(tc_cs_pin), _tc_cs{tc_cs_pin}, _ch_sel0{ch_sel0_pin}, _ch_sel1{ch_sel1_pin}, _ch_sel2{ch_sel2_pin}
21
+ PinName ch_sel2_pin,
22
+ PinName tc_th_pin)
23
+ : MAX31855Class(tc_cs_pin), _tc_cs{tc_cs_pin}, _ch_sel0{ch_sel0_pin}, _ch_sel1{ch_sel1_pin}, _ch_sel2{ch_sel2_pin}, _tc_th{tc_th_pin}
23
24
{ }
24
25
25
26
TCTempProbeClass::~TCTempProbeClass ()
@@ -31,6 +32,7 @@ bool TCTempProbeClass::begin() {
31
32
pinMode (_ch_sel0, OUTPUT);
32
33
pinMode (_ch_sel1, OUTPUT);
33
34
pinMode (_ch_sel2, OUTPUT);
35
+ pinMode (_tc_th, OUTPUT);
34
36
35
37
pinMode (_tc_cs, OUTPUT);
36
38
@@ -92,10 +94,12 @@ void TCTempProbeClass::end() {
92
94
93
95
void TCTempProbeClass::_enable () {
94
96
digitalWrite (_tc_cs, LOW);
97
+ digitalWrite (_tc_th, LOW);
95
98
}
96
99
97
100
void TCTempProbeClass::_disable () {
98
101
digitalWrite (_tc_cs, HIGH);
102
+ digitalWrite (_tc_th, HIGH);
99
103
}
100
104
101
105
TCTempProbeClass MachineControl_TCTempProbe;
0 commit comments