From the course: Learning Arduino: Interfacing with Analog Devices

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Interpreting the sensor values

Interpreting the sensor values - Arduino Tutorial

From the course: Learning Arduino: Interfacing with Analog Devices

Start my 1-month free trial

Interpreting the sensor values

- [Narrator] This is an optional example to further understand the concept using the previous equations to calculate the temperature. I'll be using these two equations in order to calculate the temperature produced by the temperature sensor. Let's say for example, that once I use the Arduino software, I read a value of 110. Remember, Arduino uses ADC to read values between zero and 1,023, representing zero to 5,000 millivolts. And we use this relationship in order to calculate the voltage output. So, the output voltage equals the value read from the analog pin, times 5,000 over 1,023, and this equals around 537 millivolts. Now we know the voltage output, then we use the second equation in order to know the temperature of the sensor. So, using the equation, the temperature is around 26.8 degrees Celsius. You can also use one equation when it's applicable. So, you can find the temperature the same exact way.

Contents