Cov txheej txheem:

THERMISTOR NROG ARDUINO UNO R3: 5 Cov Kauj Ruam
THERMISTOR NROG ARDUINO UNO R3: 5 Cov Kauj Ruam

Video: THERMISTOR NROG ARDUINO UNO R3: 5 Cov Kauj Ruam

Video: THERMISTOR NROG ARDUINO UNO R3: 5 Cov Kauj Ruam
Video: Huab Vwj Ft. David Yang - Tsis Txaus [Official MV] 2024, Hlis ntuj nqeg
Anonim
THERMISTOR NROG ARDUINO UNO R3
THERMISTOR NROG ARDUINO UNO R3

Lub thermistor yog ib hom resistor uas nws qhov kev sib txawv txawv nrog qhov kub thiab txias.

Kauj Ruam 1: Cheeb Tsam

Cheebtsam
Cheebtsam

- Arduino Uno board * 1

- USB cable * 1

- Thermistor * 1

-Resistor (10k) * 1

- Daim phiaj * 1

- Jumper xov hlau

Kauj Ruam 2: Txoj Cai

Txoj Cai
Txoj Cai

Qhov tsis kam ntawm cov thermistor sib txawv nrog qhov kub ib puag ncig. Nws tuaj yeem txheeb xyuas qhov hloov pauv kub ib puag ncig hauv lub sijhawm. Xa cov ntaub ntawv ntsuas kub mus rau qhov sib piv I/O chaw nres nkoj ntawm SunFounder. Tom ntej no peb tsuas yog yuav tsum hloov pauv cov ntsuas hluav taws xob mus rau Celsius kub los ntawm cov phiaj xwm yooj yim thiab tso tawm nws ntawm qhov chaw nres nkoj

Kauj Ruam 3: Daim duab qhia chaw

Schematic Daim duab
Schematic Daim duab

Kauj ruam 4: Cov txheej txheem

Kauj ruam 1:

Tsim lub voj voog.

Kauj ruam 2:

Rub tawm cov cai los ntawm

Kauj ruam 3:

Tshaj tawm cov duab kos rau Arduino Uno board

Nyem rau Upload icon txhawm rau upload cov cai rau pawg tswj hwm.

Yog tias "Ua tiav uploading" tshwm rau hauv qab ntawm lub qhov rais, nws txhais tau hais tias daim duab tau ua tiav tiav.

Tam sim no, koj tuaj yeem pom qhov ntsuas kub tam sim no tso tawm ntawm lub ntsuas saib.

Kauj ruam 5: Code

Code
Code

/*************************************npe: thermistor*muaj nuj nqi: koj tuaj yeem pom qhov ntsuas kub tam sim no tso tawm ntawm tus saib xyuas. ************************************** // Email: [email protected] // Lub Vev Xaib: www.primerobotics.in #define analogPin A0 // tus thermistor txuas rau #define beta 3950 // beta ntawm thermistor #define tsis kam 10 // tus nqi ntawm qhov rub tawm qhov tsis muaj teeb meem teeb tsa () {Serial.begin (9600); } tsis muaj dab tsi voj () {// nyeem tus nqi ntsuas kub ntev a = analogRead (analogPin); // cov lej xam ntawm qhov kub ntab tempC = beta /(log((1025.0 * 10 / a - 10) / 10) + beta / 298.0) - 273.0; // ntab tempF = 1.8*tempC + 32.0; // hloov centigrade rau Fahrenheit Serial.print ("TempC:"); // print "TempC:" Serial.print (tempC); // print Celsius kub Serial.print ("C"); // luam tawm chav Serial.println (); //Serial.print("TempF: "); // Serial.print (tempF); // Serial.print ("F"); ncua (200); // tos 200 milliseconds}

Pom zoo: