Last active
October 7, 2021 21:08
-
-
Save samuelsonbrito/b021f1d9ae89aa17de391cc67ecfb999 to your computer and use it in GitHub Desktop.
Lm35 - Arduino
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const int LM35 = A0; | |
double temperatura; | |
void setup() { | |
// put your setup code here, to run once: | |
Serial.begin(9600); | |
} | |
void loop() { | |
// put your main code here, to run repeatedly: | |
temperatura = (double(analogRead(LM35))*5/(1023))/0.01; | |
Serial.println(temperatura); | |
delay(2000); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment