IoT-Based Smart Shopping Cart Using Radio Frequency Identification

The modern age of technology in which most of the customer needs to wait in the supermarket for shopping because it is a highly time-consuming process. A huge crowd in the supermarket at the time of discount offers or weekends makes trouble to wait in long queues because of a barcode-based billing process. In this regard, the Internet of Things (IoT) based Smart Shopping Cart is proposed which consists of Radio Frequency Identification (RFID) sensors, Arduino microcontroller, Bluetooth module, and Mobile application. RFID sensors depend on wireless communication. One part is the RFID tag attached to each product and the other is RFID reader that reads the product information efficiently. After this, each product information shows in the Mobile application. The customer easily manages the shopping list in Mobile application according to preferences. Then shopping information sends to the server wirelessly and automatically generates billing. This experimental prototype is designed to eliminate time-consuming shopping process and quality of services issues. The proposed system can easily be implemented and tested at a commercial scale under the real scenario in the future. That is why the proposed model is more competitive as compared to others.


I. INTRODUCTION
Sensors are electronic devices [1] that can collect information from the surrounding environment [2]. Wireless Sensor Network (WSN) is used to interfacing of multiple sensors to work together and share collected information wirelessly [3]- [5]. Isolated systems are less valuable then networked systems [6] which generate more intelligent and autonomous applications [7]. A wide range of information can be collected, when the coupling of the wireless sensors with networked systems [8]. IoT is directly or indirectly tightly coupling of communication network and sensor network where the data management and data processing achieved by monitoring these processes intelligently [9], [10]. The sensors and actuators have an important role in IoT that enables us to The associate editor coordinating the review of this manuscript and approving it for publication was Chih-Min Yu .
communicate with the physical world [11]- [13]. It consists of three terms physical, smart and connectivity [8], [11] which defines how smartly the sensors, microcontrollers, microprocessors and physical devices such as actuators which connect wirelessly or wired to manage information with other electronic devices [9]. IoT enables people to manage their lives, business in effective manners and provide fundamental changes to the world that can completely transform business and industry. The potentialities offered by the IoT make it possible to develop numerous applications that belong to the industry of aerospace and aviation, automotive, telecommunication, medical, healthcare, Independent living, Pharmaceutical, Transportation, Manufacturing, Retail, logistics and supply chain management [9], [14]- [16]. The most important objective of IoT is to monitor individual objects and environment wirelessly. This introduces electronic tags attached to individual objects. When these tags become in the range of reader it reads the stored information of object wirelessly which is known as RFID technology [17]- [19]. RFID plays an integral role in the applications of IoT. It consists of three components such as RFID tags attached to the object that contain identity or data about an object, RFID reader that read the data from the tags and central processing system that perform communication in between RFID system to other electronic devices [20]. It emerging a revolutionary effect on a wide range of applications like aircraft maintenance, anticounterfeiting, health care, baggage handling, and supply chain management [?], [21].
The merchandising process is the major part of the supply chain management that promotes the products to the consumers and distributors. Shopping is the activity in which a group of people uniting at one place for purchasing products. There are supermarkets or shopping malls that provide space for people to do shopping where retailers promote their products to the consumer and consumers purchase the product according to quality like ingredients, expire or not and brand of the product, reasonable price, and quantity of the product. This is also known as traditional retailing. Supermarkets are convenient for retail and urban planning. Supermarkets are the most crowded place at the time of the weekend. As most consumers have experienced, the basic steps involved in shopping are making a list, typically with pen and paper or on their mobile phone. They have to spend a lot of time in search of products in the whole supermarket one by one and spend time in long queues to pay bills. The waiting in-queues is negatively affecting [22] on human morale and may cause misunderstandings or conflict amongst people, for instance, when someone breaks the line and stands in front of other people [23]. That is not an ideal development because traditional marketing promotes many local jobs, city life, and urban culture. The supermarket also needs to personalized the inventory according to consumer preferences [24], [25]. Due to that online shopping attracts a large number of consumers that provide products through the internet and web browsers [69]. Consumers can receive the product from specified locations in the meantime by selecting products according to prescribed specifications, ingredients or instructions. Also, there is higher risk of fraud, lack of inspection, item may not work properly or defected, not be the same product as item pictured, transaction from stolen credit card, Phishing in which customer thinks that they purchase product from reputable seller, disruptor in retail industry and not provide the pricing negotiation [26], [27]. Instead of online shopping, people feel more valuable, entertain, enjoy and get the quality product with traditional shopping. In these critical situations, traditional shopping and supermarkets have to reinvent to survive in the current age. Shopping hubs or shopping malls are the places where several small business groups together known as a market.
Many people have shown their efforts from time to time to make a revolution in the traditional shopping. Many supermarkets are working with barcode technology [28]- [30] Mobile applications [31]- [34], Zigbee [23]- [25], [35], [37], Arduino microcontrollers [30], [37]- [39], RFID and wireless sensors [37], [40], [41]. Today barcode technology implemented and working in several supermarkets. Barcode is the continuous black vertical bars that have some stored information about an object. There is a smart trolley in which user self-scan every product by using ultrasonic sensors. Product id stored in barcode printed bars which are linked with backend databases [42], [43]. There is a barcode scanner that scans that printed barcode when it became in line of sight. That is a slow process than the RFID sensor system. Consumers or cashiers need to scan every single barcode to create bills and to check ingredients or specifications of the product. Barcode can only read, not writeable again, the scanner can read one barcode at a time and the barcode contains a very small piece of information in it [12], [29], [30]. This printed barcode can easily damage due to harsh climatic conditions. This can easily be hacked by a third-party user because does not support encrypted data form. The barcode system is a time-consuming process, which causes long queues. In 2009, Arkansas University completes the study to determine the business value of the RFID at the major retailer. That proofs the efficiency of RFID is better than the barcode system. According to their survey results, the accuracy of inventory management is improved by 27%, under stock decreased by 21% and overstock decrease by 6%. Because Barcode scanner scans 10000 items in 53 hours where RFID read in 2 hours [44], [45]. In traditional shopping systems, shopping carts are very helpful for the consumer to carry products. Installing a barcode with shopping carts enables the user to scan each product individually that consumes a lot of time, energy and makes it a bothersome process for the user. In other previous works, RFID reader implemented with an LCD display attached to the shopping cart that allows the user to interact with product information. Users are not able to interact with the complete or necessary information of products due to non-attractive and not user-friendly user interface [46]. RFID reader read the product RFID tag based on the Arduino microcontroller [30], [39], [44], [47]. Automation of billing process focusses on to provide the antitheft controlling system that allows the online transaction for the billing system [48]. In another system, mobile phone inbuilt NFC used to read the RFID tags [49]. Using RFID and ZigBee module [71] to make a more effective shopping process for the users where ZigBee transmits the information to the backend databases [13], [39]. Manually, by pressing buttons the user can return the product from the cart and also pay the bill by pressing a button then details transfers to the billing system through ZigBee [23], [70]. Provide the facility to cart communication that allows multiple users to do shopping together. There is a highsecurity risk of user's information safe and also need to modify the data transfer process. By localization of everything in the supermarket allows the user to locate the exact location of the product using data collection and filtering components based on IoT [50]. Supermarket can monitor and trace the customer. There is RFID based location-sensing technology that helps to identify direct or indirect privacy threats without VOLUME 8, 2020 losing supermarket relevant insights [68]. Further, RFID based smart secure shopping system is implemented on the bases of threat and security issues. Encryption and Decryption algorithms are used for the symmetric and asymmetric methods. That provides the security techniques based on encryption keys [70]. The focus of this study is to facilitate the supermarket and indoor marketing. Speech to text application based on Natural language Processing is also used to analyze the customer opinion and feedback about traditional shopping instead of online shopping [69]. Bolt-ESP IoT kit is used to manage the supermarket effectively. But the unattractive display is used to entertain the customer [72].
RFID plays a very vital role in the retailing process to manage products from the manufacturing to the Inventory and from inventory to the consumer. The major use of RFID technology is to trace the object. In this research, IoT based Smart Shopping Cart as shown in Figure 1 is proposed by using RFID sensors that used to make the shopping process much better than the previous efforts. RFID system embedded with a shopping cart that helps the consumer to purchase desirable and cost-effective products. As mentioned above, an RFID system consists of three main parts RFID reader, RFID electronic tag and central communication device [18], [20], [51]. Arduino microcontroller allows the android application to directly communicate with product information that is stored in the RFID product tag. There is an android application based on a user-friendly and attractive display attached to the shopping cart connected with the RFID system. This application provides services to the consumer i.e. display the product information, previous shopping history, manage a current shopping list, product promotions, special offers, product location to the consumer and RFID based login process for better security. When products come near to the RFID reader in the shopping cart. The consumer can interact with product information. This information extracted by mobile applications from backend databases stored in the server system. The consumer can also search for the desired product location in the supermarket via interact with a static map of the supermarket. The consumer can also interact with previous shopping history, product promotions, and special offers. That helps the consumer to remember products to purchase, manage shopping list and can get the best products according to the preferences. The main contributions of this paper are following: • RFID sensors with a shopping cart are proposed that connected with Mobile Application makes the consumer get desirable and the best quality products in the meantime.
68428 VOLUME 8, 2020 • The searching and shopping list management modules are added in Mobile Application which helps the consumer to find the location in the supermarket, to remember the shopping list and to manage the shopping list according to preference.
• The promotion module helps the supermarket to promote the product and offer special discounts to the consumers that can enjoy different product promotions and discount offers.
• Wireless communication will provide flexibility to the shopping and supermarket management system.
• The backend supermarket management system facilitates the supermarket to personalize its shelves and products according to consumer preferences.
The main focus of this study is to facilitate both supermarkets and customers. The proposed Architecture of this study provides the hardware and software solutions that help the supermarket to improve the quality of service issues and eliminate the time-consuming process of the shopping. The retail industries invest further in exploring the potential of these technologies for the novel services for their customers [68]. These novel services attract a huge number of customers that increase revenue as well. The innovation of the proposed study is the architecture model and services that come together to provide eco-friendly services in cost-effective manners. The organization of the paper is as follows. Material and Methods discusses in section 2 that presents the concept of automation of the shopping system based on RFID technology with a detailed description of the electronic and software components. In addition, Results and Discussions of the experimental prototype are provided, and conclusions are provided in section 3

II. MATERIAL AND METHODS
In the modern era, when the customer wants to purchase an item then the customer has to put the product in the shopping cart then cart's RFID reader [17], [52] read the RFID passive tag [53], [54] which attached to every product. Corresponding data regarding the product will be display on the Mobile application that is in front of the customer attached to the shopping cart. Architecture of the proposed methodology is shown in Figure 2.
Customers can easily interact with the interface and use different services of the proposed system. By using the proposed services, customers can select the efficient product put the product into the cart and the cost will get added to the total bill. After complete shopping, the billing will be done by the customer and details will be sent to the central server. The map given in the proposed system will locate the product present in the mall with the sectional specification for the ease of the customer. By using this system, customers can buy a large number of products in very less time with fewer efforts. Smart Shopping Cart consists of 4 basic elements hardware integration, software interface, wireless communication, and network database.

A. ELECTRONIC COMPONENTS
The electronic components needed to complete our proposed system are shown in Table 1.

1) RFID READER
RFID modules can read and write Mifare's tags and being sold at several web stores. The microcontroller and card reader use SPI for communication. The card reader and the tags communicate using a 13.56MHz electromagnetic field [55]. RFID Reader is working on the principle of induction of VOLUME 8, 2020  electromagnetic waves. RFID Reader emits electromagnetic waves through its built-in antenna and reads the reading of RFID tags in a specific range of 0-60mm. Whenever products RFID tags come in the range of RFID reader. It reads the data stored in RFID tags [17], [54].

2) RFID TAG
RFID tags provide the storage to store data. We use RFID passive tags which do not need any power supply from any battery that's why RFID passive tags are much more efficient than active tags. When RFID passive tags come in a range of Electromagnetic waves produced by RFID reader then induction produces flux. Due to this flux in coil power generates to the chip [41].

3) ARDUINO UNO
Arduino Uno is a Microcontroller board named Arduino Uno based on the ATmega328 series controller [57], [59]. You can control your board on what to do by sending a set of instructions to the microcontroller on the board. It facilitates the developers and programmers with the integrated development environment in which different operations can be performed easily. Like writing, compiling and uploading code to the microcontroller. Arduino Uno is an open-source prototyping platform based on easy to use hardware and software. It has 14 digital input and output pins and six analog inputs for communication with the electronic components such as sensors, switches, motors, and so on. It also has 16 MHz ceramic resonators, a USB connection jack, an external power supply jack, an In-Circuit Serial Programmer (ICSP) header, a reset button, GND pins used as a ground, and 5V pin used for supplying 5 voltages. Its operating voltage is 5V, with an input voltage of 7 to 12V. [60], [61].

4) BLUETOOTH
Bluetooth module [62] can easily achieve serial wireless data transmission. Its operating frequency is among the most   popular 2.4GHz ISM frequency band. It adopts Bluetooth 2.0+EDR standard. In Bluetooth 2.0, the signal transmit time of different devices stands at a 0.5 seconds interval so that the workload of Bluetooth chip can be reduced substantially and more sleeping time can be saved for Bluetooth. This module is set with serial interface, which is easy to use and simplifies the overall design/development cycle [63]. The HC-06 is a class 2 slave Bluetooth module designed for transparent wireless serial communication.
Once it is paired to a master Bluetooth device such as PC, smartphones, and tablets, its operation becomes transparent to the user. All data received through the serial input is immediately transmitted over the air. When the module receives wireless data, it is sent out through the serial interface exactly as it is received. The HC-06 will work with a supply voltage of 3.6VDC to 6VDC, however, the logic level of RXD pin is 3.3V and is not 5V tolerant. A Logic Level Converter is recommended to protect the sensor if it connects it to a 5V device like Arduino Uno and Arduino Mega [58].

B. SOFTWARE COMPONENTS
Software components control the electronic devices and data transmission from server to android mobile application and vice versa. Specification of the software components as shown in Table 2.

1) ANDROID MOBILE APPLICATION
An Android application is a software application, which will run only on the Android operating system because the Android operating system developed for mobile devices. A typical Android application is developed for a smartphone or tablet, which operates on the Android operating system. That application is installed in the android supported device, which embedded with electronic circuits of the shopping cart.

2) WEB-BASED SUPERMARKET MANAGEMENT SYSTEM
A web-based application is also developed to control the data manipulation process at the cashier or admin side known as the Supermarket management system.

C. EXPERIMENTAL DESIGN
During shopping whenever, the customer puts a product in the shopping cart. Then embedded electronic circuit, which consists of the RFID reader, Arduino Uno and Bluetooth modules that get the details of the products from RFID tag and sends it to the android mobile application. Customers can easily interact with product details on mobile applications and complete their shopping in the mean time.

1) CIRCUIT DESIGN OF ELECTRONIC COMPONENTS
The circuit design of the electronic components of the Smart Shopping Cart presents in Figure 3. The electronic circuit consists of Arduino Uno, RFID reader, RFID tag, Bluetooth module, and Display device. First, connect the RFID reader with Arduino Uno. MOSI pin of the RFID reader is connected to D11 pin of the Arduino Uno, MISO pin is connected to the D12 in of Arduino Uno, RST connected to D9 of the Arduino Uno, SDA is connected to D10 of Arduino Uno, SCK is connected to D13 of Arduino Uno, 3.3 voltage power supply pin of RFID reader is connected to 3.3 voltage of Arduino Uno and GND pin is connected to negative terminal of the battery.
Second, connect the Bluetooth module with Arduino Uno. Data transmission pins TX and RX pins of Bluetooth module connected to D4 and D5 pins of Arduino Uno. GND pin connected to the negative terminal of the battery and VCC pin connected to the 5-voltage power supply pin of the Arduino Uno. Microcontroller ATmega328 of Arduino Uno needs to program efficiently to control connected sensors and handle data transmission processes in between sensors and android mobile applications.
Step1: There is an electronic RFID passive tag attached to the product that has stored information about the product. When the product comes in the range of RFID reader module then it reads the RFID tag through electromagnetic waves. Electromagnetic waves produce induction and provide power to the RFID tag. In response, the RFID tag sends data to RFID reader wirelessly through radio waves.
Step 2: Electronic MFRC522 RFID reader module that connected to Arduino Uno. After getting data from the RFID tag, the RFID reader sends the data to the Arduino Uno through its connected pins.
Step 3: Arduino Uno is the intermediatory module of the electronic circuit, which connects and controls the RFID reader and Bluetooth device. After getting data from the RFID reader, it sends towards the Bluetooth module.
Step 4: Bluetooth module connects the electronic circuit to the android mobile application and helps to communicate with each other. When RFID reader reads the data from the RFID tag then it comes to Arduino. Arduino is responsible for the transfer of data between the android mobile application and Arduino Uno. The Bluetooth module provides a way to Arduino to communicate with the android mobile application.
Step 5: Android mobile application performs two major tasks first mobile application gets data of the product from the Arduino Uno by Bluetooth. Second, according to this data android mobile application gets the further detailed information about the product from the server computer and displays it to the customer on display.

2) AUTHENTICATION OF USER
When the customer comes to shopping. The customer needs to initialize the android mobile application, which provides the interface to the customer as we discussed in Figure 2 and Figure 3. In this scenario, Customer needs an eco-friendly environment during shopping which helps the customer to select the best quality product at the best price and consume minimum time to complete the shopping process. By login, customer can get services of the shopping cart that requires user authentication first. The working of this scenario is shown in Figure 4. The registered customers have to login to the system to enjoy special discount offers and promotions as a member of the supermarket. Non-registered customers do not need to login to use android mobile application services. But they cannot enjoy those offers and promotions which are currently available in the supermarket. Further discussed in next Results and Discussion section.

RESULTS AND DISCUSSION
Customers can login with two methods after the complete initialization of the android mobile application and RFID system. First, customers can enter the user name and password and Second, customers can use the user RFID card. The user RFID card is the passive RFID tag as we discussed in the electronic component section that contains a unique customer id. The customer id is the eight-digit unique numeric value stored in the RFID tag.
When RFID reader reads the customer RFID card, it sends it to Arduino Uno, then Arduino sends it to the android mobile application through Bluetooth and then android mobile application gets the data from the server according to this customer id and verify it is a registered user or not. If the verification of customer are not successfully confirmed, then the customer can use the user name and password option to enter manually into the system. The customers can also use a customer RFID card to enter into the smart shopping cart system automatically. After login successfully, the customer became able to use different services in the dashboard discussed in the preceding section of the smart shopping cart to complete its shopping. The experimental prototype is shown in Figure 5. The serial monitor output shows the identification of the customer RFID card that ID depends on the seven-digit code as shown in Figure 6. When the RFID reader reads the RFID card value then it sends to Arduino Uno which displays on serial monitor output that RFID properly sends it to the Android mobile application or not.

3) SEARCHING AND SHOPPING PROCESS
In this scenario, customers can successfully enter into the dashboard of an android mobile application where customers can find different types of services, which helps the customer to complete shopping in minimum time. To accomplish this task in an efficient way and to get the best quality product, shopping cart services reduce the obstacles and difficulties VOLUME 8, 2020 of shopping for customers. After the initialization of the smart shopping cart customer can login successfully by using login Authentications as discussed in the previous section. Then customer enters into the dashboard that consists of four major modules shopping history, product promotions, search product, and current shopping list. By using those module customers can easily complete shopping as shown in Figure 7 that display the complete work flow of the shopping process.

RESULTS AND DISCUSSION
When a customer successfully enters into an android mobile application dashboard, an attractive screen display in front of the customer. On this screen, there are previous shopping lists and promotion modules. In the previous shopping module, customers can see his/her last time shopping list. It helps the customer to remember his/her routine wise shopping items and maintain shopping according to budget. When customer login into the android mobile application, then according to this login information android mobile application extract the customer shopping history data wirelessly from the server and display it to the customer. Also, a promotion module displays the different special discounts and promotions of the products.
By selecting the desired product from the previous list of shopping or the promotion module, the customer can enter into the search module in which customers can see an indoor map of the supermarket. In this module, customers can select the desired category of the product, then the current location of the product display to the customer on the map of the supermarket if it is available in stock. After reaching the desired location, customers can pick the desired product and put it into the smart shopping cart. RFID reader reads the RFID tag of the product then the android mobile application fetches the data of the product from the server wirelessly according to this product RFID and displays product details to the customer on the mobile device. Now, it depends on the customer to select the product or not. The results of the experimental prototype are shown in Figure 8. Figure 8(a) and Figure 8(b) shows the results of the location of the products in the supermarket if it is available in inventory. The output of serial monitor describes the results of the Arduino Uno which is working as an intermediary device shown in Figure 9. The serial monitor shows the results of the product RFID that is scanned by the RFID reader and transfers it to the android mobile application as described in RFID_Data_Transfer algorithm. Also, this scenario is shown in Figure 8(d) that displays how the product RFID is added to the shopping list. There is a Bluetooth module connected with Arduino Uno that provides wireless communication between the mobile device and Arduino Uno.

Algorithm 1 RFID Data Transfer :
Initialisation : 1: Call Bluetooth_connection 2: if Bluetooth == connected then 3: Call Wi_Fi_connection 4: if Wi_Fi == connected then 5: for Scanning = connected to disconnect do 6: Scanning RFID_tag 7: if RFID_tag == Detected then 8: RFID_Data = CALL Transfer(RFID) 9: Display RFID_Data in Mobile device 10: else 11: Show Error try to scan again 12: end if 13: end for 14: else 15: Error in Wi_Fi connection 16: end if 17 if Commmuniation_is_established == True then 5: for Scanning = connected to disconnect do Error in connection. Wi_Fi setup is Failed. 18: end if 19: return RFID D ata The algorithms mention the communication processing of the shopping cart that how hardware communicates to each other to complete the shopping process successfully. Firstly, the algorithm 'RFID Data Transfer' are presents the communication of the sensor that how they get the RFID by reading from the RFID reader and transfer it to the Android mobile application. Secondly, the algorithm 'Transfer(RFID)' presents the communication of the mobile application to the server and retrieve the data according to the RFID. Then display this data to the customer on the android mobile application.

D. COMPARISON OF EXISTING AND PROPOSED SYSTEM
We use the Arduino Uno microcontroller, which helps to control the sensors of the electronic circuit that is controlled by the android mobile application. Different technologies like RFID sensors, Arduino Uno, Bluetooth, Wi-Fi, Supermarket management application and Android Mobile application embedded together to create an innovative automation shopping system. As shown in Table 3, these proposed model technologies never embedded together in related systems. Barcode technologies are used in the most supermarket instead of RFID technologies that are very time consuming process to scan every single product in the line of sight position. RFID technologies are uses in related works but they are not provide a friendly environment to the customer. ZigBee modules are also used to trace the shopping carts and multiple shopping cart share shopping information with each other that increases the security risks and cost of the system. The Proposed system implemented on wireless communication and provide different software-based modules that make it more reliable and flexible to the customer as well as to the supermarket.

III. CONCLUSION
In the aforementioned paper, the intended system design for automation of the shopping process by merging different technologies like Arduino Uno, RFID, and Android mobile application. That can be divided into two major categories Electronic components and Software components. In Electronic Components, Arduino Uno operating as an intermediary microcontroller, which controls the RFID technology and Built, communication between RFID technology VOLUME 8, 2020 and software components like android mobile application through Bluetooth module. In software components, there is an android mobile application in which customers login to the proposed system by using different proposed methods that can secure customer privacy. Searching for the product in the shopping mall becomes easy because of the searching module based on product position allocation on the map. The proposed system prevents the customer to get an expired or undesired product by providing an android mobile application. Customer directly interacts with the product information. This information affects the preferences of the customer about the product and helps them to get the best quality product. Shopping products can be displayed in a current shopping list of the customer that helps the customer to maintain its shopping list according to need or budget. That also helps to remind the remaining products to purchase. Besides, there is a server as a data center of the supermarket, which also connected with the smart shopping cart. When an android mobile application needs to extract data from the server, according to the customer RFID card for verification of the customer login or extract information of the product according to the product RFID tags, then the mobile application can communicate with the server wirelessly. This feature of wireless information extraction helps the customer to move freely and can easily interact with information of products anywhere in the supermarket. Those technologies are programmed to work together to entertain the customer most efficiently. BY using proposed technology customers can search and effectively get the best quality product. As a lesson receive a proposed system can easily be implemented in real-life scenarios to support the shopping process by automation of shopping cart.