Skip to content

Commit 4a403f6

Browse files
committed
Adjustment hwCPUFrequency() type
1 parent 4e968c7 commit 4a403f6

File tree

4 files changed

+3
-14
lines changed

4 files changed

+3
-14
lines changed

libraries/MySensors/core/MyHw.h

+1-2
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,7 @@ uint8_t hwReadConfig(int adr);
4545
int8_t hwSleep(unsigned long ms);
4646
int8_t hwSleep(uint8_t interrupt, uint8_t mode, unsigned long ms);
4747
int8_t hwSleep(uint8_t interrupt1, uint8_t mode1, uint8_t interrupt2, uint8_t mode2, unsigned long ms);
48-
uint16_t hwCPUVoltage();
49-
uint16_t hwCPUFrequency();
48+
5049
#ifdef MY_DEBUG
5150
void hwDebugPrint(const char *fmt, ... );
5251
#endif

libraries/MySensors/core/MyHwATMega328.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ uint16_t hwCPUVoltage() {
152152
return (1125300UL) / ADC;
153153
}
154154

155-
uint16_t hwCPUFrequency() {
155+
uint8_t hwCPUFrequency() {
156156
noInterrupts();
157157
// setup timer1
158158
TIFR1 = 0xFF;

libraries/MySensors/core/MyHwESP8266.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ uint16_t hwCPUVoltage() {
113113
return ESP.getVcc();
114114
}
115115

116-
uint16_t hwCPUFrequency() {
116+
uint8_t hwCPUFrequency() {
117117
return ESP.getCpuFreqMHz();
118118
}
119119

libraries/MySensors/core/MyHwSAMD.cpp

-10
Original file line numberDiff line numberDiff line change
@@ -135,16 +135,6 @@ int8_t hwSleep(uint8_t interrupt1, uint8_t mode1, uint8_t interrupt2, uint8_t mo
135135
return -2;
136136
}
137137

138-
uint16_t hwCPUVoltage() {
139-
// TODO: not supported
140-
return 0;
141-
}
142-
143-
uint16_t hwCPUFrequency() {
144-
// TODO: not supported
145-
return 0;
146-
}
147-
148138
#ifdef MY_DEBUG
149139
void hwDebugPrint(const char *fmt, ... ) {
150140
char fmtBuffer[300];

0 commit comments

Comments
 (0)