44 #if defined(ARDUINO_ARCH_AVR) 47 analogReference(INTERNAL);
48 #elif defined(INTERNAL1V1) 49 analogReference(INTERNAL1V1);
51 #error "analogReference() not supported for this MCU" 56 (void)analogRead(_pin);
77 uint16_t temperatureLast = 0;
78 uint16_t temperature = 0;
87 temperature = ((uint32_t)analogRead(_pin) * 1000) / 931;
89 if (temperatureLast == temperature) {
95 temperatureLast = temperature;
99 return temperatureLast;
#define LM35_MAX_SAMPLES
Check tested platform.
uint16_t readTemperature()
Read unsigned analog temperature.
LM35(uint8_t pin)
LM35 constructor.
Analog LM35 temperature sensor library for Arduino.