#include <util/delay.h>
#include <avr/interrupt.h>
#include <util/atomic.h>
#include "onewire.h"
#include "ds18x20.h"
return 1;
} else {
if (parasitic_power) {
uint8_t sreg_tmp=SREG; cli();
ONEWIRE_STRONG_PU_ON
SREG = sreg_tmp;
} else {
}
}
return 0;
}
uint8_t lsb, msb;
int16_t temp;
temp = ((int16_t)msb << 8) | lsb;
return temp;
}
int16_t temp;
temp = (temp*640L) >> 10;
return temp;
}
int16_t temp;
temp = temp*5;
return temp;
}
uint8_t i;
for (i=0; i<9; i++) {
}
}
}
}
if (parasitic_power) {
uint8_t sreg_tmp=SREG; cli();
ONEWIRE_STRONG_PU_ON
SREG = sreg_tmp;
} else {
}
_delay_ms(10);
ONEWIRE_STRONG_PU_OFF
}
_delay_ms(1);
}
}