1 | International Journal of Informatics Information System and Computer Engineering 1 (2020) 13-22 Enhanced the Weighted Centroid Localization Algorithm Based on Received Strength Signal in Indoor Wireless Sensor Network Medhav Kumar Goonjur*, Irfan Dwiguna Sumitraᶲ, Sri Supatmiᶲ *Orange Business Services (Mauritius) Ltd, Mauritius ᶲMagister Sistem Informasi, Universitas Komputer Indonesia, Indonesia A B S T R A C T S A R T I C L E I N F O A challenging problem that arises in the Wireless Sensor Network (WSN) is localization. It is essential for applications that need information about target positions, are inside an indoor environment. The Localization scheme presented in this experiment consists of four anchor nodes that change their position coordinates and one target node that is used to control the distance. The Localization algorithm designed in this paper makes use of the combination of two algorithms; the Received Strength Signal Indication (RSSI) and Weight Centroid Localization Algorithm (WCLA), called the RSSI-WCLA algorithm. The laboratory results show that the fusion between the RSSI-WCLA algorithm is outstanding than RSSI and WCLA algorithms itself in terms of localization accuracy. However, our proposed algorithm shows that the maximum error distance is less than 0.096m. Article History: Received 3 Nov 2020 Revised 20 Nov 2020 Accepted 25 Nov 2020 Available online 26 Dec 2020 e online 09 Sep 18 ___________________ Keywords: Indoor Localization, RSSI, WCLA, WSN. International Journal of Informatics Information System and Computer Engineering Journal homepage: http://ejournal.upi.edu/index.php/ijost/ International Journal of Informatics Information System and Computer Engineering 1 (2020) 13-22 Goonjur et al. Enhanced the Weighted Centroid Localization Algorithm Based on … –.| 14 1. INTRODUCTION Research on an indoor localization algorithm is a challenging problem due to the various number of complexities that arises in an indoor environment condition, including counting the nearness of impediments such as dividers, entryways, furniture, individuals within the room, and other components. Furthermore, indoor localization is more enticing and getting more attention from the research domain where GPS signal is not available to detect accurate positions in the building. In order to provide seamless localization and positioning service for indoor environment, some approaches in addition to Wireless Sensor Networks (WSN) have been successfully proposed to arrange accurate solutions as the primary key for Location-Based Service (LBS) (Zhang, S., & Xing, T., 2013). Addressing some of these issues, we can calculate the estimated positions using the distance of both the transmitter and the receiver that is known in the range- based scheme, among some of the conventional distance measurement algorithms, such as the AoA (Angle of Arrival), TDoA (Time Difference of Arrival), ToA (Time of Arrival), and RSSI (Received Strength Signal Indication). RSSI method to begin with employments the receiver nodes to recognize lost signal throughout communication, and calculate the positioning using at least three nodes as a beacon node, which already know of their coordinates. RSSI method does not necessarily need any additional hardware device or extra power, but communication bandwidth is required to calculate RSSI (Mukhopadhyay, B., et al, 2014). ToA calculates the signal of time through the transmitter to the receiver in the sensor node field. However, this method has drawbacks when using a ranging approach, and between the two nodes should be synchronized in precise clock. The time difference of arrival between the arriving node and the transmitter was measures by TDoA. For accuracy of time difference, the method is implemented to discover broadband signal. Measuring the time difference of arrival at a particular array element used AoA. It is capable of a narrowband signal. AoA needs other equipment to estimate arrival angel in wireless signals (Suzhe, W., & Yong, L., 2012). On the other hand, a range-free scheme also a popular algorithm for localization. According to network connectivity, these schemes can obtain the nodes location information. One of these methods is the classical Centroid Localization Algorithm (CLA) that was proposed by (Chen, M., & Liu, H., 2012). In this algorithm, all localized node estimate the centroid of all obtained beacon’s positions. However, CLA inherent bias is still significant. It can be outperformed by Weight Centroid Localization Algorithm (WCLA), which uses the received strength signal to quantify the anchor nodes in range and emphasizes nearer ones (Behnke, R., & Timmermann, D., 2008). On the other hand, a range-free scheme also a popular algorithm for localization. According to network connectivity, these schemes can obtain the nodes location information. One of these methods is the classical Centroid Localization Algorithm (CLA) that was proposed by (Chen, M., & Liu, H., 2012). In this algorithm, all localized node estimate the centroid of all obtained beacon’s positions. However, CLA inherent bias is still significant. It can be outperformed by Weight Centroid Localization Algorithm (WCLA), which 15 | International Journal of Informatics Information System and Computer Engineering 1 (2020) 13-22 uses the received strength signal to quantify the anchor nodes in range and emphasizes nearer ones (Behnke, R., & Timmermann, D., 2008). According to the pro and cons of two sorts of localization algorithms, this paper proposed a fusion between RSSI and WCLA in order to increase the estimated accuracy of the distance between target and anchor nodes in an indoor environment. We analyze the impact of a parameter within the RSSI to separate estimation. At that point, propose the framework demonstrate utilizing RSSI-WCLA, which is more convenient, lightweight, and practical. The comparison among these algorithms are shown in Table 1. There are six basic indoor positioning algorithms: proximity, AoA, ToA/TDoA, RSS, Dead Reckoning, as well as Map matching. Each of these algorithms have their own pro and cons to address the accuracy problem. In section II, we presented RSSI, CLA, and WCLA, which construct the fundamental of our proposed algorithm. The experimental setup is explained in section III, and after that section, IV has appeared the analysis of the test comes about. At long last, the conclusions are given within the final section. 2. LOCALIZATION ALGORITHM MODEL 2.1. RSSI BASED ON RADIO PROPAGATION CHANNEL Some radio propagation on the path loss models is commonly used, namely log-distance path loss model, free space propagation model, log-distance distribution model, hata model, and others. It is utilized because of multipath, fading, shadowing, and timely variation in the environment. The observed model used the shadowing model, which is used in wireless signal transmission. The relationship between separate and gotten control can be communicated concurring to the taking after equation: [𝑃𝑙 (𝑑)] = [(𝑃𝑙 (𝑑0)]𝑑𝐵𝑚 − 10𝑛 log ( 𝑑𝑚 𝑑0 ) + 𝑋𝑑𝐵𝑚 (1) In this model, 𝑃𝑙 (𝑑) signify the loss of path at partition distance set in dB relatively to 1 mW. 𝑃𝑟 (𝑑0) acted as the path loss for the reference distance. 𝑑0 is the reference distance which breaks even with 1 meter, dm is the distance between transmitter and receiver in meter, 𝑋𝑑𝐵𝑚 is a zero-mean Gaussian distributed random variable and the mean is zero. The standard deviation is commonly for 4-10. These values symbolize the strength signal changed that is obtained in a specific distance; the esteem of n depends on the particular propagation environment. Comparatively, n is equal to 2 in a free space environment. In addition, n has tremendous value when obstructions are present. Thus, it obtains the shadowing equation model, as shown in equation (2). [Pr(𝑑)] = [𝑃𝑟 (𝑑0 )]𝑑𝐵𝑚 − 10𝑛 log10 ( 𝑑𝑚 𝑑0 ) (2) Where, 𝑑0=1m, therefore the equation of distance measurement according to RSSI value is utilized within practical given by equation (3): 𝑅𝑆𝑆𝐼[𝑑𝐵𝑚] = [𝑃𝑟 (𝑑)]𝑑𝐵𝑚 = 𝐴 − 10𝑛 log 𝑑𝑖 (3) The measurement distance between target and anchor nodes as shown in equation (4) 𝑑𝑖 = 10 ( 𝐴−𝑅𝑆𝑆𝐼 10𝑛 ) (4) Goonjur et al. Enhanced the Weighted Centroid Localization Algorithm Based on … –.| 16 Where, 𝑑𝑖 symbolizes each anchor distance to the target node in a meter. A is a strength signal which accepted the distance 1m in dBm. 2.2. CENTROID LOCALIZATION ALGORITHM (CLA) CLA is the first and the most straightforward algorithm in range-free. It does not demand the use of any other parameter or RSSI to show the distance between a target and anchor nodes. CLA in the coordinate information is the only distance information type used, that point out whether a target node is in the anchor node communication range or not. CLA is able to communicate with the other node. In addition, it also performances from the theory that each anchor node covers a circular region. To make effective algorithm, the target node utilizes the all anchor nodes location information in its range to measure the centroid position (Behnke, R., & Timmermann, D., 2008) as follows: 𝑋𝑒𝑠𝑡 = ( 𝑥1+..……+𝑥𝑚 𝑚 ) ; 𝑌𝑒𝑠𝑡 = ( 𝑦1+..……+𝑦𝑚 𝑚 ) (5) (𝑋𝑒𝑠𝑡 , 𝑌𝑒𝑠𝑡 ) shows the target nodes position provide by its two-dimensional coordinates, (𝑥1, 𝑦1) is known as anchor node position, and m is anchor nodes number in the communication range. 2.3. WEIGHTED CENTROID LOCALIZATION ALGORITHM (WCLA) The accuracy of CLA location estimation has been upgraded by the extent of WCLA. WCLA introduced anchor node quantification which depends on their distance towards the target nodes. The purpose is to give more effect to the anchor nodes that are closer to the target node. Moreover, as the RSSI increases with a shorter distance, it is selected as a suitable quantifier. WCLA uses weight to guarantee an improved localization compared to the centroid method, where the arithmetic centroid is measured as an object’s location. Weight is anchor attraction measurement to object location. The most significant weight value is closer to the target node. To compute the weight, the below formula is used: 𝑤𝑖 = 𝑑𝑖 −𝑔 (6) Where 𝑤𝑖 represent the anchor node weight, and g is a level that defines each anchor node contribution. An appropriate value for g was found in one since WCLA with a degree of zero is similar to CLA. However, the appraisal target’s position is further calculated by the formula: 𝑋𝑒𝑠𝑡 = ∑ (𝑊𝑖×𝑥𝑖) 𝑚 𝑖=1 ∑ 𝑊𝑖 𝑚 𝑖=1 ; 𝑌𝑒𝑠𝑡 = ∑ (𝑊𝑖×𝑦𝑖) 𝑚 𝑖=1 ∑ 𝑊𝑖 𝑚 𝑖=1 (7) The disadvantage of this method cannot entirely reflect the actual condition of the target node due to the interference of path loss and only calculate the target node directly connected with anchor nodes. Thus, it largely depends on the anchor nodes density. 2.4. Description of the RSSI-WCLA Algorithm An algorithm that combines the RSSI and WCLA is proposed in this sub-section. Based on the free space propagation in an indoor environment (Kochláň, M., & Miček, J., 2014), the received strength signal can be indicated as: 17 | International Journal of Informatics Information System and Computer Engineering 1 (2020) 13-22 𝑃𝑅𝑥𝑖 = 𝐴𝑒 𝑆𝑟 = 𝜆2 4𝜋 𝐺𝑅𝑥 . 𝐺𝑇𝑥𝑃𝑇𝑥 4𝜋𝑑2 = 𝑃𝑇𝑥. 𝐺𝑇𝑥 . 𝐺𝑅𝑥 × ( 𝜆 4𝜋𝑑𝑖𝑗 ) 2 (8) The remaining wave power at the receiver from the ith anchor node is 𝑃𝑅𝑥𝑖 , the sender transmission power is 𝑃𝑇𝑥 . 𝐺𝑇𝑥 symbolizes the transmitter antenna gain. 𝐺𝑅𝑥 is the receiver antenna gain. The wavelength is represented by 𝜆. Distance between a target node i and anchor node j is represented by 𝑑𝑖𝑗 . The sufficient area of the receiving antenna is symbolized by 𝐴𝑒 and the power density of the signal at the site of the receiving antenna is symbolized by 𝑆𝑟. We can get the relation between 𝑃𝑅𝑥𝑖 and 𝑑𝑖 from equation (8). In the embedded system, the received signal strength is switched into RSSI. It is illustrated with the following equation: 𝑅𝑆𝑆𝐼𝑖 = 10𝑙𝑜𝑔 ( 𝑃𝑅𝑥𝑖 𝑃𝑅𝑒𝑓 ) (9) Where 𝑃𝑅𝑥𝑖 symbolize the received signal strength from the ith anchor node is, 𝑃𝑅𝑒𝑓 is the reference power. As a result we are able moreover to know the connection between RSSI and 𝑃𝑅𝑥𝑖 . From (8), we can modify the equation: 𝑑𝑖𝑗 = 𝜆 × √ 𝑃𝑇𝑥×𝐺𝑇𝑥×𝐺𝑅𝑥 4𝜋𝑃𝑅𝑥𝑖 (10) Based on (10), 𝑃𝑅𝑥𝑖 can be expressed as: 𝑃𝑅𝑥𝑖 = 𝑃𝑅𝑒𝑓 × 10 𝑅𝑆𝑆𝐼𝑖 10 (11) Substituting formula in (6) to (10), the anchor node weight can be expressed as: 𝑤𝑖 = 𝑑𝑖𝑗 −𝑔 = (𝜆 × √ 𝑃𝑇𝑥×𝐺𝑇𝑥×𝐺𝑅𝑥 4𝜋𝑃𝑅𝑥𝑖 ) −𝑔 = (𝜆 × √ 𝑃𝑇𝑥×𝐺𝑇𝑥×𝐺𝑅𝑥 4𝜋×𝑃𝑅𝑒𝑓×10 𝑅𝑆𝑆𝐼𝑖 10 ) −𝑔 (12) After 𝑤𝑖 normalization, weight can be expressed by: 𝑊𝑖 = 𝑊𝑖 ∑ 𝑊𝑗 𝑚 𝑗=𝑖 = √(10 𝑅𝑆𝑆𝐼𝑖 10 ) 𝑔 ∑ √(10 𝑅𝑆𝑆𝐼𝑗 10 ) 𝑔 𝑚 𝑗=1 (13) Thus, the estimation position of the target node can be expressed as below: 𝑋𝑒𝑠𝑡 = ∑ (𝑊𝑖 × 𝑥𝑖 ) 𝑚 𝑖=1 ; 𝑌𝑒𝑠𝑡 = ∑ (𝑊𝑖 × 𝑦𝑖 ) 𝑚 𝑖=1 (14) Where, 𝑊𝑖 is as the weight of the anchor node, (𝑥𝑖 , 𝑦𝑖 ) represent the location of the anchor node’s coordinate. From (13) and (14), it can be observed that we are able to get the estimated position of a target node by simply knowing the RSSI value and the coordinates of anchor nodes. Furthermore, a target node does not need to compute the path loss exponent and obtain other information parameters. Additionally, the proposed localization algorithm has the advantage of lower complexity. 3. TESTBED SETUP 3.1. RESULTS The main focus of the experiments was to deploy within the WSN indoor environment. The real-time experiments were conducted to determine the received strength signal of a wireless sensor network in the testbed environment. The experiment aims to obtain the RSSI values between anchor nodes and the target node. The testbed environment is the hall of a laboratory in at our university. The advancement pack utilized within this test is the Crossbow TelosB sensor node from Berkeley University, which uses a CC2420 transceiver with an IEEE 802.15.4 standard communication with a built-in 2.4GHz antenna. Goonjur et al. Enhanced the Weighted Centroid Localization Algorithm Based on … –.| 18 Table 1. Indoor Positioning Algorithms Comparison Algorithm Estimation Type Indoor Precisio n Scope LOS/NLOS Influence d by Multipath Cost Notes Proximity (Farid, F., et. al, 2013) Signal Low to high Good Both No Low a. Precision can be made strides by utilizing an extra receiving wire. In any case, it will be expanding the fetched. b. Precision in on the arrangement of the estimate within the cells. Direction (AoA) (Hou, Y., et al, 2018) Angle of Arrival Middle Good (multi- path issue) LOS Yes High a. Exactness depends on the antenna’s particular properties. b. The area of the receiving wire must be indicated. Time (ToA, TDoA) (Xu, B., et al., 2013) Time of Arrival, Time Difference of Arrival High Good (multi- path issue) LOS Yes High a. Needs time to synchronize. b. The area of the radio wire must be indicated. RSSI Received Signal Strength Indicator High Good Both No Middl e a. Require heavy calibration utilized flag engendering show. b. The area of the receiving wire must be indicated. Dead Reckoning (Farid, F., et. al, 2013) Velocity Low to Middle Good NLOS Yes Low Inaccuracy process is collective. Therefore, the deviation in the position settles with the time. Map matching (Ahmed, A., et al., 2011) Projection and pattern recognition Middle Middle NLOS Yes Middl e a. Mapping coordinate simply centers on the calculation and not totally on position strategies, arrange change, and geocoding. b. Utilizing design acknowledgment, tall computing complex, and common real-time issues happen. 19 | International Journal of Informatics Information System and Computer Engineering 1 (2020) 13-22 The testbed consisted of five Crossbow TelosB sensor nodes programmed with NesC programming language. The program used to converge the data and show the results through the sensor nodes were written in java programming language. For this study, we analyzed the information collected from the nodes which were programmed to send data in real-time. One of the sensor nodes was connected to a laptop which was utilized as the target node, as shown in Fig. 1. The remaining four sensor nodes that act as anchor nodes were placed at 0o, 90o, 180o, and 270o distance absence from the target node at the same distance whereas taking the measurements. Furthermore, the measurements were taken from a distance of 1m to 5m with an interim of 1m, and at each distance, readings were recorded for 2 minutes, giving a total of 500 readings. The mean value of each node RSSI accomplished at a given distance was calculated. Fig. 1. Illustration position of anchor nodes and target node 4. ANALYSIS OF EXPERIMENT RESULTS In this section, we analyzed the performance of the RSSI-WCLA algorithm through the experiment by changing the distance coordinates between the anchor nodes to the target node from 1m to 5m with d1=d2=d3=d4 respectively, and the target node is fixed as the center of measurement. In this experiment, the proposed algorithm is tested for distance 1m, and target node coordinate (1, 1), the anchor nodes coordinate are anchor1 (1, 2), anchor2 (2, 1), anchor3 (1, 0), and anchor4 (0, 1). Those anchor nodes obtain the RSSI values by the target node, as it is shown in Table 2. Table 2. The average RSSI values of the four sensor nodes Distanc e (m) Averag e RSSI (dBm) for node 1 (0o) Averag e RSSI (dBm) for node 2 (90o) Averag e RSSI (dBm) for node 3 (180o) Averag e RSSI (dBm) for node 4 (270o) 1 -43.3 -45.8 -44.6 -44.2 2 -47.8 -47.2 -47.8 -47.8 3 -48.8 -47.6 -49.4 -49.2 4 -53.4 -55.0 -51.2 -51.4 5 -55.2 -58.0 -53.6 -53.4 The RSSI values represent with cycles were spread out at each sensor node according to the location in every room corner, as shown in Fig. 2. Fig.2 The anchor node location in the room with its RSSI Goonjur et al. Enhanced the Weighted Centroid Localization Algorithm Based on … –.| 20 1) Localization measurement distance error in RSSI based on path loss Table 3 shows the error distance of RSSI according to the path loss measurement between anchor nodes and a target node. From Table 1, we can see that increasing the actual distance can increase the error distance; thus, the average error distance shows a 0.88m due to the attenuation of a signal, which is a result of environmental limitations. Table 3. Measured distance based on path loss Real Distance (m) Average of RSSI (- dBm) Estimation Distance (m) Error (m) 1 -44.5 1.01 0.01 2 -47.65 1.76 0.24 3 -48.75 2.16 0.84 4 -52.75 5.12 1.12 5 -55.05 7.22 2.22 2) Localization measurement distance error based on WCLA According to eqn. (7) Table 4 shows that the measured distance in WCLA is similar to the actual distance, with g = 1. Due to WCLA only obtaining the information of the anchor node through the position coordinate, we cannot get a significant distance error. Table 4. WCLA measured distance Actual Distance (m) Center Location Measured Distance (m) 1 1, 1 1 2 2, 2 2 3 3, 3 3 4 4, 4 4 5 5, 5 5 3) Localization measurement distance error based on RSSI-WCLA The algorithm process of RSSI-WCLA is as follows: Step 1: the anchor nodes send their relevant information, including their received signal strength, ID information, and position coordinates information to the target node in the form of broadcast. Step 2: calculate the weight Wi in (13). Step 3: calculate the estimated position of the target node in (14) Table 5 shows using a similar RSSI, and knowing the position of coordinate, we get the average error distance in our proposed algorithm as 0.0552m. The accuracy localization is 1-3% of the actual distance. Table 5. RSSI-WCLA Real Distance (m) Average of RSSI (- dBm) Estimation Distance (m) Error (m) 1 -44.5 0.992 0.008 2 -47.65 2.056 0.056 3 -48.75 2.904 0.096 4 -52.75 3.936 0.064 5 -55.05 4.948 0.052 In Figs. 3 and 4, despite the comparison of the distance between the actual distance and measured distance of the three algorithms under different coordinate numbers, both the anchor nodes relative with the target node, the proposed algorithm shows RSSI-WCLA obtaining nearly the actual distance value. It is different from the RSSI algorithm, where the increase of actual distance led to increasing the error of measured distance significantly. Although in Fig. 3, it can be observed that the error of distance has a significant influence on the RSSI localization performance in WSN when the distance is at a higher level. However, our proposed algorithm shows that the 21 | International Journal of Informatics Information System and Computer Engineering 1 (2020) 13-22 maximum error distance is less than 0.096m. Fig. 3. Comparison of actual distance with the result of distance through an experiment 5. CONCLUSION We proposed a localization algorithm that combined RSSI and WCLA (RSSI- WCLA). Comparing this novel algorithm to the RSSI algorithm and WCLA, our algorithm appears that the exact area of the target hub is more precise, lightweight, and less complicated; due to getting the estimated position of the target node by just mere knowing the RSSI values and the coordinates of anchor nodes. The RSSI-WCLA obtains the average distance error of 0.0552m, whereas the average distance error in RSSI is 0.88m, which impacts as it was utilized received strength signal. Overall, our results demonstrate a strong effect of indoor localization. The further of our research, we would like to test our algorithms as well as the devices in a large room with more anchor nodes attached to the wall. Fig. 4. Comparison error of distance on RSSI, WLCA, and RSSI-WLCA Algorithm REFERENCES Ahmed, A. M., Zhu, W., & Bekele, T. M. (2011). Map-matching and positioning uncertainty in Location Based Services (LBS). In Proceedings of the International Conference on Asia Agriculture and Animal. Behnke, R., & Timmermann, D. (2008, March). AWCL: adaptive weighted centroid localization as an efficient improvement of coarse grained localization. In 2008 5th Workshop on Positioning, Navigation and Communication, 243-250. Chen, M., & Liu, H. (2012, August). Enhance performance of centroid algorithm in wireless sensor networks. In 2012 Fourth International Conference on Computational and Information Sciences, 1066-1068 Goonjur et al. Enhanced the Weighted Centroid Localization Algorithm Based on … –.|22 Farid, Z., Nordin, R., & Ismail, M. (2013). Recent advances in wireless indoor localization techniques and system. Journal of Computer Networks and Communications, 2013. Hou, Y., Yang, X., & Abbasi, Q. H. (2018). Efficient AoA-based wireless indoor localization for hospital outpatients using mobile devices. Sensors, 18(11), 3698. Kochláň, M., & Miček, J. (2014, July). Indoor propagation of 2.4 GHz radio signal propagation models and experimental results. In The 10th International Conference on Digital Technologies 2014, 125-129. Mukhopadhyay, B., Sarangi, S., & Kar, S. (2014, February). Novel RSSI evaluation models for accurate indoor localization with sensor networks. In 2014 Twentieth National Conference on Communications (NCC), 1-6. Suzhe, W., & Yong, L. (2012, December). Node localization algorithm based on RSSI in wireless sensor network. In 2012 6th International Conference on Signal Processing and Communication Systems, 1-4. Xu, B., Sun, G., Yu, R., & Yang, Z. (2012). High-accuracy TDOA-based localization without time synchronization. IEEE Transactions on Parallel and Distributed Systems, 24(8), 1567-1576. Zhang, S., & Xing, T. (2013, December). Open WSN indoor localization platform design. In 2013 2nd International Symposium on Instrumentation and Measurement, Sensor Network and Automation (IMSNA), 845-848.