File tree 1 file changed +9
-2
lines changed
1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change 5
5
6
6
#include " DallasTemperature.h"
7
7
8
- #if ARDUINO >= 100
8
+ // for Particle support
9
+ // yield() is not a standard function, but instead wraps Particle process
10
+ // https://community.particle.io/t/syscall-yield-operation/40708/2
11
+ #if defined(PLATFORM_ID) // Only defined if a Particle device
12
+ inline void yield () {
13
+ Particle.process ();
14
+ }
15
+ #elif ARDUINO >= 100
9
16
#include " Arduino.h"
10
17
#else
11
18
extern " C" {
@@ -139,7 +146,7 @@ uint8_t DallasTemperature::getDS18Count(void) {
139
146
140
147
// returns true if address is valid
141
148
bool DallasTemperature::validAddress (const uint8_t * deviceAddress) {
142
- return (_wire->crc8 (deviceAddress, 7 ) == deviceAddress[DSROM_CRC]);
149
+ return (_wire->crc8 (( uint8_t *) deviceAddress, 7 ) == deviceAddress[DSROM_CRC]);
143
150
}
144
151
145
152
// finds an address at a given index on the bus
You can’t perform that action at this time.
0 commit comments