ABSTRACT
Manualization of the gas station management system allows a lot of shortcomings and challenges which could hinder proper inventory management, lead to theft and also give rise to inaccurate value report of the product dispensed and remaining underground. This led to an extensive research to develop a functional device to device communication technology to automate and enhance gas station management system. A well-crafted algorithm was developed for communicating, computing and relaying of data for the system. The control program codes was realized using C programming language. The developed program was integrated with the ATMEGA 328 Microcontroller using Arduino as the integrated development environment (IDE). A backend for the information gathering in real time using MySQL was developed and the developed microcontroller, ultrasonic sensor device and the WIFI module were all integrated using CORBRA protocol. The prototype as a proof of concept was finally developed. The methodology that was implemented in the project development is the object oriented methodology and prototyping methodology. The ultrasonic sensor (HC-SRO4) was used to get data from the tank by SONAR to determine the volume of the product in the bucket. ATMEGA 328 microcontroller was used as a medium to convert the data received from the ultrasonic sensor and sends it to the WI-FI module. The WI-FI module is an interface between the Hardware and the web application where the data received can be seen and remotely monitored using LARAVEL. The system measures fuel or product volume, gives the equivalent price value of the quantity sold and the price and volume remaining. The system allows for automated analysis and monitoring of product level which will enhance the gas station management process.
TABLE OF CONTENTS
Title page i
Declaration ii
Certification iii
Dedication iv
Acknowledgements v
Table of Contents vi
List of Tables x
List of Figures xi
List of Plates xiii
Abstract xiv
CHAPTER 1: INTRODUCTION
1.1 Background of Study 1
1.2 Problem Statement 5
1.3 Aim and Objectives 6
1.4 Justification of the Study 7
1.5 Scope 7
CHAPTER 2: LITERATURE REVIEW 8
2.1 Historical Background 8
2.2 Device-to-Device Communication 9
2.2.1 Microcontroller 10
2.3 Automation Concepts 11
2.4 Programmable Logic Controller 13
2.4.1 Functions of a programmable logic controller 13
2.4.2 PLC programming types 17
2.5 Human Machine Interface 19
2.6 M2M Eco System 20
2.7 D2D Communication and Network Coding 21
2.7.1 D2D support in cellular network 21
2.7.2 Cooperative D2D communication 22
2.8 Formation of Device 22
2.9 Classification of D2D Communication 22
2.9.1 Inband communication 23
2.9.2 UderlayInband D2D mode 23
2.9.3 Overlay Inband D2D mode 25
2.9.4 Outband D2D communication 25
2.9.5 D2D outband communication: controlled mode 26
2.9.6 D2D outband communication: autonomous mode 27
2.10 M2M Support in Wireless Networks 27
2.10.1 M2M support in cellular networks 28
2.10.2 M2M drivers 28
2.10.3 Capillary network 29
2.10.4 M2M gateways 29
2.11 Related Works 30
2.11.1 Literature gap 34
CHAPTER 3: MATERIALS AND METHODS 35
3.1 Materials 35
3.2 Ultrasonic Sensors. 36
3.2.1 The monitoring system with ultrasonic sensor 41
3.2.2 Data processing 44
3.3 Microcontroller. 46
3.3.1 The basic structure and block diagram of a microcontroller 48
3.3.2 Features of ATmega328 49
3.4 WIFI MODULE. – ESP8266 49
3.4.1 Write data to EEPROM 52
3.5 Methodology 53
3.6 System Description 54
3.6.1 System Hardware 54
3.6.2 Interfacing HC-SRO4 ultrasonic sensor with the microcontroller 56
3.7 Arduino UNO 57
3.7.1 Programming microcontroller for UART communication 58
3.7.2 Initializing the UART module of the microcontroller 58
3.7.3 Transmitting data using UART 60
3.7.4 Receiving data using UART 62
3.8 System Software 63
3.9 System Design 63
3.10 Tank Prototyping 63
3.11 Software Algorithm 65
3.12 System Algorithm 66
3.13 Hardware Design 67
3.14 System Architecture 68
CHAPTER 4: RESULTS AND DISCUSSION 70
4.1 Results 70
4.2 Requirement 71
4.2.1 Quick design 71
4.2.2 Build prototype 71
4.3 The Principle of Measurement 71
4.4 Prototype 75
4.5 Web Application Implementation 75
4.6 Register 77
4.7 System Testing 80
CHAPTER 5: CONCLUSION AND RECOMMENDATION 81
5.1 Conclusion 81
5.2 Recommendation for Future Work. 82
5.3 Contribution to Knowledge 82
References
LIST OF TABLES
3.1: Ultrasonic pin Configuration 37
4.1: Information gathered from clients 48
4.2: Frequencies on some questions pertaining to problems faced by Total Petroleum Fuel station 71
LIST OF FIGURES
2.1: Block Diagram showing the system Architectural Gap 12
2.2: Programmable Logic Controllers. 14
2.3: An Opto-Isolator 14
2.4: PLC Wiring Output 15
2.5: Categories of Sensors 16
2.6: Liquid Level Sensor Circuit 16
2.7: Simple Relay Circuit 18
2.8: A Simple Relay Controller 18
2.9: Seal in Circuit 19
2.10: A Schematic of Human Machine Interface 19
2.11: LabkoMonitor 8 monitoring system 30
3.1: Ultrasonic sensor hc-SRO4 36
3.2: Ultrasonic wave transmission 38
3.3: HC-SR04 Ultrasonic Sensor - Working 39
3.4: Ultrasonic sensor interfaced with the Arduino 41
3.5: Ultrasonic sensor showing ECHO reception on surface 44
3.6: Circuit diagram for the Arduino and Ultrasonic sensor interface. 45
3.7: ATMEGA Microcontroller chip. 47
3.8: ATMEGA 328 Microcontroller Structure 48
3.9: WI-FI Module ESP8266 50
3.10: ESP8266-01 Module Pin Description 52
3.11: Simple Block Diagram of the System Flow. 54
3.12: Pulse for Ultrasonic sensor “HC-SR04 55
3.13: Arduino UNO 57
3.14: Flow chart Software Implementation in the Microcontroller 67
4.1: Prototyping Model 70
4.2: Sensing the Process 74
LIST OF PLATES
1: Picture of ATmega328 Microcontroller used in the prototype. 73
2: Picture of Ultrasonic sensor used in the prototype. 74
3: Initial Page of the Webpage developed 76
4: he Registration page 76
5: Log In Page. 77
6: Error Page. 78
7: Data Acquisition page 78
ABSTRACT
Manualization of the gas station management system allows a lot of shortcomings and challenges which could hinder proper inventory management, lead to theft and also give rise to inaccurate value report of the product dispensed and remaining underground. This led to an extensive research to develop a functional device to device communication technology to automate and enhance gas station management system. A well-crafted algorithm was developed for communicating, computing and relaying of data for the system. The control program codes was realized using C programming language. The developed program was integrated with the ATMEGA 328 Microcontroller using Arduino as the integrated development environment (IDE). A backend for the information gathering in real time using MySQL was developed and the developed microcontroller, ultrasonic sensor device and the WIFI module were all integrated using CORBRA protocol. The prototype as a proof of concept was finally developed. The methodology that was implemented in the project development is the object oriented methodology and prototyping methodology. The ultrasonic sensor (HC-SRO4) was used to get data from the tank by SONAR to determine the volume of the product in the bucket. ATMEGA 328 microcontroller was used as a medium to convert the data received from the ultrasonic sensor and sends it to the WI-FI module. The WI-FI module is an interface between the Hardware and the web application where the data received can be seen and remotely monitored using LARAVEL. The system measures fuel or product volume, gives the equivalent price value of the quantity sold and the price and volume remaining. The system allows for automated analysis and monitoring of product level which will enhance the gas station management process.
CHAPTER 1
INTRODUCTION
1.1 BACKGROUND OF STUDY
Storage tanks are artificial containers that hold liquids, compressed gases (gas tank) or mediums used for the short- or long-term storage of hot or cold. Large ground storage tanks filled with hydrocarbon and hazardous liquids such as oil, oil derived products, chemicals and process plant liquids are in widespread use in the UK, Europe and throughout the world. The tanks are generally spread across a large area and use manual detection and measurement methods which are still under development. This makes it more laborious and time consuming to monitor the tank levels (Ebere and Francisca, 2013). Remote monitoring and data collection systems are necessary to collect information from the tanks and monitor the same. So it is necessary to build a system which can be accurate, fast in measurement and simple to install and handle, but has an intelligence which takes decisions in real-time and alerts and communicates when necessary. The data acquisition is done by the sensors used to sense the changes in the liquid level of the tank and is stored in the system’s memory. A server collects the information sent from the onboard microcontroller through a Global system for Mobile communication (GSM) modem in the tank; saves it to a database and displays it on a website graphically. Such intelligent monitoring systems help in effective management of tanks, by assessing the status of the tanks periodically allowing optimized logistical supply of product and minimized inventory holding (Islam and Wasi-ur-Rahman, 2009).
Efficient utilization of the low power modes of the microcontroller reduces power consumption and extends the longevity and reliability of the system with less maintenance cost. Innovative solutions to tackle emergency applications need to be designed for critically sensitive application and can be achieved by developing effective embedded software, Wireless Sensor Network (WSN) architectures and communication protocols, which are robust, thereby increasing the lifetime of the network (Rosolem et al.,2013). Analog to Digital Converters (ADC’s) can be used to interface the sensors, which are used in data acquisition and sensing the parameters, to help in building sensor interface to the control unit (microcontroller). The collected data will need to be wirelessly transmitted and that can be done by using WSN services which introducing low power and low cost features (Shakah and Imran, 2013).
Scalability is another important parameter that determines the longevity of the system. A system thus developed should be scalable without major changes to the working system. There are systems which have been implemented for specific liquids like water. Typically, the measurements of liquids are done using various sensors which need physical contact with the liquid. These might induce wear and tear and introduce maintenance costs and decrease the longevity of the system (Ebere and Francisca, 2013). Ultrasonic sensors can be used to sense the liquid level by placing the sensors at a specified portion in the tank, calculating the level of liquid by time of flight of the ultrasonic wave and correlation with respect to the dimension of the tank, to get a more accurate value. The values thus collected needs to be sent to a server using a wireless communication medium, so that this can be correlated at the server for display on the tank software system. The data collected at the server end is displayed on a Graphic User Interface , thus communicating to the user about the level of liquid, in real time and also evaluating the variation of liquid levels over a period of time. This would accommodate efficient storage, dispensing of liquids and chemicals inside the tanks (Johari et al., 2011).
A GSM technology is used; it helps the system to be installed in industries, liquid storage fields, oil-tank and trucks. These measurements are sent to a server via a GSM module through WIFI. The WIFI is activated and the Transmission Control Protocol/Internet Protocol (TCP/IP) sockets are used to communicate to and from the server. The server stores the values in memory and ensures that fluid inventory levels are maintained, and helps in identifying problems such as tank leaks and fluid theft. The various components of the system includes an ultrasonic sensor, a microcontroller which contains the processor and the analogue to digital converter to measure the temperature and the GSM module used to connect to the server. The processing of the sensor data is done by the microcontroller and communicates to the server periodically as defined during installation (Doppler et al., 2009).
In recent years, collaborative communication between numerous intelligent systems through either mobile or fixed networks has achieved significant importance. One of the resultant emerging domains is mobile Device-to-Device(D2D) communication. D2D communication describes a communication style in which two or more entities such as devices/machines communicate with each other autonomously. In this new era, new technologies come to play and new innovations and creative thinking comes to enhance and help develop our daily activities in order to make life easier and more convenient. In the olden days people mostly worked within circles but now, technology is developing day by day to reduce the workload on human as well as time taken to complete the work (ETSI,2013).
This thesis discusses the automation of fuel retail station outlet to maximize the efficiency of the management system as a whole. This system will give the sales and stock report to the owner for every hour or at the end of the day, depending on what is desired by the owner. This is to enable the owner or chief executive officer to monitor and manage this fuel retail stations. Machine to Machine communication is a new communication technology whereby a large number of “intelligent devices” can autonomously communicate with each other and make collaborative decisions without direct human intervention, in a bid to achieve better cost efficiency and time management (Igarashi et al.,2012).
Machine-to-Machine (M2M) communication has its origin in the supervisory control and data acquisition (SCADA) systems, where sensors and other devices connected through wired or radio frequency networks are used with computers to monitor and control industrial processes. The use of IP-connected devices such as sensors, monitors, and actuators, in homes and in the industries, has enabled the growth of new interconnected, inter-operable services, which are designed to improve our daily lives. Exploiting multiple novel sources of information, the M2M technologies present a number of applications, sometimes known as “Internet of Things”(IoT).
Device-to-device (D2D) communications involve machines communicating with each other and exchanging information with remote servers, possibly over a cellular network infrastructure. Such technologies are considered as key enablers for next generation smart cities and homes, automated factories and other integrated commercial environments. One of the main aims of such communication techniques is to enable smart city solutions, like intelligent metering, infrastructure management, city automation, and automated health management systems (Min and Lee, 2011).
Internet of things (IoT) is the fastest growing platform nowadays for connecting all hardware modules like sensors, electronics, and devices together. These embed were with software thereby making our own creative devices applications. With the help of this technology we create the web applications that enable us to remotely view the values of temperature, density, moisture and light level of lamp status as well as download the report of sales. This thesis enables the fuel retail outlet owners to make service easier and to take a look at current status of stock easily from a remote location. With this application, the owners check the past sales record, stock of the fuel and sales for the day. Once they log in, they can access or check the current stock, temperature of the liquid/fuel and then at service level it helps reduce fuel theft.
Business also can use D2D communications for tracking inventory and security. Mobile standards are foreseen to play a prominent role in the successful deployment of numerous D2D applications due to several reasons, e.g., high capacity to support a large number of devices, enhanced coverage, low power consumption, high reliability, low cost modules, as well as easy and short-term deployment opportunities (Taleb and Kunz, 2012). D2D services are considered as one of the main motivations behind the tremendous growth in mobile traffic.
Device-to-Device communication technology is a very important and essential tool which can be used to automate and enhance the process in gas station management. Devices such as the Ultrasonic sensor (HC-SRO4), microcontroller (ATMEGA328), WI-FI module (ESP8266) will be used. These devices communicate independently and work together as a unit. The ultrasonic sensor acquires the data readings from the tank and sends to the connected microcontroller which converts the received data and sends to the WI-FI module. The WI-FI module which interfaces the hardware to the web application sends the readings to the server. The server which was developed using PHP displays the reading on the screen. With the effective communication of these devices, the entire process of monitoring the operations can be achieved effectively (Noura and Nordin, 2016).
1.2 PROBLEM STATEMENT
Manualization of the gas station management system allows a lot of shortcomings and challenges which could hinder proper inventory management, lead to theft and also give rise to inaccurate value report of the product dispensed and remaining underground. Some of the problems are listed below:
i. LACK OF PROPER INVENTORY MANAGEMENT: Most Gas stations in Nigeria lack proper inventory management of both inflow and dispensing of products as well as the ability to determine net worth of products in stock.
ii. THEFT: Gas stations in present times suffer from theft from workers in the gas stations due to inappropriate monitoring and assessment of products in the gas station.
iii. INACCURATE VALUE REPORT: When the gas is dispensed into the tanks underground, most times a calibrated rod is used to dip into the tank to know the quantity of product discharged into the tank, most times the operations are inaccurate.
iv. INABILITY TO REMOTELY MONITOR INFORMATION. Owners of gas stations find it difficult to certify accurately the quantity of product underground from different locations.
1.3 AIM AND OBJECTIVES
The aim of this research is to design and implement an improved Gas station management system deploying device to device communication technology. The objectives of this project are:
i. To develop an algorithm that communicates, computes and relay data for the system.
ii. To develop and realize the algorithm in codes using C program.
iii. To integrate the developed program with the ATMEGA 328 Microcontroller using Arduino as the Integrated Development Environment (IDE).
iv. To develop the backend for the information gathering in real time using MySQL
v. To integrate the developed microcontroller , ultrasonic sensor device and the WIFI module using CORBRA protocol.
vi. To develop a prototype as a proof of concept
1.4 JUSTIFICATION OF STUDY
The fuel station or gas station as it is called in some part of the world is fast growing and as always been an important technological tool due to its role in driving the machines and also our other daily needs. The fuel station is all encompassing as it also deals with other products such as kerosene and Automotive Gas And Oil (AGO), diesel. Automation and better management is really necessary judging from the high rate of mismanagement of funds and also lack of good calibration system and proper monitoring. Most systems being developed does not really cater for proper monitoring and close measuring of products. This research aimed at increasing the maintenance and monitoring level of the system by using the proper tools and materials such as sensors, advanced web applications. This research work is geared towards making the owners of gas stations able to be at peace and also know that their business is safe and properly handled. Imagine when you have a business and you are able to monitor and also know about the progress, loss, profits and shortage. This would really enable lots of peace of mind. With the help of this research we hope to improve and enhance the already existing fuel station system.
1.5 SCOPE
Through a comprehensive examination of Gas station management system, it involves both hardware, software and firmware implementation and deployment. This thesis focused on the improvement of gas station management system by integrating, interfacing and deploying of devices in other to implement device to device integrated system. The scope of this work is limited to configuring the microcontroller and integrating to the web application module.
Click “DOWNLOAD NOW” below to get the complete Projects
FOR QUICK HELP CHAT WITH US NOW!
+(234) 0814 780 1594
Login To Comment