You are on page 1of 65

Hybrid Power Supply with Fuzzy Logic Control System for Irrigation

A Capstone Project

Presented to

The Faculty of the Electronics Engineering Department

College of Engineering and Architecture

Iloilo Science and Technology University

La Paz, Iloilo City

In Partial Fulfillment

of the Requirements for the Degree

Bachelor of Science in Electronics Engineering

John Albert A. Anzures

Catherine D. Balano

Ivy Jude P. Gabales

June 2023
ii

ILOILO SCIENCE AND TECHNOLOGY UNIVERSITY


La Paz, Iloilo City
COLLEGE OF ENGINEERING AND ARCHITECTURE

APPROVAL SHEET

This study entitled, “Hybrid Power Supply with Fuzzy Logic Control
System for Irrigation” prepared and submitted by Mr. John Albert Anzures, Ms.
Catherine Balano, and Ms. Ivy Jude Gabales in partial fulfillment of the
requirements for the degree BACHELOR OF SCIENCE IN ELECTRONICS
ENGINEERING is hereby recommended for Oral Defense.

RAMON A. ALGUIDANO JR., DIT, PECE


Adviser

Passed the Oral Defense on June 9, 2023

PANEL OF EXAMINERS

Approved by the Committee on Oral Defense with a grade of PASSED.

NACI JOHN C. TRANCE, PECE


Chair

SANTOS EMMANUEL JAMES C. MALUNDA, ECE


Member

Accepted in partial fulfillment of the requirements for the degree BACHELOR


OF SCIENCE IN ELECTRONICS ENGINEERING.

PHILIP LLOYD E. LEGADA, ECE ROWENA P. CALASARA, Ph. D.


Department Head Dean, CEA
iii

Acknowledgement

The researchers would like to express their sincere gratitude to the


following individuals who have contributed to this study and have lent a helping
hand when the researchers needed it:

To the researchers' friends, classmates, and parents for their financial


assistance, motivation and inspiration, love, and support during their stressful
research periods;

To Engr. Ramon A. Alguidano Jr., researchers’ Research Adviser for his


excellent expertise, recommendations, guidance, and good rendition in critiquing
the study to create a favorable result;

To Engr. Naci John C. Trance, the faculty in charge in Capstone Project


2, for his guidance, patience, and encouraging comments, as well as for assisting
the researchers in realizing a more effective way to presenting their research's
data;

To Engr. Santos James Emmanuel C. Malunda, for his willingness to


support the researcher’s success in their research as well as his significant
knowledge and recommendation for improvement;

Most of all, To Almighty God who acquaints the researchers’ mind and
heart in the competitive part of our study and for his blessings in making this
study to succeed.

John Albert Anzures


Catherine D. Balano
Ivy Jude Gabales
iv

Hybrid Power Supply with Fuzzy Logic Control System for Irrigation

John Albert A. Anzures 1, Catherine D. Balano 2, Ivy Jude P. Gabales 3

1
johnalbert.anzures@students.isatu.edu.ph,
2
catherine.balano@students.isatu.edu.ph,
3
ivyjude.gabales@students.isatu.edu.ph
Iloilo Science and Technology University
La Paz, Iloilo City, Philippines

Abstract

Hybrid power supply has gained attention in irrigation system to


address the demand on efficient and sustainable need on power supply.
Traditional power sources such as reliant on grid or diesel faces a lot of
challenges. For this reason, the design of a Hybrid Power System with
Fuzzy Logic Control for Irrigation was conducted. The system employed
with Fuzzy Logic Control System and implemented in a microcontroller
unit. A solar Irradiance sensor is incorporated in the system to measure
the raw data based on the solar irradiance and was based on closed-loop
control. The input of a controller was the irradiance error with
membership functions of: IR(zero), IR(low), IR(mid), and IR(high) with
Duty Cycle of zero, low, average, and max membership functions as the
output. Researchers calculated a 240 watts/m2 irradiance threshold for
power compensation, and tested the system using an irradiance sensor
and handheld solar power meter. The actual result testing was the basis
in computing and assessing the accuracy and reliability of the hybrid
power system. The software and hardware design were successfully
implemented with acceptable accuracy and reliability thus, could possibly
help farmers in maintaining their irrigation through having uninterrupted
and cost-friendly hybrid power source system.

Keywords: Hybrid, Solar Irradiance, Irrigation, Power Compensation


TABLE OF CONTENTS

Title Page i

Approval Sheet ii

Acknowledgement iii

Abstract iv

A. INTRODUCTION 1

Background of the Study 1

Statement of the Problem 4

Objectives of the Study 4

B. METHODOLOGY 5

C. RESULTS AND DISCUSSION 19

D. CONCLUSION 38

E. RECOMMENDATIONS 38

F. REFERENCES 39

G. APPENDICES 42

H. PROFILE OF THE GROUP MEMBERS 58


1

Hybrid Power Supply of Irrigation with Fuzzy Logic Control System

A. Introduction

In recent years, the demand for efficient and sustainable power supply
solutions for irrigation systems has been on the rise. Traditional power sources
such as grid electricity or diesel generators often face challenges like high
operating costs, limited availability, and environmental concerns. As a result,
there has been a growing interest in developing alternative power supply
solutions, and one promising approach is the integration of hybrid power systems
with fuzzy logic control.

The research focuses on the design and building of a Hybrid Power Supply
of Irrigation with Fuzzy Logic Control System using a microcontroller and a
Solar Irradiance sensor. The study aims to design a hybrid power source
irrigation system, design, simulate and implement a fuzzy logic controller for the
hybrid power source, and test the functionality of the hybrid power source
irrigation system. Fuzzy logic in irrigation systems can benefit farmers, rural
communities, governments, and future researchers by increasing crop yields,
reducing greenhouse gas emissions, and improving energy security.

A.1 Background of the Study

The use of hybrid power systems in irrigation systems has gained attention
due to the increasing demand for food and the need to ensure sustainable farming
practices. A hybrid power system is a combination of two or more power sources,
such as solar, wind, diesel, or grid that work together to provide reliable and
cost-effective power supply. A study conducted by the International Rice
Research Institute (2016) found that the use of solar-powered irrigation systems
in the Philippines can increase rice yields by up to 40% while reducing water
usage by up to 30%. A study conducted by the Philippine Center for Postharvest
Development and Mechanization (2018) found that the use of hybrid solar-diesel
irrigation systems can provide a reliable and cost-effective power supply in
remote areas where access to the grid is limited.
2

The Fertile Crescent was the birthplace of agriculture, writing, and


monotheistic faiths, and early farmers in the Fertile Crescent diverted water to
dry fields whenever they had a chance. Hybrid power systems have been around
for several decades and have gone through significant changes over time
(Koutsoyiannis, 2004). The origins of hybrid power systems came from the idea
of combining diverse power sources to produce a more efficient and dependable
system, which dates back to the Industrial Revolution (Laconte, 2007). Early
examples of hybrid power systems include the diesel-electric locomotive and the
Toyota Prius. Recent developments in hybrid power systems include the use of
hybrid systems in renewable energy applications, such as wind and solar power,
and Fuzzy Logic Controllers (Fayed and Mahmoud, 2007).

Fuzzy logic controllers are a type of control system that uses fuzzy logic to
approximate human reasoning and decision-making. They have been used in a
wide range of applications, from industrial automation to consumer electronics.
The concept of fuzzy logic was first introduced by Lotfi Zadeh in 1965, and the
origin of the fuzzy logic controller was developed by Mamdani and Assilian in
1975. This study aims to provide a brief history of fuzzy logic controllers, from
their origins to their current state of development. Advances in fuzzy logic
controllers have highlighted the importance of neural networks and genetic
algorithms in optimizing the performance of fuzzy logic controllers. Fuzzy logic
controllers in combination with PID controllers (Tanaka and Sugeno, 1992) can
provide the benefits of both types of controllers, resulting in more efficient and
effective control systems.

Additionally, the study conducted by Hinokuma et al., (2021) use of fuzzy


logic controllers in combination with other types of controllers can provide the
benefits of both types of controllers and result in more efficient and effective
control systems. Techno-Economic Analysis of a Fuzzy Logic Control Based
Hybrid Renewable Energy, particularly its intermittent nature, suggests that
hybridization of variable renewables can overcome these challenges. The
researchers employ optimization techniques like particle swarm optimization
(PSO) and evaluate system configurations and operation schedules. Solar
Irradiance measurement meter is an important tool for successful solar
operations, and is usually done using a Pyranometer. This paper investigates the
connection and develops a theoretical and laboratory measurement guide for
converting solar irradiance to illuminance (Gupta, S., 2021).
3

In the study conducted by Michael et al., (2020) the standards data,


equipment calibration accuracy, and uncertainty estimations are all included in
the conversion factor. For an LED-based solar simulator, the solar irradiance of 1
Sun (1000 W/m2) is (116 3) klx and (122 1) klx for outdoor sunlight.

The study of Mekonnen, G. T. et al., (2021) provides a comprehensive


review of hybrid renewable energy systems suitable for irrigation in developing
countries. It reviews solar-wind, solar-diesel, and wind-diesel systems and
discusses their technical and economic feasibility. A hybrid solar-battery powered
irrigation system for smallholder farmers in Sub-Saharan Africa is designed to
provide reliable irrigation and improve crop yields and livelihoods. A hybrid
power supply system with fuzzy logic controller is presented to perform fast
changes in energy use from different energy sources. Hybrid power systems are
becoming increasingly popular due to their potential for energy sustainability.

The primary goal of integrating a hybrid power source using fuzzy logic in
irrigation systems is to compensate the power source if the main energy supply is
not enough due to low irradiance with the aid of a back-up power supply
connected to the grid and this will ensure continuous irrigation process. The data
coming from solar irradiance sensor is used as a basis to make decisions and
power supply management process.

Hence, the researchers designed a hybrid power source using fuzzy logic
controller for the irrigation systems. It is expected that further research and
development in this area will lead to effective and efficient system as well as
increased adoption of hybrid power sources and improved irrigation practices in
the future.

Based on the gathered data, most of the study in term of hybrid power
source use renewable energy like solar and wind. Our study entitled hybrid power
supply of irrigation with a fuzzy logic control system holds significant
implications when compared to other research in the field. This study's
significance lies in its focus on enhancing energy efficiency, reducing
environmental impact, optimizing resource allocation, ensuring system reliability,
and contributing to technological advancements. By addressing these aspects, it
adds valuable insights and potential solutions to the existing body of knowledge
on hybrid power supply and irrigation systems with fuzzy logic.
4

A.2 Statement of the Problem

The current irrigation systems rely predominantly on conventional power


sources, such as electricity from the grid or diesel generators, which may lead to
high operational costs, dependency on fossil fuels, and limited flexibility. To
address these challenges and explore more sustainable alternatives, there is a
need to develop a hybrid power source for irrigation systems that integrates
renewable energy sources, such as solar or wind power, with conventional power
sources. Additionally, the irrigation system requires an intelligent control system
to optimize the utilization of the hybrid power sources based on the dynamically
changing energy availability and irrigation demand.

The problem at hand is to design and implement a hybrid power source


for an irrigation system that intelligently integrates renewable and conventional
energy sources, ensuring reliable and cost-effective operation while minimizing
environmental impact. This system should also incorporate a fuzzy logic control
system that can effectively manage and balance the power generation and
irrigation requirements, considering factors such as solar energy availability and
weather conditions. The goal is to achieve improved energy efficiency, reduced
operational costs, enhanced sustainability, and optimized irrigation performance
through the integration of a hybrid power source and a fuzzy logic control system
in the irrigation system.

A.3 Objectives of the Study

The research primarily focuses on the design and building of a Hybrid


Power Supply for Irrigation with Fuzzy Logic Control System using a
microcontroller and a Solar Irradiance sensor that enables to supply the required
power for the pump.
5

Specifically, the study aims to:

1. design a hybrid power source for an irrigation system;


2. develop fuzzy logic control, assign membership function and generate
fuzzy rules for the hybrid power source;
3. design, simulate and implement a fuzzy logic controller for the hybrid
power source; and
4. test and evaluate the accuracy, reliability and functionality of the
system.

B. Methodology
This section presents the design of the study, sources of data, project
design, construction procedures, data gathering instrument, data gathering
procedure and data processing technique.

B.1 Design Criteria

For the design to be considered effective, it must fulfill the following


requirements.
Accuracy of Irradiance Sensor. The study should ensure that the
irradiance sensor used in the hybrid system is accurate and reliable. The sensor
should be able to measure the amount of solar radiation received accurately, and
the readings should be verified against established industry standards.
Accuracy of Fuzzy Logic Controller. The study should ensure that the
fuzzy logic controller used in the hybrid system is accurate and reliable. The
controller should be able to analyze the data from the irradiance sensor and
control the energy output of the system accurately.
Reliability of Hybrid System. The study should ensure that the hybrid
system is reliable and able to operate continuously for extended periods without
any issues. The system should be tested under various weather conditions and in
different environments to demonstrate its reliability.

B.2 System Design

In the irrigation system, having an adequate power source for powering


the pump is crucial for efficient irrigation and proper hydration of crops and for
the pump to operate optimally. Sufficient power supply ensures that the pump
6

can operate at its intended capacity, delivering the necessary water volume and
pressure required for effective irrigation practices. In many regions, where the
main source of living is farming are having problems with power outages which
resulted to system downtime and lack of backup during peak demand resulting in
halted or delayed irrigation operations and potential crop and pump damage. The
experimental study is designed and conducted in this paper using an irradiance
sensor, and a Fuzzy Logic Control System incorporated in the whole circuitry to
provide farmers with solution to the identified problem in the irrigation system
by the means of hybrid power source.

Figure 1

Block Diagram of the System

Figure 1 shows the flow of signal in the system. The system is composed of
a hybrid power source that utilizes solar and AC power supplies. The output
power of hybrid source essentially depends on the solar energy, which will be the
primary energy source and a stand-by 220 Volt AC power supply as a
compensating power source. A solar irradiation sensor is incorporated in the
7

system to measure the raw data based on the solar irradiance in which the data
is then passed to microcontroller to serve as an input to the fuzzy inference
system to produce the output which is the compensation of power supply needed
to power the pump. Two diodes will be use as a blocking diode to limit the flow
of current. The compensation of power source will be based on the voltage needed
by the BLDC pump to operate which is rated 12 Volts, 1 Ampere.

B.3 Implementation Procedure

The design of the system includes the mechanical, electronics, and


software design of the system.

Figure 2

Process Flow Chart of Hybrid Power Supply for Irrigation System with Fuzzy
Logic Control
8

Figure 2 shows the flowchart for the integration of hardware and software
design to construct the device. The mechanical design focuses on the hybrid
power sources and the irrigation system for application, electronic design for the
circuitry, and the software design focused on the integration of fuzzy logic control
system in the Arduino Uno program and the integration of solar irradiance sensor
to Arduino Uno microcontroller.

B.4 System Design Procedure

The researchers designed and integrate a fuzzy logic system into a hybrid
power source with solar irradiance as an input that involves designing the fuzzy
logic controller, defining linguistic variables and membership functions, creating
fuzzy rules, and implementing the inference mechanism.

Figure 3

Fuzzy Logic Systems

In Figure 3, the input and output variables are defined. The output
variable could be a control signal to determine the power compensation (solar or
backup AC) and defined the appropriate input and output ranges and units for
the fuzzy logic system. The input variable is divided into linguistic variables that
represent different levels of sunlight, such as “zero”, “low”, “medium”, and
“high”. Assign appropriate membership functions to these linguistic variables,
which capture the relationship between the input value and its membership to
each linguistic term (e.g., triangular or trapezoidal membership functions). A set
of fuzzy rules is created to define the relationship between the input and output
9

variables and apply the fuzzy rules to make decisions based on the current input.
The researchers used Mamdani inference mechanisms to determine the output
based on the input's linguistic terms and the defined fuzzy rules. This process
involves fuzzification (mapping the crisp input value to fuzzy values), rule
evaluation, and defuzzification (converting fuzzy output to a crisp value). After
that the fuzzy logic system is tested with different solar irradiance values and
evaluates its performance in selecting the appropriate power source.

B.5 System Design Procedure

The researchers designed a fuzzy-based closed loop control systems,


generate the membership functions and rules of the fuzzy logic system.

B.5.1 Fuzzy Logic Controller Membership Function

Table 1
Input and Output Variables

Input Variable
ERROR IRRADIANCE in W/m2
ZERO Low Medium High
Rule 1 Rule 2 Rule 3 Rule 5
(0-112.5) (112.5-225) (225-337.5) (337.5-450)

Output Variable

Duty Cycle in Percent (%)

Zero Low Average Maximum

0%-25% 25%-50% 50%-75% 75%-100%

Table 1 represents the relationship between one input and one output to
the membership function and fuzzy rules. The error between the sensor value and
the setpoint value is the fuzzy inference system input.
10

In fuzzy logic, a membership function defines the degree to which an


element belongs to a particular fuzzy set. It is a mathematical function that maps
the values of an input variable to a membership value between 0 and 1,
indicating the degree of membership in the fuzzy set. For example, one of the
input error membership functions for any variable could be Zero (Z), Low (L),
Medium (M), and High (H). The membership functions input and output can be
expressed in triangular, trapezoidal, sine, or even gaussian functions.
The fuzzy rule is the rules can be a joint relation between the two-
membership function or a single joint membership function. The value and level
of the input and output membership functions depends on the data. The output
of each fuzzy rules was determined based on this input membership functions.

B.6 Hardware Specifications

The hardware implementation is divided into two parts; the mechanical


and electronic design. The mechanical design shows the physical view of the
hybrid power source and the irrigation system. The electronic design shows the
electrical connections of the electronic devices.

B.6.1 BLDC Pump Specifications

The specifications of the BLDC Pump are shown in Figure 4 below.

Figure 4

BLDC Pump and Specifications

Specification:
Name: Solar Water pump
Material: Plastic
Color: Black
Inlet/Outlet: 1/2” male thread
Voltage: 12V DC
Maximum Rated Current: 1000MA
Power: 19W
Max Flow Rate: 800 L/H
Max Water Head: 5m
Max circulating water temperature: 100°C
Size: About 66.25x47.25x78.7mm
11

B.6.2 Panel Specifications

The specifications of the solar panel are shown in Figure 5 below.

Figure 5

Solar Panel Specifications

B.6.3 Solving Panel Area

To calculate the area of a solar panel with given dimensions;


𝐴𝐴 = 𝑙𝑙 𝑥𝑥 𝑊𝑊 (“The Ultimate Guide to Solar Panel Calculation,” 2023).

B.6.4 Solving for Panel Efficiency Factor

Solar panels can typically convert 15% to 22% of solar energy into usable
energy, depending on factors such as installation, orientation, weather conditions,
and so on. The quantity of sunshine that solar panel systems can convert into
actual power is referred to as performance, and the outcome defines solar panel
efficiency. Based on the related study, the efficiency of a solar panel is
determined by its area rather than its power (How to Calculate Solar Panel
Efficiency, 2019).

𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 (𝑖𝑖𝑖𝑖 𝑘𝑘𝑘𝑘)


𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸 = 𝑥𝑥100%
𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 𝐿𝐿𝐿𝐿𝐿𝐿𝐿𝐿ℎ𝑡𝑡(𝑖𝑖𝑖𝑖 𝑚𝑚) 𝑥𝑥 𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 𝑊𝑊𝑊𝑊𝑊𝑊𝑊𝑊ℎ(𝑖𝑖𝑖𝑖 𝑚𝑚)
12

B.6.5 Solving for Solar Irradiance Threshold Value for the Load

To determine the amount of solar irradiance, first the power consumption


of the pump should be calculated using the formula;

Power (in watts) = Voltage (in volts) × Current (in amperes)


(“DC Circuit Power Calculator,” n.d.)

Solar panels are rated in terms of their maximum power output under
standard conditions, which is typically given in watts peak (Wp). To estimate
the solar irradiance required, you can assume an efficiency factor that takes into
account losses in the solar panel and energy conversion. To determine the solar
irradiance needed, use the following formula:

Solar Irradiance (in W/m²) = Power / (Efficiency Factor × Area)


(Ahmed, 2013).

B.6.6 Making a Solar Irradiance Measurement Meter

The input needed for fuzzy inference system is coming from solar
irradiance which is the amount of solar power per unit area that is received at a
given location on Earth. It is typically measured in watts per square meter
(W/m2) and can vary depending on factors such as time of day, season, latitude,
and weather conditions.

Figure 6

Solar Irradiance Measurement Circuit


13

The BH1750 is a digital light sensor that can be used to measure the
intensity of ambient light in lux. In an irradiance measurement meter, the
BH1750 can be used to measure the amount of solar irradiance that is hitting a
solar panel or other surface. This sensor could provide a clear sky ambient light
range and that could be converted to a typical irradiance that could be used for
general purposes. So, it could provide a certain range of irradiance, technically.
So, if a higher range of ambient light is used, then the full spectrum can be
achieved. BH1750 is a Digital Ambient light sensor that uses I2C to communicate
with the microcontrollers and works with 3.3V operation voltage (Sourav Gupta,
2021). The I2C is connected with the Arduino Nano. Fortunately, the BH1750
Board is having the pull-up resistor for the I2C thus no additional resistor is
required. Powering the Arduino nano with 5V will provide 3.3V output on the
3.3V pin using the internal 3.3V regulator. The ADDR pin is set to ground
making the default address of the BH1750 the I2C address of the sensor.

Table 2

Closer Value or Maximum Range of Different Conditions of Irradiance

CASE ILLUMINANCE

Brightest Sunlight 120000 Lux

Bright Sunlight 100000-110000 Lux

Shaded Clear Sky 20000 Lux

The BH1750 sensor could provide a clear sky ambient light range and that
could be converted to a typical irradiance that could be used for general
purposes. So, it could provide a certain range of irradiance, technically. So, if a
higher range of ambient light is used, then the full spectrum can be achieved.
BH1750 is a Digital Ambient light sensor that uses I2C to communicate with the
microcontrollers and works with 3.3V operation voltage.
14

B.7 Conversion of Lux to W/m2

The Flux value that is received by the sensor is converted to the


irradiance. Basing on the related literature, there is no specific conversation for
this, but an approximation can be made for the Sun wavelength. The flux can be
converted to the approximate W/m2 using a multiplication of 0.0079.

The Illuminance according to the related literature is a measure of


photometric flux per unit area, or visible flux density (typically measured in
lumens per square meter), while irradiance is a measure of radiometric flux per
unit area, or flux density (expressed in W/m2). There is no simple conversion
from lux to W/m2, since it depends on the wavelength or color of the light.
However, a simplification was adapted: for the sun light there is an approximate
conversion of 0.0079 W/m2 per lux, valid for direct sunlight, while for daylight
the appropriate conversion drops to 10% of that value. This difference is based
on the fact that sunlight is a portion of the electromagnetic radiation given off by
the Sun, in infrared, visible, and ultraviolet light while daylight, is the
combination of all direct and indirect sunlight during the daytime, including
direct sunlight and diffuse sky radiation. Therefore, to convert irradiance into
illuminance the following equation is used:
𝑊𝑊
𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝑖𝑖 ( )
𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝑖𝑖 (𝑙𝑙𝑙𝑙𝑙𝑙) = 𝐸𝐸𝐸𝐸𝑖𝑖 = 𝑚𝑚2
0.0079
B.8 Simulation and Testing

The researchers simulate and test the membership functions and rules of
the fuzzy logic controller using Scilab sciFLT Editor. The researchers also set the
context and values for every variable for the error scaling factor, and the fuzzy
logic will be uploaded to the block diagram.

B.9 Software Design Implementation

The data collected by the solar irradiance sensor is inputted to a


microcontroller’s (Ao) input pin and undergo fuzzification to determine if the
recorded voltage output is enough to power up the load and if not, the
microcontroller gives signal the stand-by ac source to compensate the power
15

needed for the load. The data collected was based on the closed-loop control
system generated by the researchers.

B.9.1 System Algorithm

The solar irradiance control algorithm was displayed in Figure 7. The


sensor read the luminance from direct sunlight and converted the sensor readings
into an appropriate unit, such as watts per square meter (W/m²) when the
system is initialized and the data is displayed on the serial monitor.

Figure 7

Flowchart for System Control

If the readings of the sensor are greater than to the set threshold value,
the system used the solar power and repeat the process if the monitored
irradiance is above the set value. If the recorded irradiance data is below
threshold value, the systems switch to a back-up source. The system is monitored
16

using fuzzy logic control system, the cycles continue and repeat the algorithm to
continuously monitor and adjust the power generation mode based on the
measured irradiance level.

B.10 Testing and Evaluation

The testing of the hybrid power source of irrigation system is through


observation and data gathering. The researchers also monitor the irradiance
reading through the serial monitor of Arduino Simulation Application in a span
of an hour from 10 in the morning to 3 in the afternoon for a total duration of 5
hours for 3 days testing. The researchers monitored the PWM output based on
the recorded irradiance data and observed the performance of the dc brushless
pump with regards to the testing time span.

The accuracy of the membership function declared in the fuzzy logic code
is observed by comparing the continuous data taken from the irradiance sensor to
the output performance of the load. Since the range of irradiance readings must
be greater than 240 W/m2 for the PV Panel to be able to supply the needed
power for the maximum performance of the load, if the system sense that the
readings are lower than the set threshold value, the back-up ac power source
compensate the needed power for the load to operate.

B.11 Instrumentation

The following electronic components and device are used by the

researchers:

1. BH1750 digital ambient light sensor (ALS) module- Used to measure

the light intensity from direct sunlight.

2. Arduino Nano- Used as an interface between the solar irradiance sensor

and the Arduino Uno to create a solar irradiance monitoring.

3. Arduino Uno- Used to process the input data codes needed for

fuzzificztion.

4. 12V Switching Power Supply- Used to convert the AC input voltage to


17

the desired output voltage, ensuring compatibility with the connected

devices.

5. Voltage Regulator- Used prevents overloading and potential damage

caused by excessive current flow.

6. Photovoltaic cell (Solar Panel)- Used as the main power source of

hybrid system.

7. Stand-by AC power source- Used as back-up power supply of the hybrid

system.

8. Brushless DC Pump- Used to output water source for the irrigation

system.

9. Level Converter- Used to invert the input signal applied.

B.12 Data Collection Procedure

The data to be gathered is summarized in a tabular form as shown in


Table 3.

Table 3

Solar Irradiance Actual Readings

Solar Irradiance, Ir (W/m2)


10:00 11:00 12:00 1:00 2:00 3:00
AM AM PM PM PM PM
Day 1
Day 2
Day 3

Table 3 shows the tabular format for the gathered data of solar irradiance
at real time in W/m2. The solar irradiance is recorded every one hour starting
from 10 am to 3 pm.
18

The researchers gathered the data from three (3) tests. Each test has
different irradiance error membership functions. The data gathered by monitoring
the irradiance was evaluated using the Microsoft Excel Software. The researchers
highlighted the results through graphs and characterized it.

Table 4

PWM Output Actual Readings

PWM Output, Duty Cycle Percent


10:00 11:00 12:00 1:00 2:00 3:00
AM AM PM PM PM PM
Day 1

Day 2

Day 3

The actual PWM readings depend on the specific solar irradiance levels
experienced at the testing location and the sensitivity/response characteristics of
the sensor being used.

The output PWM is compared to the actual readings of the solar


irradiance at real time in W/m2. The output PWM is the basis of how much
power is needed to be compensated by the back-up ac power source. To
accurately know the amount of voltage being compensated by the back-up power
supply, the resulting irradiance reading in W/m2 is directly converted voltage
unit and displayed on serial monitor. The conversion of irradiance to voltage is
determined by multiplying the irradiance to 0.05. This multiplier is derived based
on the calculated threshold irradiance value and the voltage needed by the load
to operate.
19

C. Results and Discussions

This section presents the results of the procedures of the study entitled
“Hybrid Power Source of Irrigation System with Fuzzy Logic Control System”
were presented and discussed thoroughly.

C.1 System Implementation Results

Figure 8

Schematic diagram of the Device

The design of the schematic diagram of the actual device is constructed


using Proteus 8 professional. The circuit used a 220v-12v ac to dc converter
connected to level converter. In the circuitry of level converter, 100k ohm resistor
is connected to the base of 2N3904 then emitter is connected to the ground. A 1k
ohm resistor connected the collector pin of 2N3904 then the other end is
connected to the source pin of IRF9540, 10k ohm resistor is connected to the
collector of 2N3904 then the other end is connected to the gate of IRF9540. The
pwm pin#3 of Arduino is connected to the level converter 100k ohms resistor.
Drain of IRF9540 is connected to the blocking diode MiC 6A10. For the sensor,
SCL pin of BH1750 is connected to A4 of Arduino then SDA connected to A5,
VCC connected to 3.3V, and ADDR to ground. And, solar panel is connected to
blocking diode to the load.
20

In level converter, assuming a base-emitter voltage (VBE) of around 0.7V


for the 2N3904 transistor, and the beta is equal to 100, the calculation becomes:
R1 = (12V - 0.7V) / 0.001A R1 = 11.3kΩ
For more efficiency and availability, 100 k ohm resistor is used instead of 11.3 k
ohm. 10 k ohm resistor does not need to be connected, as the gate of the IRF9540
can be driven directly without a gate resistor but it is used for protection of the
circuit. The collector resistor 1k ohm connected to the collector of the 2N3904
transistor to help set the operating conditions, bias point and for saturation.

C.2 Software and Hardware Implementation Results

C.2.1 Software Implementation

For the software implementation, the researchers utilized the Arduino IDE
to create the Arduino script that provides the functionalities for the egg
incubator. The ready-made Arduino libraries were downloaded over the internet
which allows the simplification of the programming.

Figure 9

Screenshot of a part of the Arduino Script t


21

C.2.2 Hardware Implementation

Figure 10

3D design of the Actual Device

Preparation of Materials for Project Development and Construction were


included in this section. The researchers created a mechanical design, including
the 3D prototype irrigation, using the SketchUP. The researchers bought the
components in at the local stores in Iloilo City and online. The electronic and
electrical components were selected with respect to its usage to avoid possible
overheating and permanent damages. Lastly, the components were assembled and
integrated as a complete and functioning device.

C.2.3 Actual Image of the Device

In Figure 11 the researchers created housing for the device which


measures 2 feet by 19 inches from the ground. The total area measures 1.979 𝑓𝑓𝑓𝑓 2
with the height of 24 inches and a width of 15 inches.
22

Figure 11

Actual Images of the Hybrid Power Source of Irrigation System with Fuzzy Logic
Control System

The system circuit which consists of Arduino microcontroller for fuzzy


logic control, BH1750 Light intensity sensor for measuring solar irradiance is
connected inside with the microcontroller that serves as input to the
microcontroller, 12 Volts, 5 Amperes Switching power supply for the back-up ac
power source, voltage regulator for the microcontroller power supply, IRF9540N
MOSFET and 2N3904 pull-up transistor is used for the level converter circuit.
The aluminum heat sink and two fans, provides efficient circulation of air inside
the system enclosure. The enclosure of the main circuitry is made of sintra board
which measure 8 inches wide and 4 inches long with switches for the pump motor
and the grid back-up power supply. On top of the housing is where the solar PV
panel is set-up alongside is the sensor for measuring the solar irradiance. The
irrigation system is also located near the housing which is composed of a small
tank for the water source with the BLDC pump for irrigation of the DIY paddy.
23

C.3 Calculation for Threshold Value

C.3.1 Solving Panel Area

To calculate the area of a solar panel with dimensions of 670 mm (length)


by 520 mm (width) by 25 mm (thickness) considering the surface area of the
panel.
First, convert the dimensions to meters to ensure consistency:
Length = 670 mm = 670/1000 = 0.67 meters
Width = 520 mm = 520/1000 = 0.52 meters
Thickness = 25 mm = 25/1000 = 0.025 meters

Next, calculate the surface area by multiplying the length and width:
Surface Area = Length × Width = 0.67 meters × 0.52 meters = 0.3484 square
meters (“The Ultimate Guide to Solar Panel Calculation,” 2023).
Therefore, the surface area of the solar panel is approximately 0.3484 square
meters.

C.3.2 Solving for Panel Efficiency Factor

Panel Power = 50W


Panel Length= 0.670m
Panel Width= 0.520m

0.05𝑘𝑘𝑘𝑘
𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸𝐸 = 100% = 14.3513%
0.67𝑚𝑚 𝑥𝑥 0.52𝑚𝑚

C.3.3 Solving for Solar Irradiance Threshold Value for the Load

Power = 12 volts × 1 ampere = 12 watts


Solar Irradiance (in W/m²) = 12 Watts / (0.143513 x 0.3484 m²) = 240
Watts/m²
Therefore, the needed solar irradiance that is needed by the load is
approximately greater 240 W/m² or higher for the PV Panel to supply the
needed power to the load without the aid of back-up power supply.
24

C.4 Design Results for the Control System

Figure 12 shows the unity gain feedback closed-loop Hybrid Power Source
system with solar irradiance reference input.

Figure 12

Hybrid Power Source Control System

The error signal, the difference between the reference solar irradiance and
the actual recorded solar irradiance serves as the crisp input of the fuzzy
inference system. The output signal of the fuzzy inference system, a duty cycle of
the Pulse Width Modulation signal, was used to control the microcontroller. The
output PWM signal is the basis of power compensation coming from the back-up
ac power source for the pump to be powered optimally if the recorded solar
irradiance input does not achieve the set requirements.

Thus, the reference signal was 240 W/m2 which was based on the power
needed by the load, efficiency factor and total area of the PV panel.
25

C.4.1 Fuzzy Logic Controller Membership Function and Rules

Table 5 shows the fuzzy membership functions and rules in a tabular


format.

Table 5

Fuzzy Membership Functions and Rules

A single joint membership function was used thus; the fuzzy logic
controller holds one input and one output. The input of the controller was the
irradiance error with membership functions of: IR(zero), IR(low), IR(mid), and
IR(high). The output of the controller was the Duty Cycle with membership
functions of: very low, low, average, and max. These rules were generated in
terms of the state of the irradiance error and its corresponding output.

The membership functions and rules graphical representations of the fuzzy


logic control were simulated using the SCILAB sciFLT fls Editor.
26

Figure 13

SciFLT fls Editor Interface

Figure 13 shows a SCILAB feature which is the interface of the Fuzzy


Logic Control System Editor that used Mamdami approach to generate fuzzy
logic system.

Scilab fls editor is used in generating the fuzzy membership diagrams,


fuzzy control surface, and fuzzy rule graphs. The membership function for the
irradiance input was the level of error 0 to 3 and was computed by subtracting
the input irradiance coming from the sensor to the setpoint irradiance.

A set point is calculated based on the power requirements of the load and
the specification of the supply to power optimally the pump without the aid of
back-up supply. The setpoint of 240 W/m2 is the average value of irradiance set
in the membership function as the basis of power compensation. The graphical
representations of the membership functions and rules were then recorded and
documented.
27

Figure 14

Fuzzy Logic Control System Membership Function for Irradiance

The membership function of the fuzzy logic control system is based on the
input irradiance with Very Low (-1, 0, 40, 120), Low (40, 120, 200), Medium
(120, 200, 240), and High (120, 240, 240, 245) as the basis for making rules and if
else statement.

Graphical representations of the membership functions and rules were then


captured and recorded

Figure 15

Fuzzy Input Membership Function


28

Figure 15 shows the Irradiance Error as input member function that


ranges from 0 to 240. The membership functions were indicated as the following:
Very Low (-1, 0, 40, 120), Low (40, 120, 200), Medium (120, 200, 240), and High
(120, 240, 240, 245).

Figure 16

Fuzzy Logic Control System Membership Function for PWM

The membership function of the fuzzy logic control system is based on the
output PWM with Zero (-1, 0, 1), Low (0, 76.5, 127.5), Average (76.5, 127.5,
178.5), and Maximum (178.5, 255, 256) as the basis for making rules and if else
statement.
29

Figure 17

Fuzzy Output Membership Function

Figure 17 shows the Duty Cycle Output as output member function that
ranges from 0 to 255. The membership functions were indicated as the following:
Zero (-1, 0, 1), low (0, 76.5, 127.5), average (76.5, 127.5, 178.5), and max (178.5,
255, 256).

Figure 18

Fuzzy Rules
30

Figure 18 indicates the relationship between the input membership and


the output membership. It also shows the Duty Cycle output for any Irradiance
Error Input ranging from 0 to 450. Fuzzy rules are the fundamental building
blocks of a fuzzy logic system. They describe the relationships between input
variables and output variables in a linguistic form. Fuzzy rules are typically
formulated as "IF-THEN" statements, where the "IF" part represents the
conditions or input variables, and the "THEN" part represents the output or
consequence.

Figure 19

Fuzzy Surface Output

Figure 19, shows the surface output of the fuzzy inference system based on
the membership function and rules. Furthermore, as irradiance increases, the
degree of membership for the corresponding PWM value decreases. This
relationship is likely defined by the specific membership functions used in the
fuzzy logic system.

C.5 Testing and Evaluation Results

After the components and the circuit of the “Hybrid Power Source with
Fuzzy Logic Control for Irrigation” were finalized and installed, the researchers
tested the device several times to ensure accuracy. Three trials were conducted in
order to achieve the experiment's desired time of stability. The data was entered
31

so that the researchers may examine the results at any time. The Irradiance and
PWM were recorded every hour for 3 days.

The researchers conducted three tests in gathering the data from the Solar
Irradiance reading (BH1750 sensor). The tests have the membership function
with value in Figure 16.

C.5.1 Irradiance Testing Result

Table 6

Days Trial of Sensor Solar Irradiance

Table 7

Days Trial of Solar Power Meter Irradiance

Table 6 and Table 7 shows the actual data gathered from different trials.
The table 6 represents the Sensor Solar Irradiance values (in W/m2) measured
and Table 7 represents the Solar Power Meter Irradiance values (in W/m2) at
different times of the day for three consecutive days (Day 1, Day 2, Day 3). Each
row corresponds to a specific day, and each column represents a specific time
point. The figure provides a snapshot of the Irradiance levels throughout the day
for the given three days. It can be used to analyze and compare the variations in
Irradiance over time and between different days.
32

By examining Table 6 and Table 7, we observed the changes in Sensor


Solar Irradiance and Solar Power Meter Irradiance values throughout the day
and identify any patterns or trends. We can compare the Irradiance levels at the
same time point across different days to see if there are consistent variations or
fluctuations. This information can be useful for various applications, such as solar
energy generation, where the amount of sunlight or radiation impacts the
efficiency or output of solar panels.

C.5.2 PWM Testing Results

Table 8

Days Trial of PWM based on the Sensor Solar Irradiances

Table 9

Days Trial of PWM based on the Solar Power Meter Irradiances

Table 8 represents the PWM (Pulse Width Modulation) Duty Cycle


values at different times of the day for three consecutive days (Day 1, Day 2,
Day 3). A PWM signal is typically used to control or regulate the power output
to a load, where the duty cycle determines the average power delivered.
33

Table 9, we observed the PWM Duty Cycle values for each time point
throughout the day. The significant lies in its ability to demonstrate the
variations in the PWM Duty Cycle values over time and between different days.
By analyzing, you can identify any patterns or trends in the duty cycle values.
For instance, you can compare the duty cycle values at the same time point
across different days to observe any consistent changes or trends. The Table 8
and 9 provides valuable insights into the control mechanism used for regulating
power output, specifically through PWM. It can be utilized to evaluate the
efficiency, effectiveness, or performance of the PWM system in maintaining the
desired power levels.

C.6 Analysis Results

C.6.1 Accuracy Results of Irradiance Sensor

The method for measuring the accuracy of the actual gathered data based
on the data gathered in the tabulated results in Table 10 was the Average
percentage difference. Since percentage difference was given by,

|𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂 𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼 − 𝑆𝑆𝑆𝑆𝑆𝑆𝑆𝑆𝑆𝑆𝑆𝑆 𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼|


𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷 = 𝑥𝑥 100%
𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂𝑂 𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼𝐼

Therefore,
𝑇𝑇𝑇𝑇𝑇𝑇𝑇𝑇𝑇𝑇 𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷
𝐴𝐴𝐴𝐴𝐴𝐴𝐴𝐴𝐴𝐴𝐴𝐴𝐴𝐴 % Difference = 𝑥𝑥 100%
𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁 𝑜𝑜𝑜𝑜 𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟
34

Table 10

Average Percentage Difference of Irradiance

Irradiance Data Percent Difference (%)


10:00 11:00 12:00 1:00 2:00 3:00 Average Daily Percent
Error AM AM PM PM PM PM Difference

Day 1 1.36% 1.13% 2.02% 1.67% 1.49% 1.28% 1.49%


Day 2 0.80% 0.78% 2.32% 1.45% 4.70% 1.84% 1.98%
Day 3 4.45% 1.37% 2.11% 1.82% 1.80% 2.92% 2.41%
Average Percent
Difference 2.20% 1.09% 2.15% 1.64% 2.66% 2.01% 1.96%

Table 10 shows the accuracy result for the Irradiance reading for Test 1,
Test 2, and Test 3. The average percent difference results 1.96% for the
Irradiance readings.

The accuracy of irradiance sensor is tested by comparing the data


gathered of the irradiance sensor to the solar power meter device. The calculated
percent difference shows and proves that the solar irradiance meter using BH1750
light intensity sensor is accurate with an average percent difference of 1.96%

D.6.2 Accuracy of Fuzzy Logic Controller

The method for measuring the accuracy of the fuzzy logic control system
was based on the simulated PWM data cycle of sensor solar irradiance to solar
power meter irradiance data as seen on the tabulated results in figure table 8.
The percent difference and average percent difference was calculated using the
same formula.
|𝑷𝑷𝑷𝑷𝑷𝑷 𝒐𝒐𝒐𝒐 𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺 𝑴𝑴𝑴𝑴𝑴𝑴𝑴𝑴𝑴𝑴 𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰 −𝑷𝑷𝑷𝑷𝑷𝑷 𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺 𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺𝑺 𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰 |
Percentage Difference = 𝒙𝒙 𝟏𝟏𝟏𝟏𝟏𝟏
𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶𝑶 𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰𝑰

Therefore,
𝑇𝑇𝑇𝑇𝑇𝑇𝑇𝑇𝑇𝑇 𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃𝑃 𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷𝐷
Average % Difference =
𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁𝑁 𝑜𝑜𝑜𝑜 𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟𝑟
35

Table 11

Average Percentage Difference of PWM Duty Cycle

PWM Duty Cycle Percent Difference (%)


10:00 11:00 12:00 1:00 2:00 3:00 Average Daily
Error AM AM PM PM PM PM Percent Difference

Day 1 0.00% 0.00% 0.00% 0.00% 2.38% 0.03% 0.40%


Day 2 0.56% 0.00% 0.00% 0.00% 4.17% 7.84% 2.09%
Day 3 4.39% 0.00% 0.00% 0.00% 0.00% 2.32% 1.12%
Average Interval
Percent Difference 1.65% 0.00% 0.00% 0.00% 2.18% 3.40% 1.20%

The accuracy of a fuzzy logic controller can be influenced by the design


choices made during its development. This includes selecting the appropriate
number of fuzzy sets, defining the membership functions, and determining the
rule base. A well-designed FLC with carefully chosen parameters can improve its
accuracy. Based on Table 11, it is shown that the result of our fuzzy logic
controller is that the higher the irradiance, the lower the PWM. That fuzzy logic
controller will compensate the voltage to the load if there is not enough voltage
produced by the solar panel.

In a solar-to-grid system, the voltage output from solar panels can


fluctuate due to varying solar irradiance levels and other environmental factors.
To compensate for these voltage variations and ensure stable power supply to the
grid, a fuzzy logic controller (FLC) is employed. By utilizing fuzzy rules and
membership functions, the FLC accurately adjusts the voltage compensation
based on the changing solar conditions. The fuzzy rules incorporate expert
knowledge and heuristics to ensure precise control actions are taken in response
to varying solar irradiance levels and other environmental factors. The calculated
percent difference shows and proves that the PWM Duty Cycle of two different
testing using irradiance sensor and solar power meters is accurate with an
average percent difference of 1.20%
36

C.6.3 Reliability of the Hybrid Power Source for Irrigation System

Table 12

Recorded Actual Voltages at High Irradiance

Hybrid Power Supply Values in Voltage @ with Load


10:00 10:10 10:20 10:30 10:40 10:50
AM AM AM AM AM AM
Solar Panel 12.86 12.86 12.83 12.41 12.84 12.84
Back-up AC supply 0.36 0.29 0.31 0.33 0.3 0.3
Total Output Voltage 13.22 13.15 13.14 12.74 13.14 13.14
Actual Output Voltage 12.49 12.45 12.43 12.04 12.41 12.43
Voltage Drop 0.73 0.7 0.71 0.7 0.73 0.71

Table 13

Recorded Actual Voltages at Low Irradiance

Hybrid Power Supply Values in Voltage @ with Load


10:00 10:10 10:20 10:30 10:40 10:50
AM AM AM AM AM AM
Solar Panel 0.9 0.87 0.65 0.43 0.56 0.66
Back-up AC supply 11.7 11.9 11.77 12.12 11.95 12.08
Total Output Voltage 12.6 12.77 12.42 12.55 12.51 12.74
Actual Output
Voltage 12.4 12.07 12.32 12.08 12.21 12.03
Voltage Drop 0.2 0.7 0.1 0.47 0.3 0.71

The reliability of the hybrid system is tested by observing the actual


simulation result and device testing. The performance of the dc pump is
evaluated through a 3 days testing from 10 am in the morning to 3 in the
afternoon. The PV Panel and back-up ac grid supply was controlled using a fuzzy
membership functions and rules uploaded to the microcontroller and the result of
irradiance measurement determines the output PWM Duty Cycle that is directly
37

converted to voltage value which is the basis on how much power is being
compensated by the back-up source. The amount of voltage that the two power
source is supplying is recorded using digital multimeter every 10 minute’s interval
from 10 am. The amount of irradiance is being observed and compared to the
actual voltage delivered by the hybrid power source. It was observed that the
pump functions optimally even though there are changes in the irradiance
reading because of the hybrid power system. Thus, the reliability of the hybrid
system is proven at these observations with a maximum voltage drop of 0.73
Volts at varying irradiance tested with load.

Figure 20

Comparison of Sensor Solar and Solar Power Meter Irradiance PWM Duty Cycle
Fuzzy Surface Output

Figure 20 represents the graphical PWM Duty Cycle fuzzy surface output
of the two irradiance readings using sensor and solar power meter. This result is
compared to the surface output of the fuzzy inference system based on the
membership function and rules. It is observed that as irradiance increases, the
degree of membership for the corresponding PWM value decreases. Thus, this
supports the reliability of the hybrid system.
38

D. Conclusion

The researchers have accomplished the design for the fuzzy-based closed
loop control system of a hybrid power source by successfully generating the fuzzy
membership functions and fuzzy rules. Additionally, the software and hardware
designs were successfully implemented with acceptable accuracy and reliability.
With these results, the device created could possibly help farmers in maintaining
their irrigation system through having uninterrupted and cost friendly power
source for their pump.

E. Recommendations

Based on the findings from the implementation and testing, the


proponents would recommend the following for the improvement of the
operation.

1. Use another control system such as PID for more accurate tuning of
hybrid power compensation
2. Create solar irradiance measurement using different sensor for more
accurate solar irradiance measurement.
3. Use solar panel with higher wattage for better efficiency of hybrid
power source
4. Integrate voltmeter in the output to measure the output voltage
supplied by the source to monitor the power delivered by each source.
39

F. References

Agency for Natural Resources and Energy. Japan’s Energy; 2019.


Availableonline: https://www.enecho.meti.go.jp/en/category/brochures/pd
f/japan_energy_2019.pdf (accessed on 14 January 2021).
Ahmed, Yasir. (2013). How to Calculate the Surface Area Required by Solar
Panels. Retrieved from (https://www.raymaps.com/index.php/how-to-
calculate-the-area-required-by-solar-panels/)

DC Circuit Power Calculator (EE Power). (n.d.). Retrieved from


https://eepower.com/tools/dc-circuit-power-calculator/#

Gupta, S. (2021). Solar Irradiance Measurement Meter. Retrieved


from https://circuitdigest.com/microcontroller-projects/solar-irradiance-
esurement-meter-using-arduino?fbclid=IwAR3wiKZjAfPB8vrs7FM31r-
9aPKansHrfUYFC9XI-BMiqsK4VNE27kIWkYw.

Hinokuma, T., Farzaneh, H., & Shaqour, A. (2021). Techno-Economic Analysis


of a Fuzzy Logic Control Based Hybrid Renewable Energy System to
Power a University Campus in Japan. Energies, 14(7),
1960. https://doi.org/10.3390/en14071960.

How to Calculate Solar Panel Efficiency. (2019). Retrieved from


https://www.photonicuniverse.com/en/resources/articles/full/7.html

International Rice Research Institute (IRRI). Solar-powered irrigation in the


Philippines. (2016). Retrieved from https://www.irri.org/news/solar-
powered-irrigation-philippines.

K. Tanaka and M. Sugeno, "Fuzzy PID controllers," Proceedings of the IEEE


International Conference on Fuzzy Systems, pp. 1163-1168, 1992.

Koutsoyiannis, D.; Angelakis, A.N. Agricultural Hydraulic Works in Ancient


Hellas. In The Encyclopaedia of Water Science; Stewart, B.A., Howell, T.,
Eds.; Markel Dekker Inc.: New York, NY, USA, 2004; pp. 1–4. [Google
Scholar]
L. A. Zadeh, "Fuzzy Sets," Information and Control, vol. 8, no. 3, pp. 338-353,
1965.
40

M. E. Fayed and M. F. Mahmoud, "Hybrid Power Systems," in Encyclopedia of


Energy Engineering and Technology, ed. B. D. Steward, vol. 1, pp. 767-7
772, Taylor and Francis, 2007.

Michael, P. J., Johnston, D. E., & Moreno, W. (2020). A conversion guide: solar
Irradiance and lux illuminance. Journal of Measurements in
Engineering, 8(4), 153–166. https://doi.org/10.21595/jme.2020.21667

N. Ntuli et al. (2021), Design and implementation of a hybrid solar-battery


powered irrigation system for smallholder farmers in Sub-Saharan Africa.

P. Laconte, "Combining Power Sources to Meet Energy Needs," IEEE Power and
Energy Magazine, vol. 5, no. 6, pp. 30-38, Nov/Dec 2007.

Philippine Center for Postharvest Development and Mechanization (PhilMech).


Hybrid solar-diesel irrigation systems in the Philippines. (2018). Retrieved
from https://www.philmech.gov.ph/wp-content/uploads/2019/05/Hybrid-
Solar-Diesel-Irrigation-Systems-in-the-Philippines.pdf_

The Ultimate Guide to Solar Panel Calculation. (2023). Retrieved from


https://www.jackery.com/blogs/news/ultimate-guide-to-solar-panel
calculation.

Madrigal, et. Al. (2019). Fuzzy logic-based maximum power point tracking solar
battery charge controller with backup stand-by AC generator.
41

APPENDICES
42

G. Appendices

Appendix A

Mechanical Design

A.1

Device Back Perspective

A.2

Device Front Perspective


43

Appendix B

Lists of Project Components and Materials

Components Specification Quantity

DC Pump 12V, 1A, 19W 1

Switching Power Supply 12V, 5A 1

Arduino Board Uno (ATmega328) 1

Step Down Power Regulator LM2596, 4V-35V 2

Solar Panel 670’520’25 mm, 22.4V, 1


50W, 3.027A

Light Intensity Sensor BH1750 1

Heatsink Black, 70x35x15 mm 1

PC Fan 12V 2

Wood 1x2x8 ft 4

MOSFET IRF9540N 1

Diode 6A10 2

Resistors 10 kΩ, 1kΩ, 100kΩ 3

Switch Seesaw, 2 Pins 2

Transistor 2N3904 1

PCB Board 7x9 cm 1

Wire - -

Sintra Board 3 mm 3
44

Appendix C

Electronic Components Specification

C.1 BLDC Pump


45

C.2 Solar Panel


46

C.3 BH1750 – Ambient Light Sensor


47

C.4 IRF9540N MOSFET


48

C.5. 6A10 Diode


49

C.6 2N3904 Transistor


50

Appendix D

Arduino Codes

#include <Wire.h> //functions for I2C communication between devices


#include <BH1750.h> //library for BH1750 digital light sensor and definitions
to interface with the BH1750 sensor and obtain light intensity readings
#include <Fuzzy.h> //library for implementing fuzzy logic systems int pin_Out
= 3; //declare pin 3 as output pin with variable pin_Out BH1750 lightMeter;
//access the functions and properties of the BH1750 library for measuring light
intensity. //declare input and output variables
float lux;
float OutDC;
float luxInput;
float irr;
float voltage; //Declare fuzzy membership functions Fuzzy *fuzzy = new
Fuzzy(); //Input-irradiance
Membership Function
FuzzySet *ZERO = new
FuzzySet(-1, 0, 40, 120 );
FuzzySet *low = new
FuzzySet(40, 120, 120, 200);
FuzzySet *med = new
FuzzySet(120, 200, 200, 240);
FuzzySet *high = new
FuzzySet(120, 240, 240, 245); //Output-PWM Membership Function FuzzySet
*zeroOutput = new
FuzzySet(-1, 0, 0, 1);
FuzzySet *lowOutput = new
FuzzySet(0, 76.5, 76.5, 127.5);
FuzzySet *averageOutput = new
FuzzySet(76.5, 127.5, 127.5, 178.5);
FuzzySet *maximumOutput = new
FuzzySet(178.5, 255, 255, 256);
void setup() {
Serial.begin(9600); //initializes the serial communication with a baud rate of
9600
51

Wire.begin(); // initializes the I2C (Inter-Integrated Circuit) communication bus.


//It sets up the Arduino as an I2C master and enables communication with other
I2C devices connected to the
Arduino. lightMeter.begin();//a function call that initializes the BH1750 light
sensor. It prepares the sensor for operation and sets any necessary configurations
Serial.println(F("Fuzzy Begin")); //sends a text message to the serial port
//set output pin pinMode(pin_Out, OUTPUT);
//set fuzzy inputs
FuzzyInput *luxInput = new FuzzyInput(1);
luxInput->addFuzzySet(ZERO);
luxInput->addFuzzySet(low);
luxInput->addFuzzySet(med);
luxInput->addFuzzySet(high);
fuzzy->addFuzzyInput(luxInput);
//set fuzzy outputs FuzzyOutput *OutDC = new FuzzyOutput(1); OutDC-
>addFuzzySet(zeroOutput);
OutDC->addFuzzySet(lowOutput);
OutDC->addFuzzySet(averageOutput);
OutDC->addFuzzySet(maximumOutput);
fuzzy->addFuzzyOutput(OutDC);
//1 rule FuzzyRuleAntecedent
*ifLuxZERO = new
FuzzyRuleAntecedent();
ifLuxZERO->joinSingle(ZERO);
FuzzyRuleConsequent
*thenOutDCmaximumOutput = new FuzzyRuleConsequent();
thenOutDCmaximumOutput->addOutput(maximumOutput); FuzzyRule
*fuzzyRule01 = new
FuzzyRule(1, ifLuxZERO, thenOutDCmaximumOutput);
fuzzy->addFuzzyRule(fuzzyRule01);
//2 rule
FuzzyRuleAntecedent *ifLuxLow = new FuzzyRuleAntecedent(); ifLuxLow-
>joinSingle(low); FuzzyRuleConsequent *thenOutDCaverageOutput = new
FuzzyRuleConsequent(); thenOutDCaverageOutput-
>addOutput(averageOutput);
52

FuzzyRule *fuzzyRule02 = new FuzzyRule(2, ifLuxLow,


thenOutDCaverageOutput); fuzzy->addFuzzyRule(fuzzyRule02);
//3 rule
FuzzyRuleAntecedent *ifLuxMed = new FuzzyRuleAntecedent(); ifLuxMed-
>joinSingle(med);
FuzzyRuleConsequent *thenOutDClowOutput = new FuzzyRuleConsequent();
thenOutDClowOutput->addOutput(lowOutput); FuzzyRule *fuzzyRule03 = new
FuzzyRule(3, ifLuxMed, thenOutDClowOutput);
fuzzy->addFuzzyRule(fuzzyRule03);
//4 rule
FuzzyRuleAntecedent *ifLuxHigh = new FuzzyRuleAntecedent(); ifLuxHigh-
>joinSingle(high);
FuzzyRuleConsequent *thenOutDCzeroOutput = new FuzzyRuleConsequent();
thenOutDCzeroOutput->addOutput(zeroOutput);
FuzzyRule *fuzzyRule04 = new FuzzyRule(4, ifLuxHigh,
thenOutDCzeroOutput); fuzzy->addFuzzyRule(fuzzyRule04);
}
void loop() {
//Set lux as input lux = lightMeter.readLightLevel();
//convert lux into irradiance irr = lux * 0.0079;
//convert irradiance into voltage voltage = irr * 0.05; Serial.println("\n\n\nCrisp
Input: ");
Serial.print("\t\t\tirradiance: ");
Serial.print(irr);
Serial.println(" W/m2");
delay(1000);
Serial.print("\n\nvoltage: ");
Serial.print(voltage);
Serial.println("V");
delay(1000);
//FUZZIFICATION
fuzzy->setInput(1, irr);
fuzzy->fuzzify();
Serial.print("\n\n\nFuzzify Input:");
Serial.print("\n");
Serial.print("\t\t\tirradiance: ZERO-> ");
53

Serial.print(ZERO->getPertinence());
Serial.print(", low-> ");
Serial.print(low->getPertinence());
Serial.print(", med-> ");
Serial.print(med->getPertinence());
Serial.print(", high-> ");
Serial.println(high->getPertinence());
//DEFUZZIFICATION
OutDC = fuzzy->defuzzify(1);
Serial.print("\n\n\nDefuzzify Input: ");
Serial.println("\n");
Serial.print("\t\t\toutputDC:
zero output-> ");
//function of each output variable
Serial.print(zeroOutput->getPertinence());
Serial.print(", low output-> ");
Serial.print(lowOutput->getPertinence());
Serial.print(", Average output-> ");
Serial.print(averageOutput->getPertinence());
Serial.print(", maximum output-> ");
Serial.println(maximumOutput->getPertinence()); Serial.print("\n\nOutput
Duty Cycle: ");
Serial.print(OutDC); Serial.print("\n-----------------------------------------------------------
--------------------------------------------------------------------"); analogWrite(pin_Out,
OutDC); delay(1000); }
54

Appendix E

Documentation

Testing and Calibration of Solar Panel

In white shirt is Ivy Jude P. Gabales, in red is John Albert A. Anzures


and in yellow is Catherine Balano. Photo taken at Ang’s Boarding House, 3rd
floor La Paz, Iloilo City on May 25, 2023.
55

Soldering and Assembling of the Circuitry

With researcher’s, John Albert A. Anzures, Ivy Jude P. Gabales and


Catherine Balano at Ang’s Boarding House, 3rd floor La Paz, Iloilo City on May
25, 2023.

Construction of Device Housing

With researcher, John Albert A. Anzures at Ang’s Boarding House, 3rd


floor La Paz, Iloilo City on June 2, 2023.
56

Testing of the Device

From the left right, Catherine Balano, Ivy Jude P. Gabales and John
Albert A. Anzures. Taken at Ang’s Boarding House, 3rd floor La Paz, Iloilo City
on July 4, 2023.

Gathering of data using Solar Irradiance Sensor and Solar Power Meter
taken at Ang’s Boarding House, 3rd floor La Paz, Iloilo City on June 6, 2023.
57

Picture of the researchers, panelist and adviser after their final defense.
From the left Engr. Santos James Emmanuel Malunda (Panelist), Catherine
Balano (researcher), John Albert A. Anzures (researcher), Ivy Jude P. Gabales
(researcher), and Engr. Ramon A. Alguidano Jr. (Adviser) taken at Research
Hub, loilo Science and Technology University, Burgos St., La Paz, Iloilo City on
June 9, 2023.
58

H. Profile of the Group Members


59
60

You might also like