0% found this document useful (0 votes)
13 views

Application of Fuzzy Logic in Motorcycle Security Systems Based On Internet of Things (IoT)

Uploaded by

SoulHunterZ3RO
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views

Application of Fuzzy Logic in Motorcycle Security Systems Based On Internet of Things (IoT)

Uploaded by

SoulHunterZ3RO
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 9

http://infor.seaninstitute.org/index.

php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

Application of Fuzzy Logic in Motorcycle Security Systems


Based on Internet of Things (IoT)

Zulfahmi Syahputra1, Arpan2, Mohammad Faiza Zachary3


Universitas Pembangunan Panca Budi, Medan, Indonesia
Email: [email protected], [email protected], [email protected]

Abstract

Article Info The development of motorcycle use in Indonesia is increasing every year.
This increasing trend is also accompanied by the increasing number of
Received : 29 November 2021 theft crimes of motorcycles. This is due to the physical nature of the
Revised : 23 December 2021 motorcycle which is relatively small and easy to steal. In this study the
Accepted : 29 December 2021 author will discuss the motorcycle theft prevention system by installing
various sensors built using fuzzy logic and utilizing the concept of the
Internet of Things (IOT). This fuzzy logic consists of values and domains
that are classified into several variables to conclude the degree and status
of the motorcycle as an alarm trigger. Then by utilizing IOT the alarm is
converted into a notification that will be sent via the motorcycle user's
Telegram application if the motorcycle is stationary, Bergerak or moved.
This system has 2 (two) components, namely hardware in the form of
several sensors including infrared sensors along with a microcontroller
and software connected to the Telegram application which functions as a
motorcycle status notification receiver.

Keywords : Motorcycle safety, Fuzzy Logic, Internet of Things.

1. Introduction
Transportation has an important role in everyday life. This is because the majority of our
activities are outdoors and require us to be able to get from one place to another quickly and easily.
Motorcycles are the most dominant choice of transportation mode for the community in terms of
effectiveness, efficiency and economic value. Based on data from the Central Statistics Agency of
North Sumatra Province, the number of motorcycle exist in North Sumatra is 463,305 units until 2020.
But behind the advantages and convenience it has, motorcycles are a mode of transportation that
is easy to steal, disassemble, and easily shipped in the form of parts (McDono, C, 2011). There were
2,634 units of crime or violations reported in the type of motor vehicle theft in 2019 (Central Statistics
Agency of North Sumatra Province, 2021). Motorcycle safety is the most vital thing in preventing these
crimes. According to Pachica, et al. (2017), the easiest and most economical choice falls on the
installation of an alarm that will make a sound when attempting to steal a motorcycle. However, if the
owner is out of reach of the motorbike they will not hear the alarm going off. Therefore, it is also
necessary to notify the owner if the alarm is triggered by certain activities.
In this journal, the author proposes the application of Fuzzy Logic to an Internet of Things (IOT)
based security system. By integrating Fuzzy Logic into information systems and process engineering, it
produces applications such as control systems and decision-making systems that are more flexible,
stable, and sophisticated (Nasution, 2012). This fuzzy logic consists of values and domains that are
classified into several variables to conclude the degree and status of the motorcycle as an alarm

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
595
http://infor.seaninstitute.org/index.php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

trigger. The conclusion is sent as an alarm notification to vehicle owners via the Telegram application as
an application of the IoT concept which is a combination in a network connected to a machine or device
that sends and receives data via a network connection (Novelan, 2020).

2. Methods
2.1 Research Stages
The stages of research that the author did in this journal are as follows:
1. Problem Analysis
2. System Design
3. System Build
4. System Test

2.2 Research Design


In this study, the authors built a design for a sensory network system on a motorcycle. The design
of this study consisted of several stages. The first stage begins with compiling a table of sensor values
that will be used as test parameters using fuzzy logic.
The sensor table is as follows :

Table 1. Sensor Value

No Function Variabel Fuzzy Set Domain

Normal [0 20]
Waspada [20 40]
Getaran
Gawat [40 60]
1 Input Putaran Tidak Bergerak [0 20]
Roda
Bergerak [20 30]
Aman [0 20]
Hati-Hati [20 30]
2 Output Output
Ada Maling [30 50]

Followed by the second stage, namely designing the general architecture of the sensory network
system with tools and devices that can be illustrated as follows:

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
596
http://infor.seaninstitute.org/index.php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

Figure 1. Sensory Network General Architecture

The next stage is the installation of sensor components/devices on the motorcycle body which can be seen
in the following description:

Figure 2. Installation of the vibration sensor on the motorcycle handlebar.

Figure 3. Installation of infrared sensors on motorcycle wheels

Figure 4. Installation of the siren inside the motorcycle seat

Figure 5. Installation of the microcontroller inside the motorcycle seat

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
597
http://infor.seaninstitute.org/index.php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

Figure 6. Installation of current with a motorcycle battery

3. Results and Analysis


3.1 Fuzzification
The fuzzification of this motorcycle safety device uses two inputs from a vibration sensor (SW420) and
an infrared sensor (TCRT 5000) while the output is a value which is then converted into the sound of
alarms and notifications sent via the Telegram application. There are two input variables, namely
Vibration and Wheel Rotation. In the table below there is a fuzzy set of each variable.

Table 2. Sensor Value

No Function Variabel Fuzzy Set Domain

Normal [0 20]
Waspada [20 40]
Getaran
Gawat [40 60]
1 Input Putaran Tidak Bergerak [0 20]
Roda
Bergerak [20 30]
2 Aman [0 20]
Hati-Hati [20 30]
Output Output
Ada Maling [30 50]

In the membership function, input the sensor using the triangular and trapezoidal curve shapes. The
figure below is a membership function of the input vibration and infrared sensors.

Figure 7. Vibration Sensor Input Membership Function

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
598
http://infor.seaninstitute.org/index.php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

For the input membership function of the Vibration sensor above, two membership functions are used,
namely the representation of a triangular curve and a representation of a trapezoidal curve as follows.

Figure 8. Triangular Curve Representation and Trapezoidal Curve Representation


For the input membership function of the infrared sensor above, the membership function of the
trapezoidal curve representation is as follows.

Figure 9. Infrared Sensor Input Membership Function

30−𝑥 1;𝑥 ≤20


μTidak Bergerak {30−20 ; 20 ≤ 𝑥 ≤ 30
0; 𝑥≥30

𝑥−200; 𝑥≤20
μBergerak {30−20 ; 20 ≤ 𝑥 ≤ 30
1; 𝑥≥30

3.2 Example case 1 on fuzzy input calculation


In this case, a vibration value of 28 is given and a wheel rotation value of 30 is given. By using the
above function, the fuzzification value is obtained by:
a. Vibration membership function
40−𝑥 40−28 12
1. Normal fuzzy set, µNormal [28] = 40−20 = 40−20 = 20 = 0,6

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
599
http://infor.seaninstitute.org/index.php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

2. Waspada fuzzy set, µWaspada[28] = 𝑥−20 28−20 8


40−20
= 40−20 = 20 = 0,4

3. Gawat fuzzy set, µGawat[28] = 0


b. Wheelspin membership function
1) Tidak Bergerak fuzzy set, µTidak Bergerak[30] = 0
2) Bergerak fuzzy set, µBergerak[30] = 1

3.3 Forming of Fuzzy Rules


There are six fuzzy rules in this motorcycle safety device, namely:

[Aturan 1] If (Getaran is Normal) and (Putaran Roda is Tidak Bergerak) then (20)
[Aturan 2] If (Getaran is Normal) and (Putaran Roda is Bergerak) then (30)
[Aturan 3] If (Getaran is Waspada) and (Putaran Roda is Tidak Bergerak) then (20)
[Aturan 4] If (Getaran is Waspada) and (Putaran Roda is Bergerak) then (50)
[Aturan 5] If (Getaran is Gawat) and (Putaran Roda is Tidak Bergerak) then (30)
[Aturan 6] If (Getaran is Gawat) and (Putaran Roda is Bergerak) then (50)

3.4 Rules Composition


The composition of the rules for this motorcycle safety tool uses the MIN implication function
to get the α=predicate value of each rule. Then each value of α=predicate is used to calculate the output
of the inference results explicitly (crips) on each rule (z1, z2, z3, …, zn). In example 1 above, the
composition of the rules is as follows:

[Aturan 1] If (Getaran is Normal) and (Putaran Roda is Tidak Bergerak)then (20)


𝛼 −𝑝𝑟𝑒𝑑𝑖𝑘𝑎𝑡1 = 𝜇𝑁𝑜𝑟𝑚𝑎𝑙 ∩ 𝜇𝑇𝑖𝑑𝑎𝑘𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘
= 𝑚𝑖𝑛(𝜇𝑁𝑜𝑟𝑚𝑎𝑙[28], 𝜇𝑇𝑖𝑑𝑎𝑘𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘[30])
= 𝑚𝑖𝑛(0,6; 0) = 0

[Aturan 2] If (Getaran is Normal) and (Putaran Roda is Tidak Bergerak)then (30)


𝛼 −𝑝𝑟𝑒𝑑𝑖𝑘𝑎𝑡1 = 𝜇𝑁𝑜𝑟𝑚𝑎𝑙 ∩ 𝜇𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘
= 𝑚𝑖𝑛(𝜇𝑁𝑜𝑟𝑚𝑎𝑙[28], 𝜇𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘[30])
= 𝑚𝑖𝑛(0,6; 1)
= 0,6
[Aturan 3] If (Getaran is Waspada) and (Putaran Roda is Tidak Bergerak)then (20)
𝛼 −𝑝𝑟𝑒𝑑𝑖𝑘𝑎𝑡1 = 𝜇Waspada ∩ 𝜇Tidak𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘
= 𝑚𝑖𝑛(𝜇𝑁𝑜𝑟𝑚𝑎𝑙[28], 𝜇Tidak𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘[30])
= 𝑚𝑖𝑛(0,4; 0)
=0
[Aturan 4] If (Getaran is Waspada) and (Putaran Roda is Bergerak)then (50)
𝛼 −𝑝𝑟𝑒𝑑𝑖𝑘𝑎𝑡1 = 𝜇Waspada ∩ 𝜇𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘
= 𝑚𝑖𝑛(𝜇𝑁𝑜𝑟𝑚𝑎𝑙[28], 𝜇𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘[30])
= 𝑚𝑖𝑛(0,4; 1)
= 0,4
[Aturan 5] If (Getaran is Gawat) and (Putaran Roda is Tidak Bergerak)then (30)
𝛼 −𝑝𝑟𝑒𝑑𝑖𝑘𝑎𝑡1 = 𝜇Gawat ∩ 𝜇Tidak𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘
= 𝑚𝑖𝑛(𝜇𝑁𝑜𝑟𝑚𝑎𝑙[28], 𝜇Tidak𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘[30])
= 𝑚𝑖𝑛(0; 0)
=0
[Aturan 6] If (Getaran is Gawat) and (Putaran Roda is Bergerak)then (50)
𝛼 −𝑝𝑟𝑒𝑑𝑖𝑘𝑎𝑡1 = 𝜇Gawat ∩ 𝜇𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
600
http://infor.seaninstitute.org/index.php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

= 𝑚𝑖𝑛(𝜇𝑁𝑜𝑟𝑚𝑎𝑙[28], 𝜇𝐵𝑒𝑟𝑔𝑒𝑟𝑎𝑘[30])
= 𝑚𝑖𝑛(0; 1)
=0
3.5 Defuzzification
The picture below shows the membership function of the fuzzy output

Figure 12. Membership Function Of The Fuzzy Output


In this Sugeno fuzzy defuzzification process, the average method is used. From the example
case 1, the results of the defuzzification are as follows:

∝ 𝑝𝑟𝑒𝑑1 ∗ 𝑧1+ ∝ 𝑝𝑟𝑒𝑑2 ∗ 𝑧2 + ∝ 𝑝𝑟𝑒𝑑3 ∗ 𝑧3+ ∝ 𝑝𝑟𝑒𝑑4 ∗ 𝑧4 + ∝ 𝑝𝑟𝑒𝑑5 ∗ 𝑧5+ ∝ 𝑝𝑟𝑒𝑑6 ∗ 𝑧6


𝑧=
∝ 𝑝𝑟𝑒𝑑1+ ∝ 𝑝𝑟𝑒𝑑2+ ∝ 𝑝𝑟𝑒𝑑3+ ∝ 𝑝𝑟𝑒𝑑4+ ∝ 𝑝𝑟𝑒𝑑5+ ∝ 𝑝𝑟𝑒𝑑6

0 ∗ 20 + 0,6 ∗ 30 + 0 ∗ 20 + 0,4 ∗ 50 + 0 ∗ 30 + 0 ∗ 50
=
0 + 0,6 + 0 + 0,4 + 0 + 0
38
=
1
= 38

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
601
http://infor.seaninstitute.org/index.php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

Figure 13. Notification Output Results from Sensors installed in the Telegram Application

4. Conclusion
Based on the research that has been done, the authors conducted a case study test using input
and output functions, each of which has a variable, a fuzzy set, and a domain for the measurement range.
As for the input function, it consists of Getaran. (Vibration), which has a Normal set with a 0-20
domain, Waspada (Alert) with a 20-40 domain, and Gawat (Danger) with a 40-60 domain. The
vibration sensor is placed on the motorcycle handlebar so that it can detect the amount of vibration
generated. The next variable is Putaran Roda (Wheel Spin), which has a set of Tidak Bergerak (Idle)
with a domain of 0-20 and Bergerak (Moving) with a domain of 20-30. Infrared as a wheel rotation
detection device is placed on the motorcycle wheel.
In addition to the input function, there is an output function to give conclusions on all forms of
events that occur on motorcycles. The output variables consist of the Safe set with the 0-20 domain,
Caution with the 20-30 domain, and There are Thieves with the 30-50 domain. The output will send a
notification via the telegram application. So, if based on a research case study that has a vibration with
a value of 28 and a wheel rotation with a value of 30, the notification sent via telegram contains a Caution
message because the vibration value and wheel rotation are members of the Caution set in the output
function. Thus, the motorcycle will send a signal to the user if the motorcycle moves without the user's
knowledge through the user's telegram application and the user can act quickly and anticipate theft
actions that will occur on his motorcycle.

References
[1] McDono, C. The Changing Face of Vehicle Theft.

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
602
http://infor.seaninstitute.org/index.php/infokum/index
JURNAL INFOKUM, Volume 10, No.1, Desember 2021 ISSN : 2302-9706

[2] Novelan, Muhammad Syahputra (dkk). 2020. Sistem Kendali Lampu Menggunakan NodeMCU
dan Mysql Berbasis IOT (Internet of Things). InfoTekJar: Jurnal Nasional Informatika dan
Teknologi Jaringan Vol. 5 No. 1 (2020) Edisi September.
[3] Badan Pusat Statistik Provinsi Sumatera Utara. 2021. Jumlah Kendaraan Bermotor Menurut
Unit Pelaksana Teknis (UPT) dan Jenis Kendaraan (ubnit), 2018-2020.
[4] Badan Pusat Statistik Provinsi Sumatera Utara. 2021. Banyaknya Peristiwa
Kejahatan/Pelanggaran yang Dilaporkan menurut Jenis Kejahatan/Pelanggaran, 2015-2019. [5]
Budiyono (dkk). 2019. Rancang Bangun Sistem Alarm Pada Sepeda Motor Honda Beat FI
2014.
[6] Pachica, Archie O. 2017. Motorcycle Theft Prevention and Recovery Security
System.
[7] International Journal of Apllied Engineering Research ISSN 0982-4562 Volume 12 Number
11 pp. 2680-2687.
[8] Harys, Hafidzilhaj (dkk). 2014. Aplikasi Logika Fuzzy Untuk Prediksi Kejadian Hujan
(StudiKasus: Sub DAS Siak Hulu). Jurnal Online Mahasiswa Fakultas Teknik Universitas Riau
Vol. 1 No. 1 (2014).
[9] Sari, Syah Dia Putri Mustika. 2017. Penentuan Harga Dengan Menggunakan Sistem Inferensi
Fuzzy Tsukamoto Pada Rancang Bangun Aplikasi “Finding-Tutor”. Departemen Tenik
Informatika Fakultas Teknologi Informasi Institut Teknologi Sepuluh Nopember Surabaya.
[10] Salazar, Jordi (dkk). 2017. Internet of Things. Czech Technical University of Prague Faculty of
Electrica Engineering 1st Edition. ISBN 978-80-01-06232-6.
[11] Patel, Keyur K. (dkk). 2016. Internet of Things-IOT: Definition, Characteristics, Architecture,
Enabling Technologies, Aplication & Future Challenges. Department of Electrical Engineering
Faculty of Technology dan Engineering MSU. DOI 10.4010/2016.1482. ISSN 2321 3361.
[12] J. Sihotang, “Analysis Of Shortest Path Determination By Utilizing Breadth First Search
Algorithm,” J. Info Sains Inform. dan Sains, vol. 10, no. 2, pp. 1–5, 2020.
[13] C. Baturu, “Brute Force Algorithm Implementation Of Dictionary Search,” J. Info Sains
Inform. dan Sains, vol. 10, no. 1, pp. 24–30, 2020.
[14] H. Sunandar and B. Nadeak, “Analysis and Implementation of PlayFair Chipper Algorithm in
Text Data Encoding Process,” vol. 10, no. 02, pp. 19–23, 2020.

INFOKUM is licensed under a Creative Commons Attribution-Non Commercial 4.0 International


License (CC BY-NC 4.0)
603

You might also like