Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 19

EE314 Electrical

Engineering Design
Lab #1: Internet of Things (IoT) system to
monitor light and temperature levels of the
lab

Group Member

Rereao Enari – S11136301

Carlo Babua – S11147301

Roaia Roota – S11080735


Aim
 Formalize with design process (10 step)
 Utilizing design process to design IoT system for power monitoring for USP

Introduction
INTRODUCTION
The internet is the foundation for network organization in the information era, and it has been
extended to numerous technologies to create the Internet of Things. The Internet of Things
connects systems and objects at various scales, resulting in complex systems known as Cyber-
Physical Systems (CPSs). The Internet of Things (IoT) technology allows the integration of a
variety of heterogeneous things, such as a basic object with Radio Frequency Identification
(RFID) or an autonomous car; or objects with high processing capacity or low computational
resources [6].

Sensor clouds allow data to be uploaded, evaluated, and actions to be made on actual objects
based on the results. With the advent of Sensor Clouds, data storage and processing has gotten
much easier. The service has a wide range of applications, including healthcare, structural
monitoring, environmental monitoring, disaster monitoring, and agricultural, among others [5].

This experiment will cover the design of IoT for University to monitor the lab's daily light and
air-conditioning usage in order to cut down on excessive energy use [5].
Methodology
Following the 10 steps of the design process was taken place for this experiment where;

1. The Needs are identified according to the problem stated

2. Information Phase where research is done mainly on IoT system and applications

3. Stakeholder Phase

4. Planning or Operational Research

5. Hazard Analysis

6. Specifications of components used for three designs

7. Creative Design

8. Conceptual Design

9. Prototype Design

10. Verification
Result

Design Process

1. Step 1: Problem Statement


The cost of electricity has increased at the University of the South Pacific. It has assigned an
electrical student to design a system to monitor lighting and air conditioning across the campus,
particularly in the lecture halls and laboratories. The technology will be used to identify
unnecessary electricity use so that it may be controlled and reduced.
2. Step 2: Information Phase
Solution to the problem

Efficency
electrical
appliacne

Smart
Power
Renewable consumption
Monitoring
energy Reducing system
(IoT)

Managing
the useed
of electricty

Figure 1.0: Some of the way to reduce power consumption

Smart Monitoring System (IoT)


The Internet of Things (IoT) is a new breakthrough technology that involves the integration of
sensing and communication capabilities into everyday objects in order to collect relevant data.
These IoT-enabled device to monitor various important physical, electrical, and environmental
factors. These data then utilized to evaluate, detect, and address a variety of problems that arise
in everyday life. One such significant problem is electrical power management, which allows for
more efficient use of electricity. IoT-enabled power monitoring devices can assist in resolving
this issue by giving specific data on electricity usage.

Component’s specification
Microcontroller
A microcontroller is used to obtain values of physical conditions through sensors
connected to it.
I. Arduino Mega 2560 Microcontroller
The Arduino Mega 2560 is a microcontroller board based on the ATmega2560. It has 54 digital
input/output pins (of which 15 can be used as PWM outputs), 16 analog inputs, 4 UARTs
(hardware serial ports), a 16 MHz crystal oscillator, a USB connection, a power jack, an ICSP
header, and a reset button. It contains everything needed to support the microcontroller; simply
connect it to a computer with a USB cable or power it with a AC-to-DC adapter or battery to get
started. The Mega 2560 board is compatible with most shields designed for the Uno and the
former boards Duemilanove or Diecimila. [1]

- Operating Voltage -> 5V


- Input recommended Voltage ->7 - 12V
- Input voltage limit -> 6 – 20V
- Digital I/O pins -> 16 pins
- DC current per I/O -> 20mA
- DC current for 3.3V pin ->50mA

II. PIC16F8722A Microcontroller

This microcontroller is very convenient to use, the coding or programming of this controller is
also easier. One of the main advantages is that it can be write-erase as many times as possible
because it uses FLASH memory technology. It has a total number of 40 pins and there are 33
pins for input and output.

PIC16F877A is used in many pic microcontroller projects. PIC16F877A also have much


application in digital electronics circuits. Pic microcontrollers used Harvard architecture. PIC
microcontrollers are available in a wide range starting from 8-bit to 32-bit microcontrollers. [2]

III. ATmega168

The high-performance, low-power Microchip AVR® RISC-based CMOS 8-bit microcontroller


combines 16 KB ISP flash memory with read-while-write capabilities, 512B EEPROM, 1 KB
SRAM, 23 general purpose I/O lines, 32 general purpose working registers, three flexible
timer/counters with compare modes, internal and external interrupts, serial programmable
USART, byte-oriented Two-Wire serial interface, SPI serial port, 6-channel/10-bit A/D
converter (8-channel in TQFP and QFN packages), programmable watchdog timer with internal
oscillator, and five software selectable power saving modes. By executing powerful instructions
in a single clock cycle, the device achieves throughputs approaching one MIPS per MHz,
balancing power consumption and processing speed. [3]

IV. 8051 family

This is the CPU (central processing unit) of our project. We are going to use a microcontroller of
the 8051 family. The various functions of the microcontroller are like:
I. Reading the digital input from ADC which is derived from Temperature and Light sensor. II.
Sending this data to LCD so that the person operating this project should read the values of
temperature and light. III. Controlling the parameters like Temperature, light is turning On/Off
the respective relays IV. Sending the values of temperature and light to the computer using a
serial port. [4], [5].

  V. ESP32 MCU

 CPU and Memory


• Xtensa® single-/dual-core 32-bit LX6 microprocessor(s), up to 600 MIPS (200
MIPS for ESP32-S0WD, 400 MIPS for ESP32-D2WD)
• 448 KB ROM     
• 520 KB SRAM

• 16 KB SRAM in RTC
• QSPI supports multiple flash/SRAM chips
 Clocks and Timers                             
• Internal 8 MHz oscillator with calibration
• Internal RC oscillator with calibration                          
• External 2 MHz ~ 60 MHz crystal oscillator (40 MHz only for Wi-Fi/BT
functionality) 

•External 32 kHz crystal oscillator for RTC with calibration                                    


•Two timer groups, including 2 × 64-bit timers and 1 × main watchdog in each
group         
• One RTC timer
 RTC watchdog 

 Advanced Peripheral Interfaces    

• 34 × programmable GPIOs
   
• 12-bit SAR ADC up to 18 channels
• 2 × 8-bit DAC
• 10 × touch sensors
• 4 × SPI
• 2 × I²S
• 2 × I²C
• 3 × UART
• 1 slave (SDIO/SPI)
• Ethernet MAC interface with dedicated DMA and IEEE 1588 support
• CAN 2.0
• IR (TX/RX)
• Motor PWM
• LED PWM up to 16 channels
• Hall sensor

Light Sensor
I. Photoelectric Sensors

Photoelectric Sensors detect photo-optical work pieces. OMRON provides many varieties of
Sensor, including diffuse-reflective, through-beam, retro-reflective, and distance-settable
Sensors, as well as Sensors with either built-in or separate amplifiers and Fibre Units [6].

II. XUVE04M3KSNM8

Photoelectric sensors XU, photo Elec sensor label fork 40x3, 12...24 V DC, PNP/NPN NO/NC
connect M8 [7]

III. XUB2BKSWM12T

The OsiSense XUB2B series 15mm through-beam general purpose Photoelectric


Sensor with sensing distance related to system and single mode function.
Applications
Sensing & Instrumentation, Industrial [8]

Temperature Sensor

I. DHT11–Temperature and Humidity Sensor


The DHT11 is a commonly used Temperature and humidity sensor that comes with a
dedicated NTC to measure temperature and an 8-bit microcontroller to output the
values of temperature and humidity as serial data. [9]
Specifications:

 Operating Voltage: 3.5V to 5.5V


 Operating current: 0.3mA (measuring) 60uA (standby)
 Output: Serial data
 Temperature Range: 0°C to 50°C
 Humidity Range: 20% to 90%
 Resolution: Temperature and Humidity both are 16-bit
 Accuracy: ±1°C and ±1%

II. LM35 sensor


The LM35 is a temperature sensor whose output voltage is linearly proportional to
Celsius temperature. The LM35 comes already calibrated hence requires no external
calibration. It outputs 10mV for each degree of Celsius temperature. [10]

• Calibrated Directly in ° Celsius (Centigrade)

• Linear + 10 mV/°C Scale Factor

• 0.5°C Ensured Accuracy (at +25°C) 

• Rated for Full −55°C to +150°C Range

• Operates from 4 to 30 V

• Less than 60-μA Current Drain 

• Low Self-Heating, 0.08°C in Still Air

• Low Impedance Output, 0.1 W for 1 mA Load

• Nonlinearity Only ±¼°C Typical 

III. EMC1833T-2E/RW

Features [11]
• Measures Temperature Rate of Change Calculation with Preemptive Alert(s)
Limits • Up to Four External Temperature Monitors: – 8-Lead Devices: ±1°C
maximum accuracy (-20°C to +105°C TA, -40°C to +125°C TD) – ±1.5°C
maximum accuracy (-40°C to +125°C TA, -40°C to +125°C TD) – 10-Lead
Devices: ±1°C maximum accuracy (-20°C to +125°C TA, -40°C to +125°C TD) –
±1.5°C maximum accuracy (-40°C to +125°C TA, -40°C to +125°C TD)
• Internal Temperature Sensor: – ±1°C maximum accuracy, -40°C to +125°C
• Temperature Sensor Resolution (Internal/External): 0.125°C
• Configurable Alert Pins
• Operating Voltage: 1.62V to 3.6V

IV. STS3x-DIS

High-Accuracy Digital Temperature Sensor IC


 Fully calibrated and linearized digital output
 Wide supply voltage range, from 2.15 V to 5.5 V
 I2C Interface with communication speeds up to 1 MHz and two user
selectable addresses
 Accuracy of up to  0.1 °C
 Very fast start-up and measurement time
 Tiny 8-pin DFN package
 NIST traceability
Cloud service
Cloud computing is a common technique that involves using the internet to store and
manage data. These services are designed to provide easy, affordable access to
applications and resources, without the need for internal infrastructure or hardware.
 Blynk IoT software
• develops apps for industries using devices to exchange data without involving
other parties
•  improves Big Data Analytics by unlocking existing data sources and providing an
efficient centralized evaluation
• uses internal sensors to collect data from consumer devices such as Smart TVs,
appliances, security systems
3. Stakeholders
a. University of the South pacific
b. Schools
c. Workplace
d. Public
4. Planning/Operational Research (Limitation)
e. Cost
f. Availability of components
Specification (Requirement)
Table 1.0: The table below show all the component used for design 1

DESIGN #1
Component’s name Microcontroller Temperature Light sensor Cloud
Sensor
Arduino Mega 2560 DHT11 Photoelectri  
c Sensor
- USB or external - VCC Power - 12 – 24V
power supply supply 3.5 – 5.5V power supply
Power - 6 to 20 volts - Operating current Output – Visualization
0.3mA NPN Data
- Maximum current management
draw is 50mA  Data
-Design to reset - IP66 analysis
- use polyfused. None Protection
Protection 500mA current level
applied, fuse
automatically breaks.
Interface/Programming - Comes programmed - 8-bit - Move and
with a bootloader Microcontroller to reset less
- Not using external output temperature than 1ms
hardware programmer response
time.
- 16 Analog input pin - Temp range 0°C - 0.02 kg
- 256KB of used 8KB to 50°C weight
Specification Flash memory - Humidity range - 4m distance
- 8KB SRAM 20% -90% detection
- 4KB EEPROM - Accuracy ± 1°C
- 16MHz Clock speed and ± 1%
Table 2.0: Table below show the component use for design 2
Design #2 Microcontroller Temperature Light Sensor Cloud
Sensor
Component Names  PIC16F8722A  EMC1833T-  XUB2BKSWM12T  SENSORCLOUD
2E/RW
     Industrial Processes  Automobiles  Visualization

   Industrious  Temperature   Streetlights Data management

Application Commercial  Humidity  Security  Data analysis

     Whether    
         
    SLEEP mode      
   Data memory - 128   Sensing  Operating  
temperature-40°C ~ temperature -25...55
125°C °C
Specification  Timer - 3    DC 10...36 V DC  
voltage range: 2.0V Working voltage 35 mA (no-load)
to 5.5V 1.62V ~ 3.6V
64 bytes of  Accuracy ±1.5°C 1 male connector
EEPROM Data M12, 4 pins
Memory
   < 2mA @ 5V  IP65  
   5 input channels      
    DC - 20 MHz clock  Computable with  < 15 ms  
input DC - 200 ns PIC microcontroller
instruction cycle
Others  MSSP    <= 500 Hz  
       
         
Table 3.0 Table below show all the component and specification for design number 3

Design #3 Microcontroller Temperature Sensor Light Sensor Cloud


Componet ESP32 LM35 IR Sensor Blynk
Names
   Home Automation  Transportation  Night-Vision Devices Businesses
  Energy monitoring for Smart HVAC systems  IR Image Devices  Developers
Building
Application Industrial Automation Avionics  Gas Detectors  Data analysis
  Health monitoring Security  Radiation  Data
Thermometers management
  Remote controlled toys Industrial Processes  Industrial Safety  
Devices
   34 x Programmable GPIOs +5 V VDD  5 Vdc Power Supply  -
  18 channels of 12-bit SAR  GND  GND  
ADC
Specification  Motor PWM  Vout  Vout (Digital Output)  
  3 x UART   Draws 60 µA  20 mA supply current  
  10 x Touch sensors      
4 x SPI
 500 mA output current
IR (TX/RX)
   160 MHz (for ESP32-  -55 ℃ to +150℃ rates  Combatable with  
D2WD) ESP32
   400 MIPS (CPU of ESP32-  Accuracy of +/-0.4℃    
D2WD)
Others  Up to 80 MHz of SPI  Combatable with ESP32    
   Up to 4MHz High-speed      
UART HCI
5. Selecting Final design

Table 4.0 Decision Matrix Table

Components Design 1 Design 2 Design 3


Microcontroller  Arduino Mega 2560  PIC16F8722A  ESP32
Application  2  1  3
Connectivity  1  2  2
Speed  2  2  2
Power consumption  1  3  1
Range  2  2  2
Temperature Sensor  DHT11  EMC1833T-2E/RW  LM35
Application  2  2  3
Connectivity  1  1  2
Speed  2  3 3
Power consumption  1  2  1
Range  2  1  2
Light Sensor  Photoelectric Sensor  XUB2BKSWM12T  IR Sensor
Application  2  1  2
Connectivity  1  1  1
Speed  1  2  2
Power consumption  2  1  2
Range  1  1  2
Total Point  23  21  30

Design #3 was going to used for a final design


Scoring
1 – poor
2 – Good
3 – Perfect
6. Block Diagram

Figure 2.0 Block diagram of final solution


7. Design Verification

Overview

The ESP32 is a 2.4 GHz WIFI and Bluetooth chip which is designed for best power
performance, and reliability in various applications [7]. Additionally, ESP32 is of series of chips
of ESP32-DOWDQ6, ESP32-D2WD, ESP32-SOWD, and ESP32-DOWD [7]. This chip is
designed for IoT applications, smart phones, and many more. The ESP32 takes actions only
when a precise condition detected by a low power IoT sensor, which means that using ESP32
can be useful in terms low power consumption [8]. Moreover, due to its robustness and low
power consumption, ESP32 has become popular in IoT applications.

Security Features

ESP32 has two security features called secure boot, and Flash security [7]. Flash security is a
feature with a main purpose of protecting the Flash memory. As the flash security gets enabled,
the binaries or data flashes into the memory, and then the device encrypted each and every
partition, using AES Flash encryption. After encryption, the device restarted with the
programmed logic processing. However, ESP32 Secure boot is a feature that verifies every flash
memory’s binary with eFuse RSA-3072, before running application firmware. In other words,
the Secure Boot protects the ESP32 from damaging [8].

Block diagram

Figure 3.0: Block Diagram of ESP32 MCU


1. Blynk IoT software (Cloud Service)

Figure 4.0: Blynk app for IoT applications

Blynk app is an app that uses sensors to collect data from appliances, HVAC systems and
security systems, and many more, for controlling hardware. Moreover, the Blynk software
develops apps for homes, industries, laboratories, offices where actions can be taken
automatically for monitoring and controlling issues or power wastage [11]. Also, Blynk app
offers data visualization to optimize the stakeholders’ decision making. Lastly, but not least, the
Blynk app enables only secured devices to connect to the user’s network where the software
controls and runs diagnosis on system for protection from any threats.
Circuit Diagram

Figure 5.0 Circuit diagram of verification project

Discussion
In this experiment, an IoT system for power monitoring for USP lobotomy was designed. The
experiment went through ten major design steps, including identifying the problem, obtaining
data, producing various solutions, and assessing the selected solution.
The experiment begins with determining what the major problem is that has to be solved and
defining it in a problem statement. After the problem has been resolved, the design moves on to
the information phase. The goal of this portion of the experiment was to find a solution to the
problem stated in the problem statement. Figure 1.0 depicts several approaches to resolving the
power consumption issue. The experiment finds four key solutions: efficiency appliances,
renewable energy, power consumption control, and monitoring using a smart system (IoT). The
experiment focuses on the Internet of Things (IoT) system. The experiment moved on to seek for
information on the IoT system after picking a solution for the problem in step 2. Step 3 contains
data and specifications on the various components utilized in an IoT system. Microcontroller,
sensor, and cloud are the three basic components of an IoT system. As seen in step 3, the
experience has different specifications for each IoT component.
Furthermore, the experiment generates multiple solution for the design required for the problem.
As shown in table 1.0 to 3.0 shows different design component with specification. Design 1 use a
Arduino microcontroller, DHT11 temperature sensor and Photoelectric sensor Design 2 use
PIC16F8722A microcontroller, EMC1833T-2E/RW temperature sensor, and XUB2BKSWM12T
for light sensor. Design 3 use ESP32 microcontroller, LM35 temperature sensor, and IR sensor
for light sensor. The experiment notice that all design is have pro and cons, however to make fair
decision on the best design, the experiment use a matrix decision In table 4.0, show the design
decision, based on the specification of each component the experiment rank from 1 to 3.
According to the result design number 3 was selected for the final design.

Conclusion
The experiment was effective in designing a solution to the problem of excessive power usage in
USP Labs. Design number three was chosen as the final design based on the design requirements
and decision matrix. To carry out the dosage, the experiment employs engineering design
approaches (step).

REFERENCE
[1] "Arduino Mega 2560 Rev3", Arduino Official Store, 2021. [Online]. Available:
https://store.arduino.cc/products/arduino-mega-2560-rev3. [Accessed: 09- Sep- 2021].

[2]"Arduino Reference - Arduino Reference", Arduino.cc, 2021. [Online]. Available:


https://www.arduino.cc/reference/en/. [Accessed: 09- Sep- 2021].

[3]"Overview of Photoelectric Sensors | OMRON Industrial Automation", Ia.omron.com, 2021.


[Online]. Available: https://www.ia.omron.com/support/guide/43/introduction.html. [Accessed:
09- Sep- 2021].

[4]"DHT11–Temperature and Humidity Sensor", Components101, 2021. [Online]. Available:


https://components101.com/sensors/dht11-temperature-sensor. [Accessed: 09- Sep- 2021].

[5]"EE314 – Lab 1", Elearn.usp.ac.fj, 2021. [Online]. Available:


https://elearn.usp.ac.fj/pluginfile.php/270298/mod_resource/content/1/Lab%201.pdf. [Accessed:
09- Sep- 2021].

[6] M. Geller and A. Meneses, "Modelling IoT Systems with UML: A Case Study for
Monitoring and Predicting Power Consumption", American Journal of Engineering and Applied
Sciences, vol. 14, no. 1, p. 81, 2021. Available: 10.3844/ajeassp.2021.81.93.

You might also like