dumped all my old arduino stuff in here.
This commit is contained in:
parent
8cc6f23f59
commit
8f8959b76f
76 changed files with 8127 additions and 2 deletions
21
_LT1025_temp_sensor/_LT1025_temp_sensor.ino
Normal file
21
_LT1025_temp_sensor/_LT1025_temp_sensor.ino
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
int sensorPin = A0;
|
||||
int ledPin = 13;
|
||||
int sensorValue = 0;
|
||||
float printValue = 0;
|
||||
|
||||
void setup() {
|
||||
Serial.begin(9600);
|
||||
pinMode(ledPin, OUTPUT);
|
||||
}
|
||||
|
||||
void loop() {
|
||||
sensorValue = analogRead(sensorPin);
|
||||
|
||||
printValue = (sensorValue * 0.48828125);
|
||||
|
||||
Serial.print(printValue);
|
||||
Serial.print("\n");
|
||||
digitalWrite(ledPin, HIGH);
|
||||
delay(1000);
|
||||
digitalWrite(ledPin, LOW);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue