Design and Implementation of Smart Parking System Using Location-Based Service and Gamification Based on Internet of Things

Information on the number of available parking slot capacity and trip routes to the destination parking area, and motivation in choosing a parking area location are parameters that can help two-wheeled vehicle users choose the right parking area location. The three parameters that determine the accuracy of selecting a parking area location are implemented in an Internet of Things (IoT) based smart parking system. This system can provide information about the maximum number of slot capacities and the number of available slot capacities at the parking area. Two-wheeled riders are given information about which route to take to the destination parking area by utilizing the Location-Based Service (LBS). These two features are then supported by applying the gamification method to motivate two-wheeled riders to choose the right parking area. The smart parking system is tested with considered Quality of Service (QoS) parameter and black box testing. The results of testing the smart parking system produce QoS performance on the Line of Sight (LOS) test, with an average delay is 71.66 ms, average jitter is 107.59 ms, and throughput is 23 kbps. Meanwhile, in the non-LOS test, the average delay is 132.88 ms, the average jitter is 200.84 ms, and the throughput is 12 kbps. Overall system performance obtained the percentage of reliability is 99.65 %, and availability is 99.65 %. In black-box testing, LBS and gamification methods can implement according to application requirements specifications.


INTRODUCTION
The population of Indonesia has increased in the last ten years. Starting from 2010 to 2020, the population in Indonesia has increased by 32.56 million people, or an average increase of 3.26 million people each year [1]. As the population increases, the demand for motorbikes also increases by 6.2% per year [2]. The use of the increasing number of motorbikes has made parking areas a necessity [3]. However, the limited location of the parking area can cause twowheelers to spend time and fuel in finding the location of the designated parking area [4], [5], [6]. This problem is followed by a lack of information regarding the maximum number of parking slot capacities and the number of available parking slot capacities. Twowheeled vehicle users also need to know the route they will trip to the desired parking area. In addition, there needs to be additional motivation for two-wheeled riders to balance the available parking area [7], [8].
Previous research by Eka Santi Wahyuningtyas, Rendy Munadi, and Sussi has made a smart parking application that can provide information about the parking capacity of two-wheeled vehicles. This application is integrated with the Radio Frequency Identification (RFID) sensor, placed at the entrance and exit gates of the two-wheeled vehicle parking area at Telkom University [9]. The weakness of this research is that the number of parking areas that are informed is limited to only one parking area, and the application used cannot show the route taken to the parking lot desired by two-wheeled riders. The use of a parking area limited to one location makes the Copyright  The second research conducted by Ginanjar Wiro Sasmito and Fuad Hadiansah has made an application that has a feature to inform about tourist objects in the Tegal area, Central Java. This application utilizes the Location Based Service (LBS) to implement the Tegal tourist attraction route which can provide information on the location of tourist objects, coordinate points , and support information about tourist objects in Tegal [10]. The drawback of this research is that this application cannot display the number of tourists in a tourist attraction in the Tegal area.
The third research was conducted by Kavisha Duggal, Lovi Raj Gupta, Ph.D., and Sravani Ammu in a paper entitled "Gamification Leads to Smart Parking", a research was conducted on the application of smart parking using the gamification method to motivate motorists to park their vehicles in the right way. The gamification method used in this smart parking system utilizes the point acquisition system obtained by the rider if it meets the criteria given. The criteria given are based on the location of the parking area, the accuracy of the parking position of the vehicle in the available parking slot, and how much time it takes the rider to park his vehicle in the slot provided [7]. The drawback of this research is that the smart parking system is only implemented on fourwheeled drivers.
Based on the existing problems, this research creates a smart parking system by utilizing Internet of Things (IoT). That can be accessed through an Android-based application used to provide information about the maximum number of slot capacities and slot capacities that are still available in a parking area. And can provide information about the route taken by two-wheeled vehicle users to the desired parking area. Data of the available capacity are obtained from the RFID reader sensor. Meanwhile, information on the route to the designated parking area was obtained using LBS [11]. The two features in this application are then supported by using the gamification method, which functions to motivate two-wheeled riders to be more precise in choosing the desired parking area [12], [13]. The smart parking system that was created measured concerning parameter Quality of Service (QoS) such as delay, jitter, throughput, reliability, and availability to determine network performance on the communication of RFID system device to Firebase. And also, the tested carry out with black-box testing to testing the functionality of parking slot capacity information, LBS, and gamification on the android application.

A. Smart Parking
Smart parking is one of the many technologies implemented in a smart city concept [14]. All devices in the parking area are integrated with electronic devices. This integrated device is then connected to internet connectivity to form an IoT [15].

B. Location-Based Service (LBS)
LBS is an information service with software orientation provided by mobile devices to perform control operations using location-based data [16]. This information service can be accessed using a mobile device via the internet network and can display the geographic position of the mobile device [10]. In this research, the implemented LBS service is information about the route taken by two-wheeled riders to the parking area.

C. Gamification
Gamification is a method of applying game techniques, game thinking, and game design to nongame activities. The purpose of this method is to motivate someone to achieve their goals [7]. Gamification consists of 4 semantic components, namely games, elements, design, and non-game context. Games are systems in which players engage in artificial conflicts, are determined by rules, and produce measurable results [8].
Gamification elements can be interpreted as elements that are characteristic of games found in many games and are significant to the meaning of games [8]. Gamification applies several elements in the game: points, leaderboard, achievement, level, story, clear goals, feedback, reward progress, and challenges [17]. This research applied the game elements are points and achievements. Point is a game element whose application occurs when the user completes certain activities in a game. Meanwhile, the achievement is a game element whose application occurs when the user reaches a particular achievement in a game.
Design is a component that distinguishes game design elements from game-based technology. Whereas technology in games includes technological aspects such as game engines or controllers, the definition of gamification refers explicitly to the deliberate design process [8].
The non-game context is an area where it is impossible to apply the game concept. This concept can be a potential opportunity to apply gamification to that area. The only context excluded by definition is game design elements within the game itself or in the game design process [8].

D. Internet of Things (IoT)
IoT is a node with intelligence and interoperability that is interconnected in a dynamic global network infrastructure. IoT applies any concept of connectivity from anywhere and anytime. Simply put, IoT is the ability to make everything around us intelligently connected to the internet and take into account the existence of a type of autonomy and privacy [18]. Something or object referred to in this discussion is a 65 Jurnal Infotel Vol. 13  physical object or virtual object [19]. Physical objects are represented in virtual objects to facilitate IoT application to society, especially in terms of conveying information data [20].  can communicate with each other either through a gateway or without going through a gateway. In this research, IoT implementation can be done in an application that informs the maximum slot capacity and available slot capacity in the parking area based on the number of two-wheeler riders who enter and leave using the RFID system. Figure 2 explained this research is implemented in two different parking area locations, so two RFID system devices are placed at each parking area location. Each RFID system device is placed at the entrance gate and exit gate of the parking area location. The four RFID system devices are connected in realtime to the Firebase realtime database via the internet network.  Figure 3 describes the Firebase console that can use as a database for stores data on the amount of available parking area slot capacity. This data is then sent to the application to find out information on the available parking area slot capacity. The application can inform the user about the destination parking area using a polyline and voice direction using LBS. In addition, the application also applies gamification elements consisting of points and achievement [12].  Figure 4 is the overall view from the hardware of the RFID system device that carries out in parking areas A and B. Figure 5 describes the device user needs to be connected to a power source to activate the components on the device. The device also requires an internet connection to transmit data to Firebase. The RFID tag is used to enter input data in the form of a User Identification (UID) read by the RFID reader. The data read on the RFID reader is continued to the microcontroller. In the microcontroller, coding has been done to identify which UID users are allowed to enter the parking area and which are not allowed.  The LCDs a description of whether or not users are allowed to enter the designated parking area. In addition, the input from the RFID tag is then processed by the microcontroller to make the process of adding or reducing the number of available parking slot capacities. After the process on the microcontroller is complete, the data is stored in the Firebase realtime database. The process of increasing the number of available parking slot capacity is carried out every time there is tapping by the user at the exit gate of the parking area. In contrast, decreasing the number of available parking slot capacity is carried out every time there is tapping by the user at the entrance gate of the parking area. Figure 6 explains that the smartphone used needs an internet connection and can use GPS service access because both are components needed to implement LBS on a smartphone [21]. With the fulfillment of these two components, users can get trip route information to the location of the selected parking area. Route information consists of 2 implementations. The first route information is implemented in a polyline direction, from the user's initial location to the destination parking area. They are parsing the JSON data implemented on these polyline lines.. JSON data is obtained based on the latitude and longitude of the user's initial position and the location of the intended parking area. In addition to polyline direction, users can also take advantage of voice direction, which is a route of the trip, by implementing the Intent class to move to the Google Maps application.

H. Gamification Design
The gamification method consists of implementing the point and achievement elements. Acquisition of points in the parking area can be divided into four conditions. The first condition, if parking area A has an available capacity of less than 30 and parking area B has an available capacity of more than 30. Parking area B is worth 50 points. Meanwhile, parking area A is worth 0 points. The second condition, if parking area B has an available capacity of less than 30 and parking area A has an available capacity of more than 30, then parking area A is worth 50 points.
Meanwhile, parking area B is worth 0 points. The third condition, if the two parking areas have available capacities above 30, then the two parking areas are worth 0 points. The fourth condition, if the two parking areas have an available capacity of below 30, then the two parking areas are worth 0 points. Users who have reached specific points get an achievement in the form of a pop-up window with a star image on it. Achievement appears in 3 different conditions. The user can achieve if the user has reached 1000 points, 2000 points, and 3000 points, as in Fig.7.

I. Application Design
The application called Parking Points is designed to contain several functionalities that users can use to determine the location of the designated parking area. The application is connected with several other support systems such as the Firebase realtime database, the Google Maps API, and the Google Maps application. Figure 8 explains the relationship between actors and systems contained in the use case diagram. Based on the use case diagram, the Parking Points application has four actors, each connected to the use case on the system. As the first actor, the user has connected to the use case sign in, sign up, check the acquisition of points, confirm the point and select the location of the parking area. By connecting the user to the use case, the user can run the Parking Points application functionality based on the connected use case. As the second actor, Firebase is connected to use cases related to account authentication functionality, account registration, point storage, and parking slot capacity information. Meanwhile, the Google Maps API and Google Maps application actors are related to using cases related to the implementation of LBS in the Parking Points application, namely information on route polyline direction and voice direction.  An application consists of several activities that users use to interact with the application. The following are some of the components in the application design used in this research. a) Splash screen activity Figure 9 describes user interface of splash screen activity that functions as the initial display for the user before entering the next activity. This activity has a duration of 2 seconds. After the duration of this activity is complete, another activity is displayed. b) The sign-in activity Figure 10 describes the user interface of the sign-in activity that functions to users to sign-in to their account before accessing application services. In this activity, users need to fill in the email and password that were previously registered. c) The sign-up activity Figure 11 describes the user interface of the sign-up activity that functions to register for an account if the user does not have an account to access the application service. Registration is carried out related to filling in the username, email, and password.  Figure 12 describes the user interface of the main activity that functions to select the location of the parking area. As information for the route, the user takes to the destination parking area. The route for this activity is informed in the form of a polyline direction. The number of available parking slot capacities and the maximum parking slot capacities are displayed in this activity. The amount of capacity can display by clicking on the marker, which is the location of the parking area. The marker color can also change according to the number of available parking slot capacities. e) The user profile activity Figure 13 describes the user profile activity that display user profile data such as username, email, and points obtained. The Pop-up window is implemented as an achievement to the user. This pop-up window appears three times depending on the achievement of the points earned by the user. Figure 14 describes user that has reached 1000 points can earn achievement with 1 star. The user that has reached 2000 points can earn achievement with two stars describes in Fig.15. Figure 16 describes user that has reached 3000 points can earn achievement with three stars.
g) The Google Maps application Figure 17 describes the Google Maps application that functions to provide voice direction services. This application is implemented by utilizing the Intent class in the Parking Points application to call the Google Maps application when voice direction services are needed. The Google Maps application in Fig.17

J. Quality of Service (QoS)
QoS is the overall characteristics of telecommunication services related to its ability to meet the needs of service users, both expressed and implied [22]. In this research, the measurement observes the packets sent from the system and measures several performance parameters such as delay, jitter, throughput, reliability, and availability.
According to the Telecommunications and Internet Protocol Harmonization Over Networks (TIPHON), the specifications for delay and jitter are presented in Table 1 and The throughput parameter measured by paying attention to the package received, and the total amount of delivery time, these two variables can be formulated as (1),

Throughput =
Packets received Total delivery time .
(1) A smart parking system needs to pay attention to two parameters in reviewing the system's success rate in carrying out its functions. The two parameters are reliability and availability. Reliability is the probability of the system carrying out the required functions under certain conditions and periods so that the system is run must allow it to be free from failure [24] Reliability = (Uptime-Downtime) Availability is the system's ability to perform the functions required during the system's life, or it says that availability is the probability that the system will not fail or is not being repaired when the system is needed [24] Availability = Uptime (Uptime + Downtime) × 100 %.
In (2) and (3), there are two variables determining the value of availability and reliability, namely uptime and downtime. Uptime is the total time the system 71 Jurnal Infotel Vol. 13  performs its functions. Meanwhile, downtime is the total time the system does not perform its function.

K. Black Box Testing
Black box testing or functional testing is a technique in software testing designed to perform functionality testing based on information from the software specifications being tested. This test does not focus on the source code mechanism of software but only focuses on the output produced in response to the selected input [25]. In this research, black box testing is used to test the application's performance in receiving input from users so that the output produced is by the specifications of the application requirements.

L. Hardware and Software
Implementing a smart parking system needed some hardware to develop an RFID system device that explained in Table 3. In addition, it also needs some software that is explained in Table 4. Table 3. Hardware Function.

Development board based Chip ESP8266 ESP-12F
As the main control center in the RFID system device RFID tag As an identifier when user tapping in RFID system device RFID reader Read UID of RFID tag when user tapping in RFID system device

Jumper cable
Connecting some of the hardware in RFID system device so that the hardware is integrated LCD 16x2 Displays some of the sentence based on condition when the user exit and enter from the parking area gate after the user tapping on the RFID system device Lithium-ion battery As the central resource in running the RFID system device Battery holder As the place put the lithium-ion battery in the RFID system device

M. Method of Testing System
System testing aims to test the fundamental research to see that the system is operating properly and correctly. In this research, the system is tested as follows.

A. Hardware Testing
The hardware in the RFID system tested consists of an RFID reader, a microcontroller, a lithium-ion battery, and a 16x2 LCD.  Table 5 explains every component contained in the RFID system device can function properly. The RFID tag detection test on the RFID reader can run as needed when viewed from the specified indicators. This condition cannot separate from the RFID tag detection by distance parameter on the RFID reader. Table 6 explains the maximum distance that the RFID reader can detect is 3 cm, while at a distance of 4 cm and 5 cm, the RFID reader cannot detect the RFID tag.

B. Testing of Parking Slot Capacity Information
The testing using black-box techniques on the Parking Points application. This test is done by testing the functionality of the Parking Points application [25].  Table 7 explains that every click made on a parking area location marker can display an info window informing the available parking slot capacity and maximum parking slot capacity. And Table 8 explains the color change from green which indicates a parking slot capacity of more than 200 slots, to a color change to red, indicating a parking slot capacity of fewew than 30 slots.

C. Testing of Location-Based Service (LBS)
The testing using black-box techniques on the Parking Points application. This test is done by testing the functionality of the Parking Points application [25].  Table 9 explains if the user chooses the location of the parking area with a distance of the user from the location of the selected parking area of more than 75 meters for parking area A and more than 50 meters for parking area B, then the route information is displayed in the form of a polyline direction. The user can use voice direction services by clicking the button provided. Meanwhile, suppose the user chooses the location of the parking area with the user's distance from the location of the selected parking area less than 75 meters for parking area A and less than 50 meters for parking area B. In that case, the route information is not displayed.

D. Testing of Gamification
The testing using black-box techniques on the Parking Points application. This test is done by testing the functionality of the Parking Points application [25]. Table 10 explains if one of the parking areas is in a condition where there are less than 30 available parking slots. And another parking area is in a condition that the parking slot capacity is more than 30 slots, then 50 points are obtained if the user chooses a parking area with a capacity of more than 30 slots. The points obtained for selecting the two parking areas can be worth 0 points if the condition of the two parking areas has an available parking slot capacity of fewer than 30 slots or more than 30 slots. Table 11 explains that the user can confirm the acquisition of points because the user is less than 10 meters from the location of the intended parking area. If the user is more than 10 meters from the designated parking area, the user cannot confirm the point acquisition.

Input Expected Output Output Produced
The point is 1000 points The star image in the pop-up window is one Appropriate The point is 2000 points The star image in the pop-up window is two Appropriate The point is 3000 points The star image in the pop-up window is three Appropriate

E. Quality of Service (QoS) Testing
The tested QoS parameters consist of delay, jitter, throughput, reliability, and availability. Parameters of delay, jitter, and throughput were tested using the Wireshark application by observing packet traffic filtered based on source and destination IP addresses with port 443 on communication between RFID system device to Firebase and vice versa. Meanwhile, testing reliability and availability were tested by measuring uptime and downtime using a stopwatch. a) Delay Testing Figure 18, if referring to Table 1, the average delay results resulted from the LOS test can be classified into the excellent category.  Figure 19, if referring to Table 2, the results of the average jitter resulted from the LOS test can be classified into the not good category. c) Throughput Testing Figure 20 describes tests in the LOS test that resulted in a higher throughput value than the non-LOS test.

d) Testing of Reliability and Availability
In Table 13, if referring to equations 2 and 3, the percentages for reliability and availability of the whole system are 99.65% and 99.65%.  IV. DISCUSSION The result that tested and measured then analyzed the result of the implementation of the design. The smart parking system consists of an RFID system device as a hardware component and Parking Points application as an Android application. Both of them have functionality and are needed. It can see from hardware testing that properly, this is because each function of the component is under the specified indicators. Such as on the RFID reader testing obtained distance variety for detect RFID reader, this is due to the use of the antenna on the RFID, tag which affects its operating distance. And application testing consists of parking slot capacity information, LBS, and gamification testing. Based on software testing obtained, the result can match the expected output because the application designed before the test was carried out has been adjusted to the expected application needs.
The QoS testing obtained results for the delay, jitter, and throughput parameter had better results in the LOS scenario than the non-LOS scenario. This scenario is influenced by the absence of obstacles during the LOS testing. The chance of a decrease in signal quality caused by the obstacle can be reduced [26]. Apart from the obstacle effect, fluctuating internet connections from time to time also affects these results. As well as, on the parameter of reliability and availability obtained a downtime of 300 seconds in 86700 seconds total tested. Downtime is obtained from replacing a lithium-ion battery with an exhausted electric charge with a fully charged lithium-ion battery.

V. CONCLUSION
Based on the test result, the smart parking system can display information on the maximum slot capacity and available parking slot capacity based on the tapping input made by the user on the RFID system when entering or exiting the parking area gate. The smart parking system can display trip route information taken by the user in a polyline direction and voice direction by utilizing the LBS service in the Parking Points application. The smart parking system can apply the gamification method by using point and achievement elements in the Parking Points application. Measurements of QoS obtained on the LOS scenario can generate better results in parameters delay, jitter, and throughput. The measurement of the whole system had resulted in reliability and availability above 99% for implementation in the parking area.