Bài báo cáo Assignment 2 về môn Internet of Things (IoT) của BTEC đã đạt điểm Merit, thể hiện sự hiểu biết sâu sắc và kỹ năng ứng dụng tốt. Bài báo cáo đã cung cấp một cái nhìn tổng quan về IoT, bao gồm cả lịch sử, nguyên lý hoạt động, và các ứng dụng thực tế. Đặc biệt, bài báo cáo đã tập trung vào việc phân tích các vấn đề an ninh và quyền riêng tư liên quan đến IoT, cũng như đề xuất các giải pháp để giải quyết những vấn đề này. Bài báo cáo cũng đã đề cập đến các công nghệ và tiêu chuẩn mới nhất trong lĩnh vực IoT. Sự cố gắng và nỗ lực đã giúp bài báo cáo đạt được điểm số cao.
Outline a plan for an appropriate IoT application, using common architecture, frameworks, tools, hardware and APIs
Inves gate architecture, frameworks, tools, hardware and API techniques available to develop
Our idea is an infrared an -the system that takes advantage of cu ng-edge technology to improve security and protec on This system detects unlawful movement and intrusions using infrared sensors, promp ng quick warnings and reac ons The project is built with the goal of delivering dependable and efficient security, giving consumers piece of mind With the use of infrared technology, it provides a strong and sophis cated solu on for protec ng important assets and premises
Sensor Floor: At this floor, use infrared sensors to detect the movement of people or objects in the area to be protected
Middle Layer (Gateway): Data from the sensor is sent to a Gateway, usually an intermediate IoT device or network computer, to process and transmit data to the applica on layer
Applica on Layer: At this layer, there is an IoT applica on dedicated to the an -the system This applica on receives data from the Gateway and manages the an -the system, triggers alarms and sends no fica ons to users
Sensor Floor: At this floor, infrared sensors are used to detect mo on
Network Layer: Data from the sensor is sent to an intermediate IoT device or IoT network node (IoT node) The network layer handles communica on and transfers data to the background layer
Back-End: Data from the network layer is fed into the IoT data storage system or IoT server Here, data is stored, processed and analyzed to determine if there is any suspicious movement
Applica on Layer: This layer manages and processes data, checks for unwanted mo on events, and sends alerts to users via mobile apps or through no fica on mechanisms
To create a complete and efficient IoT system, you can use the following classes:
Sensor layer: This layer contains IoT devices or sensors to collect data from the environment Chungs I use infrared sensors to develop the project
Connec vity Layer: This layer manages how data from the sensor is transmi ed to the IoT system It includes a Wi-Fi communica on protocol, and a gateway to collect and transmit data to the network or cloud
Analy cs Layer: This layer uses data from the Data layer to perform analysis, extract important informa on, and create reports or predic ons It includes data analysis tools, machine learning algorithms, and data visualiza on
Product Infrastructure Layer: The Product Infrastructure Layer provides the infrastructure for managing and controlling IoT devices It includes device management, firmware updates and remote configura on This ensures that the equipment is properly installed and maintained
Smart Apps Layer: Smart applica on layer includes applica ons that interact with IoT systems These applica ons can be web or mobile applica ons, allowing users to monitor and control devices, receive no fica ons, and access analy cal data
For crea ng Internet of Things (IoT) applica ons and solu ons, there are numerous frameworks and pla orms available These frameworks offer tools, libraries, and services that make IoT crea on and maintenance easier Here are several well-known IoT frameworks:
Arduino: Arduino is an open-source hardware and so ware pla orm that is popular for prototyping IoT devices It includes a wide range of compa ble sensors and shields, making it easy to build IoT prototypes
ESP8266: is a Wi-Fi module with Internet connec vity and is integrated on some embedded boards such as NodeMCU, Wemos, and ESP-01 The ESP8266 can act as an access point, a client connec ng to another access point, or both It is widely used in IoT (Internet of Things) applica ons such as smart sensors, device control systems, or remote control applica ons This module is cheap and very easy to use, along with compa bility with many different types of microcontrollers
I use the following tools to make the project
- Infrared Sensor: Used to detect movement
- IoT Gateway device or Node: Used to collect data from sensors and transmit to the network or pla orm layer
- IoT Server or Storage System: Stores and processes data from sensors
- Mobile device (Smartphone or Tablet): Use to receive alerts and no fica ons from IoT applica ons
Several types of Sensors and Output loads :
Sensor: Humidity Sensor, Gas Sensor, Water Sensor, Light Sensor, Mo on Sensor, Touch Sensor,Utralsonic Sensor, Temperature Sensor,…
Output loads: Led, Servo Motor, Buzzer, Stepper Motor, Relay, GPIO,…
- Devices and apps in an Internet of Things (IoT) ecosystem communicate and exchange data using an API (Applica on Programming Interface) set of rules and interfaces IoT APIs facilitate communica on and interac on between various IoT system elements, such as sensors, devices, services, and apps
- In the context of IoT, APIs essen ally specify how informa on is sent and received between devices and pla orms, as well as how commands and no fica ons can be sent and received IOT APIs usually offer the ability to access and manage data gathered from devices as well as remotely manage, control, and monitor them
- Here are some common APIs:
MQTT (Message Queuing Telemetry Transport): MQTT is a lightweight and powerful communica on protocol, commonly used for sending messages between devices in IoT environments
CoAP (Constrained Applica on Protocol): CoAP is a lightweight communica on protocol, op mized for devices with limited resources It is commonly used for communica on between IoT devices and servers
HTTP/HTTPS (HyperText Transfer Protocol/Secure): HTTP and HTTPS protocols are commonly used to communicate between IoT devices and web service pla orms
RESTful API (Representa onal State Transfer): RESTful API provides a communica on architecture based on HTTP methods It is commonly used to create interfaces between devices and web applica ons
WebSocket: WebSocket is a protocol that allows devices and servers to communicate in real me It is suitable for applica ons that need low latency
AMQP (Advanced Message Queuing Protocol): AMQP is a standard protocol for communica on between applica ons and services, o en used in large IoT systems
Bluetooth APIs: For IoT applica ons that use Bluetooth connec vity, APIs such as the Bluetooth Low Energy (BLE) API are provided to manage connec vity and communica ons
- Blynk is an IoT (Internet of Things) pla orm that helps connect and manage smart devices via the internet Here are some preliminary characteris cs about Blynk Cloud:
Friendly User Interface: Blynk provides a simple and friendly user interface, helping users easily interact with their IoT devices
Mul -Pla orm Support: Blynk supports mul -pla orm, including iOS, Android and web pla orms This helps users control and monitor devices from any mobile device with an internet connec on
Determine a specific problem to solve using IoT.(P4)
4.1.1 Plan an IoT applica on for a specific target end user in the form of a document IoT Applica on Plan: Infrared An -The System
The s and unauthorized access to homes, offices, and valuable assets are persistent issues affec ng the security of individuals and organiza ons To address this problem, we propose the development of an Infrared An - The System using IoT technology This system aims to provide an efficient and reliable solu on for detec ng and preven ng intrusions
Our target end users for this IoT applica on include:
- Homeowners: Individuals who want to enhance the security of their homes, ensuring the safety of their loved ones and valuable possessions
- Small Businesses: Small business owners looking for cost-effec ve security solu ons to protect their offices, stores, and inventory
- Security Personnel: Security professionals who require advanced tools to monitor and secure large proper es and facili es
Our IoT applica on will leverage Infrared (PIR) sensors to detect mo on and heat sources within a specific range When unauthorized movement or intrusion is detected, the system will trigger alerts and no fica ons to the end users The IoT aspect allows for remote monitoring and control, enhancing the overall security and peace of mind for the users
- Infrared Sensors: U lize IR sensors for precise mo on and heat detec on
- Internet Connec vity: Connect to the internet to enable remote monitoring and management
- Real-Time Alerts: Provide real- me alerts through mobile apps or email no fica ons when intrusions are detected
- Remote Control: Allow end users to arm or disarm the system remotely using a mobile applica on
- Data Logging: Record event data and mestamp to maintain a history of security-related events System Architecture
The proposed IoT applica on will follow a three- er architecture:
- Device Layer: This layer comprises Infrared sensors and IoT-enabled devices Arduino Uno R3 and ESP8266
- Middleware Layer: This layer handles data processing, event detec on, and communica on with end users via RESTful APIs
- Applica on Layer: End users interact with the system through a user-friendly mobile applica on or web interface for remote monitoring and control
- Hardware Setup: Install Infrared sensors at strategic points in the secured area
- Connec vity: Establish an internet connec on for the IoT devices
- Programming: Develop the firmware for the IoT devices, including mo on detec on, data transmission, and alert genera on
- API Development: Create RESTful APIs for communica on between IoT devices and the user interface
- User Interface: Develop user-friendly mobile applica ons and web interfaces for end users
- Tes ng: Thoroughly test the system to ensure the accurate detec on of intrusions and the reliability of alerts
- Deployment: Install the system at the target loca ons and provide user training
- Maintenance: Monitor the system for ongoing opera on and provide necessary maintenance
In the diagram above, the infrared sensor sends informa on to the Arduino when mo on is detected The Arduino will process informa on from the sensor and keypad If the authen ca on informa on is correct, Arduino will control other devices such as LED, Buzzer, and Servo Motor Informa on is also displayed on the LCD screen
Algorithm diagram presents the opera ng process of the infrared an -the IoT project The process first starts with boo ng and configuring the devices, then waits for the user to enter the password via the LCD screen and keypad
Next, the system checks the entered password and compares it with the previously set password If the password is correct, the system enters Standby Mode, where infrared sensors are ac vated to detect movement in the environment
When there is a mo on event, the system ac vates an alarm, using LED lights, sound from the horn and displays a no fica on on the mobile applica on The user can then iden fy and unlock the door by opera ng the keypad This process helps ensure safety and protect assets before the
Finally, the project will finish one cycle and be ready for the next cycles Diagram algorithm help helps understand the system's opera on and is the basis for op mizing and expanding features in the future
Select the most appropriate IoT architecture, frameworks, tools, hardware and API techniques
PIR mo on sensor HC-SR501:
Number of connec on pins: 13(digital)
Number of connec on pins ROWS: 4, 8, 7, 6(digital)
Number of connec on pins: 12(digital)
Number of connec on pins: A0 (Analog)
Number of connec on pins: 2 (digital)
Number of connec on pins: 11(digital)
Number of connec on pins: 10(digital)
Choosing Arduino for the infrared an -the IoT project was done for many specific reasons First, Arduino is a popular and easy-to-use pla orm that is great for embedded projects like an -the projects Simplicity in programming and integra on with other components reduces project complexity, especially when it involves devices such as infrared sensors, keypads, LCD screens, LEDs, buzzers and servos
Second, the large community around Arduino provides great documenta on and significant support This helps reduce development and troubleshoo ng me through sharing experiences and knowledge At the same me, the variety of Arduino versions allows choosing the model that suits the specific requirements of the project
Arduino also has good compa bility with many different types of addi onal components and modules In an an -the project, combining an Arduino with devices such as infrared sensors and servos helps create a secure and flexible system This flexibility is important to ensure that the system can adapt to different requirements and situa ons
In short, simplicity, popularity, community support, and compa bility are the key reasons that make Arduino the ideal choice for an infrared an -the IoT project
Choosing to use the ESP8266 module in an infrared anti-theft IoT project is especially reasonable and brings many important advantages The ESP8266 is a built-in Wi-Fi module, designed for easy integration into IoT projects, which offers several important benefits
First, the wireless connectivity of the ESP8266 makes the project more flexible and easier to manage remotely This module allows direct access to the project via Wi-Fi, helping users conveniently monitor and control the system over the network
Second, the ESP8266 has a compact size and low power consumption, which makes it a suitable choice for projects that require compactness and energy efficiency This is important in an anti-theft system, where maintaining performance without increasing cost and complexity is key
Third, the ESP8266 has a strong support community and many online references, which helps reduce development time and problem solving The popularity of the ESP8266 in the IoT community also provides high stability and reliability
In short, the combination of Wi-Fi connectivity, small size, energy efficiency and strong community support are the key reasons why ESP8266 is the superior choice for anti-virus projects This thief
Improved user interface: Provides a new user interface, designed to make the programming process easier and friendlier
Support for a variety of boards: Con nue to improve compa bility with a variety of Arduino and other boards
Feature updates: New versions o en bring feature improvements, bug fixes, and performance
The applica on supports control connec on via the Internet
Blynk is a popular and powerful IoT (Internet of Things) pla orm that provides Blynk Cloud to manage and connect IoT devices Here are some advantages of Blynk Cloud along with an introduc on to the func onal components in the interface of Blynk Cloud and the Blynk mobile applica on:
Ease of Use: Blynk Cloud is designed to be simple and easy to use, helping users quickly connect and control IoT devices
Secure Connec on: Blynk Cloud provides a secure connec on between devices and mobile applica ons through secure protocols
Cross-Pla orm Support: Supports mul ple pla orms and device types, from simple microcontrollers to complex IoT boards
Free Cloud Service: Blynk provides a free cloud service to users, helping them quickly deploy their IoT projects without the need to deploy their own servers
Dashboard: Allows users to create and customize dashboards to remotely monitor and control IoT devices Project Se ngs: Where users manage general se ngs for the project, including connec on informa on and opera ng modes
Datastreams: Display and manage data from connected devices
Virtual Pins: Virtual pins enable interac on between mobile applica ons and IoT devices
Widgets (Interface Elements): Blynk provides a series of widgets such as bu ons, sliders, clocks, charts, for users to easily create control interfaces
Eventor: Allows users to set automated rules and scenarios based on events and device status
History: Displays a history of events and data from the device
Apply selected techniques to create an IoT applica on development plan (M4)
We, the research team, took full advantage of our crea vity and technical understanding to plan and implement an an -the system project using infrared technology This marks an important step in our journey, where together we build a unique and effec ve security solu on
During the planning process, we set specific goals about the system's features and capabili es At the same me, we have clearly iden fied elements such as infrared sensors, keypads, servo, and other components to op mize an -the capabili es and at the same me ensure the prac cal applicability of the project
Close coopera on between team members is an important key to project success We leverage our diversity of knowledge and skills to deliver innova ve ideas and prac cal solu ons This not only fosters crea vity but also ensures that we have a comprehensive view of every aspect of the project
We worked hard to realize the idea from selec ng components to wri ng programs and integra ng them into a powerful opera ng system This process not only helps us apply the knowledge we have learned but also strengthens our teamwork and problem-solving skills
We started by crea ng a detailed list of components needed for the project, including infrared sensors, controllers, LCD screens, servo, LED, buzzer, ESP8266 Wi-Fi module, etc We then do research on suppliers and stores that specialize in electronic components to ensure that we can get quality products at the right price
The hardware assembly process for our infrared an -the system project was done in a careful and organized manner Below is a detailed descrip on of this process:
- Prepare Components: Before star ng, we thoroughly checked and arranged the components according to the list we purchased This helps us easily access and use components conveniently during the assembly process
- Install Main Components: We started by installing the main components such as infrared sensor (PIR), controller (Arduino and ESP8266), LCD screen, keypad, servo motor, LED and buzzer Each component is carefully connected to ensure system consistency and stability
- Install the Power Supply and Connec ons: A er installing the main components, we con nue with installing the power supply and electrical connec ons This includes connec ng the power, ground, and control wires from the components to the common circuit
- Check Connec on and Opera on: Before final packaging, we performed system connec on and opera on tests This includes using the Arduino IDE to load the program and check that each component works as expected If any problems appeared, we made the necessary adjustments
The process of wri ng the control program for the infrared an -the system project is an important and interes ng part of the en re project development process To ensure system performance and stability, we have approached wri ng source code in an organized and standard way Below is a descrip on of this process:
- Iden fy Func onal Requirements: First, we iden fied specific func onal requirements for the system, from mo on sensing to how the door opens and closes This gives us an overview of the features we want to integrate into the project
- Choose Programming Language and Environment: We decided to use Arduino IDE with C++ programming language to write the program This choice is due to convenience, high compa bility with a wide range of Arduino microcontrollers, and strong support from the development community
- Integra ng Libraries: To reduce complexity and increase code stability, we used exis ng libraries for components such as keypad, servo, and LCD This helps us save programming me and ensure the correctness of the source code
- Programming Each Func on Separately: We have divided the program into small func ons that control each specific func on, such as controlling the PIR sensor, processing data from the keypad, and controlling the servo motor This helps to be er manage and understand each part of the project
- Tes ng and Fixing: A er wri ng the source code, we perform thorough tes ng to ensure every func on works as expected Debugging and op mizing source code is an important part of this process
Step 5 : Load Program and Test
Develop an IoT application using any combination of hardware, software, data, platforms
Employ an appropriate set of tools to develop a plan into an IoT applica on.(P5)
The an -infrared IoT project has achieved significant results in improving security and access control By integra ng infrared sensors, keypads, LCD screens, LED lights, buzzers and servos, the system delivers important benefits
Infrared sensors respond quickly and accurately to movement in the monitoring area, triggering alerts immediately The keyboard provides a secure and convenient means for the user to gain access to the host system
The LCD screen displays detailed informa on about the system status, making it easy for users to monitor and control LED and Buzzer create effec ve warnings, a rac ng a en on when there is a problem servo ensures the ability to remotely control a door or gate in a safe and opera onal manner
The result is a powerful security system, helping users monitor and control their space effec vely Rapid detec on and response capabili es with the ability to prevent intrusions and protect assets At the same me, the remote control feature brings benefits and opera ons in security management This is a successful IoT project, improving the balance of safety and peace of mind for users
This is the video link of the system: https://youtu.be/4furznl9Z6E
6.1.2 Source code of the system
Figure 0.18: Code of the system(1)
Figure 0.19: Code of the system(2)
Figure 0.20: Code of the system(3)
Figure 0.21: Code of the system(4)
Figure 0.22: Code of the system(5)
Figure 0.23: Code of the system(6)
Figure 0.24: Code of the system(7)
Figure 0.25: Code of the system(8)
Figure 0.26: Code of the system(10).
Run end user experiments and examines feedback.(P6)
Descrip on of IOT An -The Product Opera on Process:
Users open the system by entering the password on the keypad
A er entering the password, the system switches to standby mode, ready for monitoring
Step 3: Mo on Detec on
If there is movement, the system ac vates alarm devices such as LED lights and Buzzer speakers
Step 4: Alarm and No fica on
The system sends warning no fica ons to users via devices connected to the internet with the system
The user confirms that they are not the one causing the movement by re-entering the password
If the password is correct, the system unlocks and returns to standby mode
Step 6 : Advanced Protec on Mode
If the user enters the wrong password 3 mes, the system can ac vate protec on mode and send warning messages via buzzer and LED
Step 7 : Management from devices connected to the internet to the system
Users can manage and control the system from devices connected to the internet, including viewing and changing status
The infrared an -the IoT project with devices such as infrared sensors, key pads, LCD screens, LEDs, buzzers, and servos has achieved important and correct func ons as originally expected Here is a conclusion on the effec veness and responsiveness of the main func ons:
Infrared Sensor: This sensor works accurately and reliably in detec ng movement in the monitoring area It helps ac vate the warning system quickly when there is an intrusion
Key Pad: Key pad provides a secure and easy-to-use means of authen ca on to manage access rights Users can easily enter the code to open the door or gate
LCD screen: The LCD screen clearly displays status informa on and warnings, helping users monitor the status of the system
LED and Buzzer: Both LED and Buzzer work effec vely in crea ng alerts, a rac ng a en on and informing users about events that are happening
Servo: Servo ensures safe and flexible control of a door or gate, opening and closing based on user decisions or defined condi ons
In short, the project met and exceeded the ini al requirements of building an IoT an -the system using infrared rays The func ons work together to deliver a comprehensive and flexible security solu on, providing peace of mind and effec ve management for users
Conducting a survey on Google Forms with the active participation of 100 people, we received a positive picture of the anti-theft IoT project using infrared rays Evaluation results from the community showed great satisfaction and support for various aspects of the project Besides, there are also some mixed opinions
Overall, the community has been quite suppor ve of the project, and most users have given it high marks for its func onality, adaptability, performance, flexibility, and user interface These encouraging comments provide us with a lot of incen ve to keep developing and improving the project so that we may best serve consumers.
Reconcile and evaluate end user feedback and determine advantages and disadvantages of your
disadvantages of your chosen IoT techniques (M5)
The infrared anti-theft system project has successfully achieved the initial requirements and brought many important benefits The system not only ensures home safety but also creates a modern and convenient approach to control and monitoring
- Safe and Efficient: The system responds well to detec ng presence using PIR sensors and controlling doors using servo motors, increasing safety and efficiency
- Friendly Interface: Using keypad and LCD screen makes user interac on easy Visual no fica ons on the LCD screen and audible buzzer provide clear informa on
- Blynk Integra on (if available): Integra on with Blynk Cloud provides remote control and system status monitoring via mobile app
- Sensor Accuracy: It is possible that the PIR sensor reacts to environmental noise Improve accuracy by implemen ng filtering and calibra ng sensor thresholds
- Password Spoofing: Ability to spoof by guessing the password Enhance security by adding addi onal verifica on factors such as a PIN or mobile phone confirma on code
- Internet Connec vity: For Blynk integra on, a stable Internet connec on is required Use me synchroniza on so ware and handle unstable connec on situa ons
Upgrade Directions and New Features:
- System Expansion: Integrate additional sensors and components to expand monitoring capabilities, such as temperature sensors, sensor lights, or cameras
- Smart Connection: Upgrade to be able to connect with other smart devices in the smart home system
- Artificial Intelligence (AI) Application: Using AI technology to improve the ability to recognize and predict behavior, improve system efficiency
- The project has achieved many goals and brought many benefits Continuous monitoring, optimization and upgrades are important to stay efficient and up to date with new technology trends
The project has achieved many goals and brought many benefits Continuous monitoring, optimization and upgrades are important to stay efficient and up to date with new technology trends.
Make mul ple itera ons of your IoT applica on and modify each itera on with enhancements
We have created a survey to get customer opinions Overall, 70% of users agree with the system and the remaining 30% disagree with the system Below are some proof images:
User surveys have made it clear that our products receive positive reviews from the majority of users According to the results of the survey, about 70% of users said they felt the product was suitable for their needs and desires
Most users appreciate the robust security features, easy-to-use interaction via keypad and LCD display, and the system's flexibility to provide notifications and remote control These features all meet users' expectations of a modern and convenient anti-theft system
However, about 30% of the remaining users expressed expectations about product upgrades Maybe it's about greater customization, improving sensor accuracy, or adding new features that enhance the user experience This feedback is valuable so we can continue to develop and improve the product to meet the specific expectations and requests from the user community
In total, the diversity of feedback from users is a great source of encouragement for us to continue our efforts to develop products and bring the best value to users
During the explosion of the digital revolu on, the subject of Internet of Things (IoT) has marked an important step forward in understanding and applying IoT technology to everyday life We learned how to build IoT systems, from sensor selec on and connec vity design to data analysis and crea ng prac cal applica ons
We see that IoT is not only a poten al technology field, but also an opportunity to create breakthrough solu ons for the real world The power of IoT lies in its ability to connect and collect informa on from the surrounding environment, thereby helping us be er understand the world and make smart decisions
This subject helped us realize that IoT is not just a field of technology, but also a bright prospect for the future We hope that the knowledge and skills learned from this course will help us par cipate in the IoT revolu on and contribute to building a smarter and more convenient world
During our me in the Internet of Things (IoT) course, we were immersed in a world full of connec vity and automa on This has helped us expand our knowledge and evaluate a wide range of IoT-related concepts and technologies Exploring IoT sensors, networks, communica on protocols, and data analy cs has us feeling excited and ready to explore more
The prac cal part of the course was really interes ng We had the opportunity to build and program real IoT systems This not only helps us apply our knowledge in prac ce, but also helps us be er understand how to interact and work with IoT devices
Equally important, the teaching and support staff were always ready to support us throughout our learning journey They have enabled us to gain a deeper understanding and confidence in IoT The course posed many construc on challenges We have faced and solved real problems, from connec ng sensors to crea ng remarkable solu ons This has mo vated us to think crea vely and develop prac cal skills
In total, the IoT course gave us a valuable and enlightening experience We hope that the knowledge and skills learned from this course will be the founda on for us to par cipate in the IoT revolu on and create exci ng applica ons in the future.