IoT Technology Involving Wheeled Line Follower Robot for Restaurant Services Automation

This article discusses the design of a restaurant automation model that includes a computer program for receiving orders and sending bills as well as a wheeled robot which can deliver orders to customers automatically. In the restaurant model there are tables that have been attached with Radio Frequency Identification (RFID) tags placed alongside the track. The main equipment used includes Arduino Uno, NodeMCU, smartphone and computer. The test results showed that the system was able to accept orders. The robot was able to move forward by following the path to the intended table by reading the code on the RFID tag and stopping in front of it with a range of between 0.5 and 1.5 cm from the axis of the RFID card. Moreover, the system generates an invoice and email it to the customer.


INTRODUCTION
In general, restaurants could be grouped in two kinds namely take-away and eat-in restaurants. Daily activities in eat-in restaurants services include taking orders from customers, preparing food, serving food to customers' tables, providing bills and recording transaction reports which are normally done by humans. Problems that arise in restaurant services include the occurrence of errors in the delivery of orders and payment billing that cause customer inconvenience. These two errors are usually caused by mistake on the manual order recording by restaurant staffs probably due to less concentration, tiredness, handle too many orders in one time or any other factors. Preparing payment bill manually by staff also could be time consuming in busy hours such as in lunch time when many people come to the restaurant together in the short period of time.
Food delivery for customers in the restaurants could be automated by using conveyor belts (Chin, et al, 2019). However the drawback of this method is that there is less convenience and privacy for customers since the ordered foods are not served at their table directly but are moved along the conveyor belt route which could be seen by other customers. This drawback could be overcome by using a waiter robot in order to replace the human waiter. A line follower robot is a robot that moves along the specified trajectory line. Line follower uses line sensors such as in the form of photodiode and Light Emitting Diode (LED). LEDs are used to reflect light from detected objects and then the reflected light is captured by photodiode. The line follower robot could be employed in the environment where there is a line trajectory which will be used as the route of the robot. The usage of the line follower robot examples are in gas leakage detection alongside the distribution pipe (Supriyono & Hadi, 2017) and in computer controlled public transport (Gumus, et al, 2016). Attempts of using line follower robots for replacing waiters in restaurants have been attracted the interest of researchers. Line follower robot model for restaurant waiters where every table was equipped with a radio frequency based communication instrument for transmitting unique code to the kitchen in order to identify the intended table has been proposed (Ammanagi, et al, 2016). Then, based on this unique code the robot would be able to identify which table it should be reached.
Broadly speaking, the Internet of Things (IoT) technology is the way to connect a device or instrument to the computer networks or internet. Combination of line following robots and IoT for restaurant automation has been proposed by researchers for example in (Hamid, et al, 2019). In the proposed system, the robot was equipped with a keypad and Liquid Crystal Display (LCD) for receiving menu order from customers. After that, robot sent the menu chosen by customer to the kitchen for food preparation processing in wireless using Bluetooth. Finally robot able to recognize the intended table by counting the table because restaurant tables have been outlined in certain arrangement so that the number of table could be counted by using infrared sensor. Almost similar system was proposed where the menu was chosen by using keypad and then sent to the kitchen by using wifi and robot find out the intended table by calculating distance of table form the kitchen based on motor rotation (Shiny, et al, 2017). The disadvantage of these two research results is that the method on the table finding by robot by using counter and distance calculations are only effective if the tables arrangement are strictly unchanged. If there is a shift of table position, the potential of the robot finding the wrong table or robot reaching an empty place between tables would be high.
The publication on the combination of wheeled robot, Radio Frequency Identification (RFID), and computer network for restaurant automation model is still limited. The problem which would be solved in this article is how to record the food orders from customers with accurate information including location of the table automatically, serve the food to the customer table accurately and finally generate and send payment bills to the customer automatically. The restaurant services automation system would enable customers to be able order food by themselves using a smartphone and the data is then recorded in the computer server. This order information should be completed with a valid customer's email address and accurate table number. This record would be used by restaurant staff for the food preparation process. Furthermore, the wheeled robot would be used for servicing the food to the customer table. RFID code could be used for identifying intended tables accurately without being mistaken for other tables by the wheeled robot. After the wheeled robot servicing the food successfully and back to the base, the computer server will generate a payment bill and email it to the customer. By using this restaurant automation services, errors in delivery and payment bill could be eliminated. The objectives of this publication are involving: (i) to record the customer order accurately and automatically for food preparation process, (ii) to generate the bill and send it to the customer by email, (iii) to make wheeled robot find the intended table by reading the RFID code of the table.

METHOD
The development of the proposed model for restaurant services automation system consists of steps involving system architecture design, restaurant model layout design as the experiment test bed, hardware design, software design and testing.

System Architecture Design
The proposed system involves a wheeled robot which will be modelled for replacing humans as a waiter. The work of the whole system would be initiated by food ordering by customers using either smartphone or computer/laptop which is connected to the available computer network. The ordered food would be received by a server which then could be viewed by restaurant staff either using smartphone or computer for food preparation. After the food is ready, restaurant staff then command the robot to deliver the food to the intended table by pressing the table number button of the user interface display of the computer program either using a smartphone or a computer. The wheeled robot would be able to receive command to deliver the food to the intended customer who will be identified by using the table number. The whole architecture of the system is represented in the block diagram of Figure 1. In Figure 1, infrared sensors are used to read the line trajectory followed by the robot while RFID sensor or also called as the RFID reader is used for identifying the intended table. Arduino uno is used as the main processor for the wheeled robot will receive input from two infrared sensors and RFID sensors. Based on the reading of infrared sensors, Arduino Uno controls the Direct Current (DC) motor which is functioning as the actuator to move wheels of the robot.
In this article, the NodeMCU, an open source IoT platform, is used to receive commands from computer servers in wireless using thinger.io platform because Arduino Uno does not have this component. Moreover, command input received by NodeMCU is given to Arduino Uno using cable. Signal input of Arduino Uno from NodeMCU is actually a command signal from the server which has function as a switch to determine the table to be addressed and to activate the infrared sensor and RFID sensor. The RFID sensor then recognizes the identity code of each table which is installed with an RFID tag. The general computation process of the developed systems could be seen in the flowchart depicted in Figure 2. In the computation process, if Arduino Uno receives commands from the server via a smartphone or computer then it commands infrared sensors to read the trajectory line and send the data to Arduino Uno to control the DC motors (the wheels) so that the robot runs by following the trajectory line. Along the way, the RFID reader will read the RFID code of each table which is passed. The robot will stop when the RFID code of the table is matched. In every intended table, the robot would be given adjustable certain stop time which in this article is set to 10 seconds as a simulation and proof that this concept is working well. Robot counts down its given stop time and after the stop time is finished then it runs again and finally stops at the robot's starting point or customer service table to receive the next order. The system architecture of this publication is different from that proposed in (Gurav, et al, 2017) where the customers only could ordering food by using keypad based menu card attached on the robot and then the robot needs to run to the kitchen to display the ordered food to the staff for food preparation which is still time consuming and has potential for food delivery and payment bill errors.

Restaurant Model Layout Design
In this publication, a model of restaurant was used in the experiment. The model itself is not represent the actual restaurant. However, it is just functioning as a proof of concept. In this stage, the focus of this work is for modelling the food ordering process, payment bill generation and robot model would be able to find the intended table. Figure 3 shows a restaurant layout model plant which was designed to be the task environment for the robot where there is a trajectory line, three tables for customers, and one table for Customer Service (CS). The detailed dimension of the restaurant model is also provided.  Robot uses line sensors in the form of photodiode and LED. The LED is used to emit light from the detected object and the reflected light will be captured by the photodiode. In this experiment the floor of the restaurant model was made of white-colored plastic-based material with black line trajectory. The intensity of reflected light when detecting between the white floor and the black line will be different. When detecting a black line, the value of light intensity will be small so that produces a large voltage. This electricity voltage will be read by the Analogue to Digital Converter (ADC) instrument of the microcontroller. Thus, it can be seen whether the sensor reads the black line or not by comparing the different ADC values when detecting a white floor or black line. While for the tables, paper boxes with dimensions of 15 x 7 x 11 centimetres were used and each paper box has an RFID tag mounted on it which has different code on each tag. RFID tags could be contained with unique information such as unique code so that it would not be mistaken one with another. RFID tags were proven to be used as a unique identification including security for example for an electronic payment application (Nataliana, et al, 2019) and for electronic tickets of an event (Isnianto & Agustian, 2019).

Hardware Design
The schematic circuit design tool used in this step is Fritzing software and the obtained design is presented in Figure 4. This schematic is used to determine the location and connection of Arduino, NodeMCU, DC motors, motor driver, RFID module, infrared sensors, buzzer, I2C module, 16x2 LCD and two batteries 18650 3.7V. The batteries are used as the main source of voltage for the robot.

Robot Construction Design
In this article, the developed robot uses differential drive wheel arrangement, i.e. it has two fixed wheels which are controlled by separate actuators (Oriolo, 2014). As a proof of concept, the robot model is not designed to carry any actual foods or drinks. In this stage the main goal is how the robot is able to receive command from the server regarding which table should be reached, identify the targeted table by reading its RFID code, stop at alocated time and back to the base. The hardware construction of robots built in this article complete with its dimension is presented in Figure 5 and 6. The robot is made of a plywood box with a size of 20 cm x 10 cm x 8 cm as a frame and body of a robot. The robot has three wheels: one front wheel as a steering wheel and two rear wheels functioning as a power source to robot to make the robot move forward. Most of hardware components are placed inside the box as the line follower sensors are placed in the bottom part of robot, i.e. in front of front wheel. Because the robot moving will be in the clockwise, the RFID reader is mounted in the lefthand side of the outer robot body so that it would be able to detect and read RFID tag freely. The robot is equipped with LCD display to give information intended for the customer.  The first computation step is the Arduino always checks whether it is connected to the internet or not. If the Arduino is already connected to the internet and to the server, the restaurant staff then would be able to click the button of the user interface of computer display (depicted in Figure 8) or smartphone display (depicted in Figure 9) which table to be selected. If there is any button clicked, the computer or smartphone produces a signal with logic "1" that means to turn on the robot and then the robot will move following the trajectory line to the intended table. Besides choosing the intended table, the computer program is also used for processing of ordered food by customers. The steps of the computer program for processing food order are shown in Figure 10. The computer program is implemented using Google form and the contents of customer orders are stored in the Google spreadsheet and will automatically send invoices to the customer's email. Google form can be opened via the link bit.ly/Food_order. The interface of food ordering software is depicted in Figure 11. The use of smartphones and computers in this proposed system have advantages such as providing more simple and convenient food ordering system for customers besides the ordering process that could be done in parallel in comparison to ordering based on keypad proposed in (Afsheen, et al, 2018). Also, the use of smartphones would be more user friendly and simpler system architecture compared to keypad-like touchscreen proposed by (Bankar & Suresh, 2015). The use of smartphone in this publication for model of food ordering in restaurants also different from that has been proposed in (Mirgal, et al, 2018) where customers able to order food by using Android application, however, the food ordering system was not connected to automated food delivery by using robot.

Actual Robot Construction and Layout of Restaurant Model
The actual wheeled robot obtained in this article is shown in Figure 12, which is a model of a restaurant waiter. The robot was then tested on the restaurant model which has an actual layout depicted in Figure 13 to unveil its performance. The testing was done by simulation, i.e. the robot is simulated in a place that has been made to resemble the real situation. The restaurant model was made of white plastic material sheet with black line as trajectory printed on it. The restaurant model consists of four tables, i.e. one customer service table for restaurant staff and three customer tables.

Line Sensors Testing
There are two line sensors used by the robot. The robot will move following the black line. Testing was done by simulating it on the black line that has been made. Table 1 presents the test results conducted more than ten laps of restaurant model layout of Figure 13. All tests were successful which suggested that the line sensors were work consistently.

RFID Reader and Robot Stop Testing
The user interface display of a computer ( Figure 8) or smartphone ( Figure 9) has four buttons namely table 1, table 2, table 3, and CS. Each table has its own RFID tag mounted on it with unique RFID code. RFID reader detects and reads RFID code of every table that is passed by the robot. When the RFID code is matched then the robot will stop in front of the table abruptly otherwise it will continue to run passing the table and detect RFID code of the next table and so on until it finds the correct RFID code. In the experiment, the RFID reader used in the research has specifications only be able to detect and to read the tag which has distance within 2 cm from it.
The experiment was carried out as follows. The robot was given command to find the intended table starting from the CS table as its base. After that robot runs by following the trajectory line to find the intended table and then stops in front of it. Then the distance of the RFID reader of the robot to the axis of the RFID tag of the table was measured. After stopping in the set time, in this publication was ten seconds, the robot was expected to continue to run and stop at its base (in front of the CS table). For every table, there were five experiments conducted. The results showed that robot always able to find intended table correctly without mistake and stop in front of it, as can be seen in Figure 14, but with varying distance between RFID reader of robot and RFID tag of table were in the range from 0.5 to 1.5 centimetres as can be seen in Table 2. These results suggested that the robot worked consistently. Figure 14. Robot Stops in Front of Intended Table   Table 2. RFID Reader and Robot Stop Testing Results  Table 1 Stop ± 0.5-1.5 cm Passed Passed Stop ± 0.5-1.5 cm Table 2 Passed Stop ± 0.5-1.5 cm Passed Stop ± 0.5-1.5 cm Table 3 Passed Passed Stop ± 0.5-1.5 cm Stop ± 0.5-1.5 cm CS Passed Passed Passed Stop ± 0.5-1.5 cm

Button
The distance was caused by the delay time from the RFID reader detecting the RFID code and then Arduino providing a command for the DC motor to stop where the delay time was set equal to 500 miliseconds. After stopping for designated time, the display of LCD will be changed and then followed by buzzer on-off three times as the sign that the robot will continue moving forward to return to base, i.e. CS table.

Process of Ordering Food Testing
To order food, customers must fill in the form on the link provided namely bit.ly/Food_order. Customers provided accurate information including name, table number, and email address (the form can be seen in Figure 11). After filling in the form, the text of the form is recorded on the spreadsheet, which is stored on Google Drive, which can be seen in Figure 15. The restaurant staff then read the text and prepared the food according to it. In addition, after the customer fills out the form, the customer will directly receive a customer service email in the form of a bill that must be paid by the customer, as shown in Figure 16. After filling out the food order form and the customer has received the invoice, the food will be processed and prepared for the delivery process by the customer service and the food will be delivered by the robot to the customer's table.

CONCLUSION
Based on the experiment results, it can be concluded that the design of the restaurant services automation model has been working well as expected. The computer program of the proposed system was able to receive food orders from customers automatically which contain accurate information of food, table number, customer name, and valid email address. The wheeled robot was able to receive command from the computer program so that it knows the table number where the food must be delivered. The robot was able to move by following the trajectory line and recognized the intended table by reading the RFID code of each table and stopping in front of it precisely with the distance of between 0.5 and 1.5 centimeters from the RFID tag axis. Finally, the computer program generated the payment bill and emailed it to the customer successfully. However, it can be noted that the article is still in the very beginning stage that the wheeled robot and the restaurant layout have not been constructed based on actual condition. This publication could be extended by research focusing on how constructing robot models in actual environment conditions by including the type of food it could be carried and the speed of the robot in order to deliver food safely and timely.