Uploaded by YOUNUS DEWAN

IoT Project

advertisement
UNIVERSITY OF MANITOBA
DEPARTMENT OF ELECTRICAL AND C OMPUTER ENGINEERING
GRAD PROJECT
A SMART IOT TEMPERATURE MONITORING SYSTEM
USING HUZZAH ESP8266
Report Prepared by
YOUNUS DEWAN
Date of Submission
2nd May 2022
Abstract
The goal of the project was to design, analyze, and develop a Smart IoT Temperature Monitoring
System (SITMoS). The SITMoS will collect and share data between two devices using the Internet
to automatically adjust a HVAC system. The SITMoS is built using Adafruit Feather HUZZAH
ESP8266 and the LM61B2M3 Si Bandgap temperature sensor on the hardware side and Arduino
IDE (Integrated Development Environment) running in the backend. SITMoS is a real time system
which transmits data to open IoT API service Adafruit IO where it is analyzed and stored. This
paper will start by introducing the SITMoS and how it can be useful in moveable shelving storage
systems. Then it will give a brief idea of the components used along with their technical
specifications. Details on the data packet sent and the method to fetch data from the asset to the
cloud are provided. Then the paper will show a mock-up of the dashboard that would be used to
present and analyzed the data. It will be followed by a flowchart which will give a clear idea of
how the system will work. The experimental results show that the SITMoS meets the requirements
of practice and will be deployed in an outdoor carousel.
Acknowledgement
I would also like to express my gratitude towards my supervisor and the course instructor, Dr.
Douglas Thomson, for giving me this great opportunity to do a project on a smart IoT temperature
monitoring system. Without his support and suggestions, this project would not have been
completed.
1|Page
Table of Contents
ABSTRACT ....................................................................................................................................... 1
ACKNOWLEDGEMENT ...................................................................................................................... 1
TABLE OF CONTENTS ....................................................................................................................... 2
INTRODUCTION ................................................................................................................................ 3
1.1 BACKGROUND ........................................................................................................................ 3
1.2 PROBLEM STATEMENT ............................................................................................................ 3
1.3 PROPOSED SOLUTION ............................................................................................................. 3
PROJECT OVERVIEW ......................................................................................................................... 4
2.1 APPLICATION OVERVIEW ........................................................................................................ 4
2.2 SITMOS CIRCUIT ................................................................................................................... 5
2.3 FINAL BUDGET ....................................................................................................................... 5
TECHNICAL SECTION........................................................................................................................ 6
3.1 QUANTITY UNDER MEASUREMENT (QUM) – TEMPERATURE ................................................. 6
3.2 HARDWARE DESCRIPTION ...................................................................................................... 7
3.2.1 TEMPERATURE SENSOR – LM61B2M3 SI BANDGAP....................................................... 7
3.2.2 WIFI DEVELOPMENT BOARD – ADAFRUIT FEATHER HUZZAH ESP8266 ...................... 7
3.2.3 BATTERY – LITHIUM ION POLYMER BATTERY (3.7V 500MAH)........................................ 8
3.2.4 BATTERY CHARGER – SOLAR LIPO BATTERY CHARGER (3.7V 500MA) .......................... 9
3.2.5 SOLAR PANEL – WAVESHARE SOLAR PANEL (6V 5W) .................................................... 9
3.3 POWER LIMITATION AND REQUIREMENT ............................................................................... 10
3.4 COMPUTATIONS .....................................................................................................................11
EDGE COMPUTATION ...............................................................................................................11
CLOUD COMPUTATION ............................................................................................................11
3.5 THE DATA PACKET................................................................................................................ 12
3.6 DATA TRANSMISSION ............................................................................................................ 12
3.7 THE DASHBOARD ................................................................................................................. 15
3.7 STATISTICAL ANALYSIS ......................................................................................................... 15
3.7.1 DATA RECEIVED BY ADAFRUIT IO UNTIL EQUILIBRIUM REACHED ................................ 16
3.7.2 DATA RECEIVED BY ADAFRUIT IO AFTER EQUILIBRIUM REACHED ............................... 17
3.7.3 THE MEAN MEASURED VALUE OF THE DATA POINTS – ACCURACY ANALYSIS ............. 18
3.7.4 THE STANDARD DEVIATION OF THE DATA POINTS – PRECISION ANALYSIS .................... 18
RECOMMENDED AND FUTURE WORK ............................................................................................. 20
CONCLUSIONS ................................................................................................................................ 20
REFERENCES .................................................................................................................................. 21
2|Page
Introduction
1.1 Background
Internet of Things (IoT) allow us to monitor and control our environment through the use of
devices such as sensors and actuators. IoT facilitates sensing, processing, and wireless
transmission of data to remote storage like cloud which stores, analyzes, and processes this data in
useful form. From the cloud this information can then be accessed through various front end user
interfaces for various applications. Temperature monitoring is an important IoT application which
involves monitoring the surrounding temperature and reporting this data for remotely controlling
the heating or cooling devices.
1.2 Problem Statement
Vidir Solutions Inc. is developing an outdoor carousel to be used for storage, farming, etc. They
want to develop a system that can use to monitor what is happening inside the enclosed carousel
in order to automatically adjust the HVAC system. The client would like something that can be
installed onto the rotating shelves and monitor what is happening inside the enclosed carousel.
1.3 Proposed Solution
This paper presents the implementation details and results of a temperature monitoring system –
SITMoS. The SITMoS uses a temperature sensor to monitor the temperature at each shelf location
inside the Carousel and then transmits the data collected through Internet to a remote cloud storage.
The data is then accessed from the cloud by a controller. The controller analyzes the data and
triggers the HVAC system accordingly to maintain a suitable environment inside the enclosed
Carousel.
3|Page
Project Overview
2.1 Application Overview
Each carousel is equipped with 12 rotating shelves. Each shelf will be used for storing different
types of good. As different goods will require different weather conditions for proper storage, it is
essential to monitor the temperature of each individual shelf and adjust the HVAC system. The
rotational motion of the shelves makes it difficult to install wired sensors on the shelves and as a
result an IoT integrated solution using Wi-Fi is chosen for this application.
Figure 1: 3D Drawing of the Carousel
4|Page
2.2 SITMoS Circuit
Figure 2: SITMoS Circuit Diagram
2.3 Final Budget
Table 1: Budget Table
Single SITMoS
Adafruit Feather HUZZAH ESP8266
LM61B2M3 Temperature Sensor
Lithium Ion Polymer Battery – 3.7v 500mAh
3.7V 500mA Solar LiPo Battery Charger
Waveshare Solar Panel (6V 5W)
Cloud Service
Total
Cost
$ 18.95
$ 2.23
$ 7.95
$ 6.28
$ 14.09
$0
$ 49.50
5|Page
Technical Section
3.1 Quantity Under Measurement (QUM) – Temperature
Temperature will be measured using the LM61B2M3 Si Bandgap temperature sensor.
𝐿𝑀61 πΏπ‘–π‘›π‘’π‘Žπ‘Ÿ π‘†π‘π‘Žπ‘™π‘’ πΉπ‘Žπ‘π‘‘π‘œπ‘Ÿ = 10π‘šπ‘‰/°πΆ
𝐴𝑑 0°πΆ → π‘‰π‘œπ‘’π‘‘ = 600π‘šπ‘‰
𝐴𝑑 − 30°πΆ → π‘‰π‘œπ‘’π‘‘ = 600π‘šπ‘‰ + (−30 × 10) = 300π‘šπ‘‰
𝐴𝑑 100°πΆ → π‘‰π‘œπ‘’π‘‘ = 600π‘šπ‘‰ + (100 × 10) = 1600π‘šπ‘‰
LM61B2M3 Temperature Range
LM61B2M3 Voltage Range
Feather HUZZAH ESP8266 ADC Input Range
Feather HUZZAH ESP8266 ADC Output Range
π‘ˆπ‘π‘π‘’π‘Ÿ π΅π‘œπ‘’π‘›π‘‘ π‘œπ‘“ π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’ =
Lower Bound
-30°C
300mV
0mV
0
Upper Bound
100°C
1600mV
1000mV
1023
1000π‘šπ‘‰ − 600π‘šπ‘‰
= 40°πΆ
10π‘šπ‘‰/°πΆ
πΏπ‘œπ‘€π‘’π‘Ÿ π΅π‘œπ‘’π‘›π‘‘ π‘œπ‘“ π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’ = −30°πΆ
π‘…π‘’π‘ π‘œπ‘™π‘’π‘‘π‘–π‘œπ‘› =
40°πΆ − (−30°πΆ)
= 0.068°πΆ/𝑏𝑖𝑑
1024 − 1
6|Page
3.2 Hardware Description
3.2.1 Temperature Sensor – LM61B2M3 Si Bandgap
Figure 3: LM61B2M3 Si Bandgap Sensor
The LM61B2M3 Si Bandgap Temperature sensor is selected for environmental monitoring as it
has high reliability and excellent long-term stability. It has small dimensions, low cost, good
quality, analog signal output, and precise calibration. It can be easily interfaced with Feather
HUZZAH ESP8266 Wi-Fi board using the pins shown in figure 2. Figure 3 shows a picture of the
LM61 sensor used in the SITMoS. It has temperature range from -30°C to 100°C. The project
required temperature reading between -20°C and 30°C. This sensor is chosen because it has
calibrated linear scale factor of 10mV/°C for full temperature range of -30°C to 100°C.
3.2.2 WiFi Development Board – Adafruit Feather HUZZAH ESP8266
Figure 4: Adafruit Feather HUZZAH ESP8266 Wi-Fi Development Board
The central component of the SITMoS is the Feather HUZZAH development board which
interfaces with other components of the system. The Feather HUZZAH development board consist
7|Page
of an ESP8266 WiFi microcontroller clocked at 80 MHz and at 3.3V logic. The development board
also comes with a built in ADC. The controller interfaces with the sensor chip at the ADC input
for receiving temperature readings and sends the received data to the cloud over the Internet. The
microcontroller polls the sensor to retrieve data and sends it over the Internet to Adafruit IO. This
built in ADC has a 10-bit resolution (0.068°C/bit) and the board can be powered with a battery.
This microcontroller serves the purpose well due to its low cost, simplicity, and robustness. Figure
4 shows a picture of the Adafruit Feather HUZZAH Development board used in the SITMoS
system. The microcontroller is programmable with the Arduino IDE for an easy-to-run Internet of
Things core via a type B USB cable. The project required reading of analog signal at a resolution
of 1°C and this development board meets the requirement. Additionally, these microcontrollers
contain a Tensilica chip core as well as a full WiFi stack and a USB-Serial chip that can upload
code at a blistering 921600 baud for fast development time. [1]
3.2.3 Battery – Lithium Ion Polymer Battery (3.7V 500mAh)
Figure 5: Lithium Ion Polymer Battery - 3.7v 500mAh
The project required a system with power storage capability. Presence of artificial light inside the
enclosure will allow recharging of the battery at regular intervals. The total power consumption of
the system is less than 100mA (see section 3.3), therefore this battery is capable of powering the
system for 5 hours each time its fully charged.
8|Page
3.2.4 Battery Charger – Solar LiPo Battery Charger (3.7V 500mA)
Figure 6: 3.7V 500mA Solar LiPo Battery Charger
The power from the solar panel cannot be directly used to recharge the battery and so this battery
charger is used to allow intelligent charging with reverse polarity protection. With operating
temperature between -40°C to 85°C and having a small size (33mm x 33mm x 12mm) it is a good
fit for the solar powered charging sub-system.
3.2.5 Solar Panel – Waveshare Solar Panel (6V 5W)
Figure 7: Waveshare Solar Panel (6V 5W)
The project required that the SITMoS be installed on rotating shelves. As the shelves are rotating,
any electronics installed on it required power storage capability – i.e. A battery. To avoid replacing
batteries, a renewable energy source (light) is exploited and thus a solar panel is used in the system.
This specific solar panel is selected as it meets all the operating conditions (i.e. power, voltage,
current, etc.) to work with the charger and the battery chosen for this project.
9|Page
3.3 Power Limitation and Requirement
Solar Panel
π‘ƒπ‘œπ‘€π‘’π‘Ÿ → 5.0π‘Š ± 5%
π‘‚π‘π‘’π‘Ÿπ‘Žπ‘‘π‘–π‘›π‘” π‘£π‘œπ‘™π‘‘π‘Žπ‘”π‘’ → 6.0 𝑉 ± 5%
π‘‚π‘π‘’π‘Ÿπ‘Žπ‘‘π‘–π‘›π‘” π‘π‘’π‘Ÿπ‘Ÿπ‘’π‘›π‘‘ → 833 π‘šπ΄ ± 5% (π‘šπ‘Žπ‘₯)
𝑂𝑝𝑒𝑛 π‘π‘–π‘Ÿπ‘π‘’π‘–π‘‘ π‘£π‘œπ‘™π‘‘π‘Žπ‘”π‘’ → 7.2 𝑉 ± 5%
π‘†β„Žπ‘œπ‘Ÿπ‘‘ π‘π‘–π‘Ÿπ‘π‘’π‘–π‘‘ π‘π‘’π‘Ÿπ‘Ÿπ‘’π‘›π‘‘ → 916 π‘šπ΄ ± 5%
Battery Charger
𝐼𝑛𝑝𝑒𝑑 π‘£π‘œπ‘™π‘‘π‘Žπ‘”π‘’ → 4.4~6𝑉
πΆβ„Žπ‘Žπ‘Ÿπ‘”π‘–π‘›π‘” π‘π‘’π‘Ÿπ‘Ÿπ‘’π‘›π‘‘ → 500π‘šπ΄ (π‘šπ‘Žπ‘₯π‘–π‘šπ‘’π‘š)
πΆβ„Žπ‘Žπ‘Ÿπ‘”π‘–π‘›π‘” π‘π‘’π‘‘π‘œπ‘“π‘“ π‘£π‘œπ‘™π‘‘π‘Žπ‘”π‘’ → 4.2𝑉
Battery
π‘‰π‘œπ‘™π‘‘π‘Žπ‘”π‘’ → 3.7𝑉
π‘‡π‘œπ‘‘π‘Žπ‘™ π΄π‘šπ‘ π»π‘œπ‘’π‘Ÿ → 500π‘šπ΄β„Ž
π‘‡π‘œπ‘‘π‘Žπ‘™ π‘Šπ‘Žπ‘‘π‘‘ π»π‘œπ‘’π‘Ÿ → 1.9 π‘Šβ„Ž
System Requirement
𝐿𝑀61 πΆπ‘’π‘Ÿπ‘Ÿπ‘’π‘›π‘‘ π·π‘Ÿπ‘Žπ‘–π‘› π‘Žπ‘‘ 25°πΆ → 125πœ‡π΄
πΆπ‘’π‘Ÿπ‘Ÿπ‘’π‘›π‘‘ π·π‘Ÿπ‘Žπ‘–π‘› π‘œπ‘“ Feather HUZZAH ESP8266 → 80mA
π‘‡π‘œπ‘‘π‘Žπ‘™ π‘ƒπ‘œπ‘€π‘’π‘Ÿ πΆπ‘œπ‘›π‘ π‘’π‘šπ‘π‘‘π‘–π‘œπ‘› = 125πœ‡ + 80π‘š = 80.125π‘šπ΄
π‘‡π‘œπ‘‘π‘Žπ‘™ π‘‚π‘π‘’π‘Ÿπ‘Žπ‘‘π‘–π‘›π‘” π‘‡π‘–π‘šπ‘’ π‘€π‘–π‘‘β„Ž 𝐹𝑒𝑙𝑙𝑦 πΆβ„Žπ‘Žπ‘Ÿπ‘”π‘’π‘‘ π΅π‘Žπ‘‘π‘‘π‘’π‘Ÿπ‘¦ =
π‘‡π‘–π‘šπ‘’ π‘‘π‘œ π‘…π‘’π‘β„Žπ‘Žπ‘Ÿπ‘”π‘’ =
500π‘šπ΄β„Ž
= 6.24 π»π‘œπ‘’π‘Ÿπ‘ 
80.125π‘šπ΄
500π‘šπ΄β„Ž
= 0.6 π»π‘œπ‘’π‘Ÿπ‘ 
833 π‘šπ΄
It will have less than an hour to fully recharge the battery if maximum solar power is available.
10 | P a g e
3.4 Computations
Edge Computation
Edge computing is computing that's done at or near the source of the data. In the SITMoS, the
temperature sensor converts temperature reading to voltage reading with the conversion rate of 10
mV/°C and an offset of 600mV at 0°C. The voltage signal is then fed into the ADC port of the
microcontroller. The ADC pin has a 10-bit resolution, which means it converts 0 – 1000mV analog
signal to digital signal between 0 and 1023 bits. The data is sent to the cloud at 1 minute intervals.
This interval is programmable depending on the application requirement.
Cloud Computation
Cloud computing is the delivery of computing services such as storage, databases, networking,
software, analytics, etc. Arduino IDE was used to program the microcontroller for data retrieval
from sensor and data transmission to the Adafruit IO (cloud). The data is compared to set
conditions and action commands are sent to a Programmable Logic Controller (PLC) via the
Adafruit IO HTTP API. The PLC then controls the HVAC system of the carousel accordingly. Data
is also stored in the cloud for future analysis,
The following is an example of the set conditions and action commands:
< 400π‘šπ‘‰ (−20°πΆ): 𝐸π‘₯π‘‘π‘Ÿπ‘’π‘šπ‘’π‘™π‘¦ πΏπ‘œπ‘€ π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’! π΄π‘‘π‘‘π‘’π‘›π‘ π‘–π‘œπ‘› π‘…π‘’π‘žπ‘’π‘–π‘Ÿπ‘’π‘‘
401π‘šπ‘‰(−19.9°πΆ) < π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’ < 599π‘šπ‘‰(−0.1°πΆ): π‘‡π‘’π‘Ÿπ‘› π»π‘’π‘Žπ‘Ÿπ‘‘π‘–π‘›π‘” 𝑂𝑁
600π‘šπ‘‰(0°πΆ) < π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’ < 899π‘šπ‘‰(29.9°πΆ): π‘‡π‘’π‘Ÿπ‘› π΄π‘–π‘Ÿ πΆπ‘œπ‘›π‘‘π‘–π‘‘π‘–π‘›π‘” 𝑂𝑁
< 900π‘šπ‘‰(30°πΆ): 𝐸π‘₯π‘‘π‘Ÿπ‘’π‘šπ‘’π‘™π‘¦ π»π‘–π‘”β„Ž π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’! π΄π‘‘π‘‘π‘’π‘›π‘ π‘–π‘œπ‘› π‘…π‘’π‘žπ‘’π‘–π‘Ÿπ‘’π‘‘
11 | P a g e
3.5 The Data Packet
Firstly, using Wi-Fi credentials (i.e. WIFI_SSID and WIFI_PASS), the controller connects to the
local network. Secondly, connection to Adafruit IO is established by using the dafruit.io username
and adafruit.io key. Once connected, the data points are transmitted as ascii encoded text by the
controller to the Adafriut IO cloud service. Assuming 20% overhead, the following data packet
can be taken as an example:
dewanyaio_NFNKwZh4eF8IVYNtmsIq5b3NnbvqBELL777D88815A2C2F3765
This example includes the username, password, WiFi, WiFi Password and also the number sent.
The example data string above contains 60 characters.
𝐡𝑦𝑑𝑒𝑠 π‘…π‘’π‘žπ‘’π‘–π‘Ÿπ‘’π‘‘ π‘π‘’π‘Ÿ π·π‘Žπ‘‘π‘Ž π‘ƒπ‘Žπ‘π‘˜π‘’π‘‘ = πΆβ„Žπ‘Žπ‘Ÿπ‘Žπ‘π‘‘π‘’π‘Ÿ π‘ƒπ‘’π‘Ÿ π‘†π‘‘π‘Ÿπ‘–π‘›π‘” + π‘‚π‘£π‘’π‘Ÿβ„Žπ‘’π‘Žπ‘‘
= 60 + 20% π‘œπ‘“60 = 60 + 12 = 72 𝑏𝑦𝑑𝑒𝑠/π‘‘π‘Žπ‘‘π‘Ž π‘π‘Žπ‘π‘˜π‘’π‘‘
ASCII is an 8-bit code. It uses eight bits to represent a letter or a punctuation mark. Eight bits are
called a byte. To calculate the number of bits per data packet, multiply Bytes/Data packet by 8.
𝐡𝑖𝑑𝑠 π‘π‘’π‘Ÿ π·π‘Žπ‘‘π‘Ž π‘ƒπ‘Žπ‘π‘˜π‘’π‘‘ = 72 × 8 = 576 𝑏𝑖𝑑𝑠/π‘‘π‘Žπ‘‘π‘Ž π‘π‘Žπ‘π‘˜π‘’π‘‘
3.6 Data Transmission
Figure 8: System Architecture Block Diagram
12 | P a g e
The ESP8266 WiFi controller as an integrated TCP/IP client. The controller reads the sensor and
uploads the data to the Adafruit IO. The Adafruit IO uses a Key to restrict or grant access to the
data. The key is unique and covers every use of the Adafruit IO API for a certain account. Data on
IO is kept in time-series databases called feeds. Each feed contains time-stamped data points. The
data points do not have to be numbers and can be any type of data.
Figure 9: Adafruit IO Feed
As can be seen on the code below, the controller will connect to the feed, initialize the sensor, and
then execute a loop, sending the temperature every 1 minute. Free Adafruit IO Account is used for
this project. The rate limit for the free account is 30 data points per minute. With one SITMoS
system on each shelf, 12 data points will be transmitted per minute; there is no chance of loss of
data. The data coming in can also be monitored using the dashboard over at the Adafruit IO
website.
13 | P a g e
14 | P a g e
3.7 The Dashboard
Adafruit IO uses Dashboard to aggregate, visualize and analyze live data streams. The Dashboard
provides instant visualizations of the real-time data uploaded by SITMoS.
Figure 10: Adafruit IO Dashboard
An outdoor Carousel is not available to determine the accuracy of the SITMoS. However, an
experiment under controlled conditions is conducted to verify the accuracy and precision of the
system.
3.7 Statistical Analysis
In order to accurately test the system, the temperature around the sensor is artificially varied by
placing the sensor in an ice bath, thus a drop can be observed in figure 10 after which the
temperature readings settle to average environmental temperature of approximately 0°C (figure
11). The temperature within the ice bath is within +-0.1C of the melting point for water. The data
is transmitted to Adafruit IO. The data is graphed and tabulated as follows:
15 | P a g e
3.7.1 Data Received by Adafruit IO until Equilibrium Reached
Table 2: Data Received by Adafruit IO until Equilibrium Reached
Reading #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Time(s)
5
10
15
20
25
30
35
40
45
50
55
60
65
70
75
80
85
90
95
100
Data
787
692
668
656
649
646
645
642
637
628
619
617
617
617
617
617
617
617
617
617
Figure 11: Data Point-Time Plot for data received until Equilibrium Reached
Figure 10 shows the record of temperature monitoring over a period of time. The graph is
temperature vs. time where the temperature changes are updated after an interval of 5 seconds.
16 | P a g e
3.7.2 Data Received by Adafruit IO after Equilibrium Reached
Table 3: Data Received by Adafruit IO after Equilibrium Reached
Reading #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Time(s) Voltage (mV)
5
619
10
618
15
619
20
617
25
618
30
619
35
618
40
618
45
618
50
618
55
618
60
618
65
618
70
618
75
618
80
618
85
618
90
618
95
618
100
618
Figure 12: Data Point-Time Plot for data received after Equilibrium Reached
17 | P a g e
3.7.3 The Mean Measured Value of the Data Points – Accuracy Analysis
𝑁
20
𝑛=1
𝑛=1
1
1
1
Μ… = ∑ 𝐷𝑛 =
π‘€π‘’π‘Žπ‘› π‘œπ‘“ π‘‘β„Žπ‘’ π·π‘Žπ‘‘π‘Ž π‘ƒπ‘œπ‘–π‘›π‘‘π‘ , 𝐷
∑ 𝐷𝑛 =
× 12362 = 618.1
𝑁
20
20
π‘€π‘’π‘Žπ‘› π‘‰π‘œπ‘™π‘‘π‘Žπ‘”π‘’, 𝑉̅ =
618.1 − 1
× 1000 = 603.23π‘šπ‘‰
1024 − 1
π‘€π‘’π‘Žπ‘› π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’ =
603.23π‘šπ‘‰ − 600π‘šπ‘‰
= 0.323°πΆ
10π‘šπ‘‰/°πΆ
π‘‡π‘Ÿπ‘’π‘’ π‘‰π‘Žπ‘™π‘’π‘’ @ 0°πΆ π‘“π‘Ÿπ‘œπ‘š π·π‘Žπ‘‘π‘Žπ‘ β„Žπ‘’π‘’π‘‘ = 600π‘šπ‘‰
π·π‘–π‘“π‘“π‘’π‘Ÿπ‘’π‘›π‘π‘’ = 603.23π‘šπ‘‰ − 600π‘šπ‘‰ = 3.23π‘šπ‘‰ = 0.54%
3.7.4 The Standard Deviation of the Data Points – Precision Analysis
#
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Sum
Mean
Si Bandgap Sensor
Data Point (D) βˆ†D
(βˆ†D)2
619
1
0.809999999999959
618
0
0.010000000000005
619
1
0.809999999999959
617
-1
1.210000000000050
618
0
0.010000000000005
619
1
0.809999999999959
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
618
0
0.010000000000005
12362
618.1
3.800000000000000
18 | P a g e
1
1
2
Μ…
π‘†π‘‘π‘Žπ‘›π‘‘π‘Žπ‘Ÿπ‘‘ π·π‘’π‘£π‘–π‘Žπ‘‘π‘–π‘œπ‘› π‘œπ‘“ π‘‘β„Žπ‘’ π·π‘Žπ‘‘π‘Ž π‘ƒπ‘œπ‘–π‘›π‘‘π‘  = √𝑁−1 ∑𝑁
𝑛=1( 𝐷 − 𝐷𝑛 ) = √20−1 × 3.8 = 0.447
𝑆𝐷 π‘œπ‘“ π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’ = 0.447 × 0.068°πΆ/𝑏𝑖𝑑 = 0.03°πΆ
π‘†π‘‘π‘Žπ‘›π‘‘π‘Žπ‘Ÿπ‘‘ πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ π‘œπ‘“ π‘‡π‘’π‘šπ‘π‘’π‘Ÿπ‘Žπ‘‘π‘’π‘Ÿπ‘’, 𝑆𝐸 =
0.3
√20
= 0.0068°πΆ
The difference between the mean (0.323°C) and the true value (0°C) is 50xSE, thus the readings
are good. However, the following sources of error are considered for error analysis:
•
•
•
Calibration Accuracy of LM61B2M3
Gain Error of LM61B2M3
Line Regulation Error of LM61B2M3
Initial Calibration Accuracy [2]:
πΌπ‘›π‘–π‘‘π‘–π‘Žπ‘™ π΄π‘π‘π‘’π‘Ÿπ‘Žπ‘π‘¦ = ±3 °πΆ
πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ 𝑖𝑛 π‘„π‘ˆπ‘€ = ±3 °C
Gain Error [2]:
πΊπ‘Žπ‘–π‘› πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ = 0.3 π‘šπ‘‰/°πΆ
πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ 𝑖𝑛 𝑂𝑒𝑑𝑝𝑒𝑑 = 0.3 π‘šπ‘‰/°πΆ × (30 − 10) °πΆ = 6 π‘šπ‘‰
πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ 𝑖𝑛 π‘„π‘ˆπ‘€ =
6 π‘šπ‘‰
= ±0.6 °πΆ
10 π‘šπ‘‰/°πΆ
Line Regulation Error [2]:
𝐿𝑖𝑛𝑒 π‘…π‘’π‘”π‘’π‘™π‘Žπ‘‘π‘–π‘œπ‘› πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ = 0.7 π‘šπ‘‰/𝑉 × 3.7𝑉 = ±2.6 π‘šπ‘‰
πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ 𝑖𝑛 π‘„π‘ˆπ‘€ =
2.6 π‘šπ‘‰
= ±0.26 °πΆ
10 π‘šπ‘‰/°πΆ
Method 1 (Maximum Error):
π‘‡π‘œπ‘‘π‘Žπ‘™ πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ = 3 + 0.6 + 0.26 = ±3.86 °πΆ
Method 2 (Most Likely Error):
π‘‡π‘œπ‘‘π‘Žπ‘™ πΈπ‘Ÿπ‘Ÿπ‘œπ‘Ÿ = √32 + 0.62 + 0.262 = ±3.07 °πΆ
The accuracy and precision of the Temperature Sensor agree with the specifications for the
sensor/signal conditioning/measurement instrument.
19 | P a g e
Recommended and Future Work
Along with temperature, other sensors like humidity, gas, noise, light, pressure, and UV can be
used based on the application requirement. However, a controller with more analog input pins is
required to accommodate multiple sensors. The BeagleBone (BB) is a good option for applications
involving multiple sensors. Microsoft Azure IoT hub can be used as the cloud service with the BB
for a more powerful and robust application. MQTT protocol can also be used in place of HTTP to
communicate with external devices due to its lower complexity and ability to send information in
low bandwidth environments.
Conclusions
The goal of the project was to build a Smart IoT Temperature Monitoring System (SITMoS) for
real-time monitoring of temperature of surrounding environment. The sensed data is sent through
Wi-Fi to the cloud (Adafruit IO) where both real-time data and its graphical analyses can be viewed
(dashboard). The Adafruit IO HTTP API will provide access to the Adafruit IO data from any
programming language or hardware environment that can speak HTTP. This system will be
integrated with a Carousel automation and HVAC system where the monitored values of
temperature will be used to trigger some action and control the devices for heating or cooling as
needed. IoT based temperature detecting devices provide an efficient and definitive system for
monitoring environmental parameters. IoT based systems can also be extended for controlling
various electronic and electric devices from remote locations.
20 | P a g e
Appendix
Figure 13: Control Panel of the Carousel
References
[1] https://learn.adafruit.com/adafruit-feather-huzzah-esp8266?view=all
[2]https://www.ti.com/lit/ds/symlink/lm61.pdf?ts=1645318805504&ref_url=https%253A%252F
%252Fwww.google.com%252F
21 | P a g e
Download