RFID Gazebo based simulator with RSSI and Phase signals for UHF tags localization and tracking.

Radio Frequency Identification (RFID) technology is becoming very popular in the new era of Industry 4.0, especially for warehouse management, retails, and logistics. RFID systems can be used for objects identification, localization, and tracking, facilitating everyday operators’ efforts. However, the deployment of RFID tags and reader antennas in real-world application scenarios is crucial and takes time. Indeed, deciding where to place tags and/or readers’ requires examining many conditions. If some weaknesses appear in the design, the arrangement must be reconsidered. The proposed work presents a novel open-source RFID simulator that allows modeling environments and testing the deployment of RFID tags and antennas apriori. In such a way, validating the performance of the localization or tracking algorithms in simulation, possible weaknesses that could arise may be fixed before facilities are applied on the field. Any number of tags and antennas can be placed in any position in the created scenario, and the simulator provides the phase and the RSSI signals for each tag. Every reader antenna is parametrized so that different antennas of different vendors can be reproduced. The simulator is implemented as a plugin of Gazebo, a widely used robotic framework integrated with the Robot Operating System (ROS), to reach a broad audience. In order to validate the simulator, a warehouse scenario is modeled, and a tag localization algorithm that uses the phase unwrapping technique and hyperbolae intersection method employing a reader antenna mounted on a mobile robot is used to estimate the position of the tags deployed in the scenario. The outcomes of the experiments showed realistic results.


I. INTRODUCTION
Today, Industry 4.0 aims at making use of the information and communication technology (ICT) infrastructure and the new smart technologies to improve the efficiency of manufacturing processes. Some of the main concepts pushed by such a new industrial revolution span many fields like telecommunications, robotics, artificial intelligence, computer graphics, and others. Machine-to-machine communication (M2M) or internet of things (IoT) [1] is used to improve communication and self-monitoring among the devices employed in the plant. Advanced robotics is meant to develop autonomous and intelligent systems that could reduce the intervention of human workers [2] in many of the crucial and repetitive tasks that represent the core business of companies. Augmented and virtual reality can give operators more information about their tasks [3] and help them to alleviate the mental stress during some jobs. Computer vision and artificial intelligence are becoming essential tools that are integrated into a wide variety of systems. One of the most diffuse application fields of such technology is certainly the quality inspection for the automatic defect detection in the production line [4]. However, even other aspects are increasingly acquiring importance. Additive manufacturing [5] is one of them since it can speed up the production process. The research for smart sensors or new materials that could open new opportunities to industrial applications [6] or the use of simulations systems [7] to test in advance new ideas before trying them on the field are some other aspects that are worth to be mentioned.
Robotic warehouse management and retails are real applications scenarios in which such new technologies are massively employed. For example, autonomous mobile robots, like the Kiva [8] ones, are used to move goods from the storage area to the production line where human workers or autonomous manipulators [9] with the help of computer vision or AI systems grab them to perform some operations. In addition, IoT and ICT systems monitor goods that go inside and outside the plant improving the management of the warehouse. Such organization allows for better management of inventories, making more accurate forecasts for the next quarter predicting future trends.
In the context of warehouse management, retails, and, more in general, logistics, Radio Frequency Identification (RFID) technology is becoming more and more popular [10] thanks to the declining cost and the improved durability and sensitivity. RFID is a special type of wireless communication that allows for the objects' identification using the data embedded in specific tags electronics and, exploiting the data collected by the reader(s), it also allows detecting the object's location [11]. Therefore, RFID is a convenient technology that facilitates the labor force in logistics and supply chain processes. However, the deployment of RFID systems in real-world application scenarios is crucial and takes time. The choice of tags and/or readers' locations is not trivial and requires considering many conditions. Indeed, once some weaknesses appear in the design, the deployment must be repeated all over again. Such kinds of situations are time and cost-consuming. Therefore, a simulator, which allows to model the scenario and deploy the RFID tags and antennas for testing and validating the positions and the algorithms in advance, would be beneficial. The present essay proposes an RFID simulator for ultra-high frequency (UHF) passive tags and fixed or mobile reader antennas. It is developed as a plugin extension for the Gazebo simulator, which is one of the most popular simulators in the robotics community thanks to its seamless integration with the Robot Operating System (ROS) framework. Even though Gazebo provides many sensors that can be employed directly in the virtual environment, it does not support any realistic RFID sensors. In particular, only a virtual RFID sensor is present in the Gazebo software distribution with a fake tag's implementation, which returns the tag position in the world coordinate. Of course, such a simplistic model does not allow for realistic tests and evaluations of the software to be deployed. This paper, instead, proposes a more realistic antenna-tag communication model. In order to validate the simulator, a warehouse scenario is modeled in Gazebo, and several tags are deployed on it to be detected. A mobile robot equipped with a reader antenna builds a map of the environment and, while navigating in the warehouse, collects the data from the tags detecting their positions thanks to a localization method based on hyperbolic intersection and phase unwrapping presented in [12].
The code of the simulator is available at the link 1 below. The remainder of the manuscript is organized as follows: Section II presents the background and the related works; Section III describes the simulator and the experimental details; Section IV discusses the results of the experiments; Section V concludes the paper summarizing the work.

II. BACKGROUND AND RELATED WORKS
Typically, an RFID system is composed of three main elements: one or more readers, one or more tags, and a host management system. The reader consists of a high-frequency module, a control unit, and an antenna. The tag, usually attached to an object, has an antenna and a chip that contains an identification code. The reader antenna queries tags by sending an electromagnetic interrogation signal, and tags send back digital data that usually represent the Electronic Product Code (EPC), univocally identifying the item the tag is attached to. The host management system collects all the data received by the reader from several tags into the scenario. RFID systems are categorized into four frequency bands depending on the working frequency: low frequency (LF) at 125 kHz, high frequency (HF) around 13 MHz, ultra-high frequency (UHF) in the range 860-960 MHz, and microwaves at 2.4 GHz. The lower the frequency, the shorter is the communication range between the tag and the reader antenna. In particular, the communication distance for LF and HF is lower than one meter, while for UHF, it reaches around five meters. RFID systems can also be classified depending on the tag technology. An active tag has a transmitter and its own power supply that is used to run the microchip and broadcast signals to the reader. A passive tag has no battery, but it exploits the power from the reader that delivers electromagnetic waves inducing a current in the tag's antenna. When an RFID reader antenna interrogates a passive tag, a signal providing both command and power is transmitted to the tag, which, on activation, returns the modulated backscattering signal to the reader. The phase of the complex signal backscattered by the tag mainly depends on the distance between the tag and the reader antenna but, it is also affected by the reader hardware circuits and the tag itself (see figure 1). Reader antennas can be stationary or mobile. Stationary readers are placed on doors, walls, or other static objects and have a long reading range. Mobile readers weight little (80 g) and are typically mounted on mobile platforms powered by batteries while the formers are preferred in large enterprises when the traffic of goods is high.
The working principle for locating passive RFID consists of measuring either the received signal strength indication (RSSI) or the phase of its backscattering signal. It is worth noticing that the phase measurements are highly sensitive to the tag-reader distance, and there is a cycle ambiguity in the phase measurements because an unknown number of full wavelengths can be contained in the tag-reader distance or, FIGURE 1: Schematics of the RFID communication. r is the distance between the reader and tags antennas. θ T X , θ RX , and θ T ag depends upon the electronic circuits and compose the phase offset φ 0 . in other terms, many possible distances could produce the same phase. Hence, small errors in the estimation of the tags' positions can compromise the system. Therefore, a laborious setup of the environment and a calibration phase could be necessary before the system can work properly. The same precision regarding the tag coordinates is not required with the RSSI since it is not sensitive to the tag-reader relative position. However, due to the noise in the measurements, the quantization error, and the signal-to-noise ratio, the precision of the localization achievable exploiting the RSSI is not always satisfactory for all the applications.
The RSSI for a detected tag can be formulated as: where D is the distance between the tag and the reader, λ is the wavelength, K RT is a constant that depends on the radiated power and the modulation coefficient of the tag, G R and G T are the gains of the reader and the tag antenna in the main path direction, and H i is the contribution of the ith multipath. In particular, the available RSSI measurement is the integer dB: The observed phase-distance model for the n-th reading can be written as: where φ 0 is the phase offset including the effect of cables and other reader components [13]. Equation (3) shows that the observed phase value φ n is the remainder of the phase rotation to 2π, revealing that the observed value wraps and repeats over the 0−2π interval. Therefore, the same observed value could be obtained from multiple antenna distances, depending on the number of cycles, generating ambiguity. The process of extracting the distance information from that observed value must take this phenomenon into account. Furthermore, even the phase offset, φ 0 , should be considered.
Several techniques have been proposed in the literature for achieving adequate performance in tag localization. Hightower et al. [14] introduced a trilateration method exploiting a distance attenuation model on the RSSI. Since the accuracy of such a method was largely affected by multipath and reflections, Ni et al. proposed the introduction of reference tags in the environment [15]. The disadvantages of techniques exploiting reference tags are the need for a relatively high tag spatial density and a full knowledge about the environment map. Many researchers modeled the RSSI signal with a standard radio frequency propagation model in free space [16] obtaining a rough distance estimation of the tag from the reader antenna. Indeed, RSSI is affected by reflection, interference (constructive and destructive), and absorption. However, by considering uniform radiation patterns, typical of omnidirectional antennas, it is possible to describe the signal attenuation as a function of the distance. Unfortunately, tags and readers antennas are directional in practice introducing another source of disturbance that with the multipath effects may invalidate the distance estimation. Therefore, such kind of solution should be limited to open space environments with low reflections. In order to efficiently estimate distances based on RSS only, there is the need to properly characterize several parameters like the antenna gains of both the reader and the tag, the alignment of the antennas, and others. As a consequence, the use of the RSSI measurement has been limited to an extra source of information. In the recent literature approaches, the relationship between the RSSI signal and the radar cross-section (RCS) [17] or the combination between RSSI and the signal phase [18] is exploited. RFID phase-based distance methods exploit consecutive measurements of the RFID signal phase over a short time. Phase measurements could be achieved employing time domain, frequency domain, or spatial domain techniques [19]. The frequency-domain technique can be efficiently used for estimating the distance of tags, sampling the phase at different frequencies [20]. The spatial domain technique allows the computation of accurate directions of travel of tags and requires multiple antennas [21]. The time-domain approach allows both the computation of tags velocities and their direction of travel enabling not only the localization but also the tracking of tags' motion [22]. To avoid the need for multiple antenna systems, and to increase the accuracy of localization, strategies in which a single antenna is moved in the environment to emulate a synthetic aperture radar (SAR) have been presented in the last years [23]- [27]. SAR methods provide good localization performance but usually require large computational costs. For this reason, they are suitable for offline reconstruction algorithms. In order to efficiently use the phase difference measurement, the phase angle signal should be conveniently unwrapped to become continuous in cases where the reader value presents jumps. The unwrapping technique has been recently introduced in RFID localization to eliminate the phase cycle ambiguity obtaining promising VOLUME 4, 2016 results [28], [29]. Recent approaches use synthetic aperture and phase-unwrapping on a SLAM-enabled mobile robot, solving a convex optimization problem to allow for real-time tags localization even in the 3D space [30] or exploiting a particle filter technique to be robust to multipath problems [31]. Tags tracking can exploit similar system structures and methods [32] in scenarios where tags are moving and antennas are fixed.
Simulating RFID facilities in an environment before deploying them can be time and cost-saving because it allows noticing the weaknesses in the actual deployment. Furthermore, a simulator allows to test and validate the performance of the detection/tracking algorithm in some particular scenarios and to experiment with different hardware characteristics even without physically having the devices. A few RFID simulators have been attempted in the past. One of the first RFID simulators was proposed in [33], where the authors introduced the middleware platform called Accada. Accada was an open-source RFID infrastructure implementing the interfaces defined in the EPC Network specifications by EPCglobal2 that was one of the predominant standardization efforts of the RFID community. The objective of the Accada platform was to address some of the application needs and constraints of passive RFID technologies at the lower level, mainly for what concerns the filtering and aggregation of the data. In the same period, another passive UHF RFID simulator realized in MathWorks Matlab Simulink was introduced [34]. It was based on a multi-processor hardware target, using a Texas Instruments TMS320C6416 digital signal processor. After a few years, RFIDSim [35] was proposed. It was an RFID simulation environment that facilitated the evaluation of RFID protocols in real-world applications by simulating signal propagation and RFID communication protocols. In particular, it supported different path loss, fading, backscatter, capture, and tag mobility models at the physical level and implemented the ISO 18000-6C UHF RFID communication protocol. The aim of RFIDSim was to facilitate the relative comparison of different transmission control strategies. A similar approach was followed in [36] proposing a simulation platform that relies on a discrete event simulator, designed to implement a part of the ISO 18000-6C communication protocol supporting path loss, backscatter, capture, and tag mobility models. Nowadays, they are old, no more available, and focused on the low-level communication issues between tags and reader antennas. Some of them are not open source and do not give the final user the possibility to model the environment in which the facilities will be deployed. In addition, none of the simulators can be easily interfaced with the tools used by the robotics community like ROS. The paper proposes an open-source plugin for Gazebo, the 3D simulator mostly used in ROS by the robotics community, that allows for a high-level RFID simulation. The objective is not to simulate the hardware characteristics of a specific vendor of RFID facilities but to give a general and configurable tool to simulate the data exchange between the tag and the reader antenna at a high level publishing the tag identifier, the RSSI, FIGURE 2: Schematic representation of RFID communication disturbances. Depending on the environment, several path can be followed by the radiofrequency signal: line-of-Sight, Non-Line-of-sight passing trough objects, diffraction, scattering and reflection. and the phase. The simulator would allow testing detection and/or tracking algorithms in the modeled environment in advance.

III. SYSTEM DESCRIPTION
The simulator has been developed in ROS Noetic as a plugin for Gazebo 11.5.1. There are plenty of sensors available in Gazebo that have been developed since its first version like for simulating RGB cameras, depth cameras, lasers, IMUs, bumpers, and others. However, concerning RFID, there is only a skeleton of a class with a bare implementation of an RFID tag that provides the exact tag position in the world frame. Of course, such a perfect behavior does not resemble any real-world sensors and will not be helpful to test any algorithm. On the contrary, the proposed plugin provides the unique ID of the tag sensor, the RSSI, and the phase of the backscattering signal. The ID can be used to identify the object to which the tag is attached, while the RSSI and the phase can be exploited to locate such a tag, implementing, for example, one of the methods cited in section II. The phase is implemented starting from the formulation of equation 3 by adding a noisy factor to take into account the effect of multipath that leads to the following equation: where n φ is a normally distributed noisy factor and n o ptional is another optional random variable that can be added by the user choosing among the most popular distributions (uniform, exponential, gamma, weibul, normal, lognormal, χ 2 , and cauchy).
For what concerns the RSSI signal, some simplifications have been applied to the model described in equation 1. In FIGURE 3: Warehouse environment an ideal environment, like the anechoic chamber, an RFID reader communicates directly with the tag at a distance D without interfering with any other object. However, objects and obstacles scatter and reflect the electromagnetic waves generating multiple propagation paths or, the direct path is partially or completely blocked by an object or a wall. In particular, RFID communication suffers from path loss, scattering, reflection, diffraction, and propagation within the dielectric material. Path loss is an important phenomenon in a wireless communication system that represents the attenuation of the radio energy between the feedpoints of two antennas. Several models can be found in the literature. Hashemi in [37] proposed a path loss model with variable environmental factors. Then, Leong in [38] improved such a model considering that, in a room, only one environmental factor can be used. However, it should be increased when walls are encountered as distance increases. Figure 2 graphically depicts some of these concepts. RSSI can become unpredictable in such situations, and a complex model should be designed to take them into account. However, some approximations can be considered without jeopardizing the results of the simulation. Referring to equation 1, the gain of the reader and the tag are considered equivalent, and the effect of the multipath and other uncertainties are included in a measurement error n RSSI , leading to the following equation in dB: where n RSSI is a Gaussian with a normal distribution. The proposed model is not intended to be used for specific hardware but is meant to be general. Indeed, the plugin allows specifying the various parameters discussed previously according to its own needs. For the reader antenna, the user can specify the frequency, the range, the phase noise, and the gain, which would be the same as the tag antenna. In addition, physical parameters, like damping coefficient and friction, can be selected. Tags can be spawned with the environment creation at the start of the simulation but can even be added at run-time. In order to test the simulator, an experiment has been carried out by reproducing a warehouse, placing various tags in the environment, and installing an antenna reader on a mobile robot. The robot first constructs the map of the environment, and then, while navigating, collects the data of the tag through the antenna and reconstructs tags' locations using the method described in [12]. It is worth noticing that no initial information (like from handmade measurements) is needed on the position of the tags. In the following, some aspects of the experiment are described in more detail.

A. WAREHOUSE ENVIRONMENT
An indoor warehouse scenario is used for the experiment, as can be seen in figure 3. In the environment, N RFID tags are located on rack. The reader antenna can process the data sent by a tag only if such a tag is within a specific range r, which is a parameter of the reader antenna that the user can specify. However, due to the high directivity of the antennas, the actual detection field is slightly different from the nominal circle. In order to consider such a situation, a perturbed radius can be modeled. Therefore the range becomes:r = r|1+n r |, where n r ∼ N (0, σ 2 r ). It has been proved in [39] that a value of σ r = 0.05 give measurements having a good matching with exprimental data. VOLUME 4, 2016

B. ROBOT KINEMATIC
The mobile robot used for the experiment is a Pioneer P3-AT (figure 4a: a rugged four-wheel skid/slip drive robot). It is a unicycle-like non-holonomic mobile robot with differential drive equivalent kinematics. Figure 4b shows the kinematics schematic of a skid-steered robot. The following assumptions are considered in the model without loss of generality: the mass center of the robot is located at the geometric center of the body frame; each pair of wheels rotates at the same speed; and, the four wheels are always in contact with the ground. By defining an inertial frame (X, Y) (global frame) and a local (robot body) frame (x,y), as shown in figure 4b, and assuming that the robot moves on a plane with a linear velocity expressed in the local frame as v = [v x , v y , 0] T and rotates with an angular velocity vector ω = [0, 0, ω z ] T , it is straightforward to calculate the relationship of the robot velocities as follows: where q = [X, Y, Θ] T represents the state vector describing the generalized coordinate of the robot that are the x and y position of the center of mass and the orientation of the local coordinate frame with respect to the inertial frame, andq = [Ẋ,Ẏ ,Θ] T indicates the vector of generalized velocities. Denoting ω i , with i = 1, 2, 3, 4 the wheel angular velocities of the rear-left, front-left, rear-right, and front-right wheels, and recalling the assumptions, it can be written that: Therefore, the kinematic model can be expressed as a function of the left and right angular velocities: where v = (v x , v y ) is the translational velocity of the vehicle with respect to its local frame, ω is its angular velocity, r > 0 is the wheels' radius, and d > 0 is the distance between the centers of the wheels. For the experiment, the robot is equipped with an Hokuyo laser scanner.

C. SLAM ALGORITHM
Navigation is the ability of a mobile robot to determine its position in the environment (localization) and to plan and execute the path to a target location, avoiding both static and dynamic obstacles. For navigation to work, it is very important to have a map of the environment, and the process of creating a map is called mapping. The GMapping algorithm [40] is used to build the map of the warehouse. It is a laser-based SLAM (Simultaneous Localization And Mapping) algorithm for grid mapping. The main idea is to use Rao-Blackwellized particle filters (RBPFs) to predict the state transition function. Based on onboard measurements, a large number of particles are used for state transition function predictions, with each particle representing a possible position of the robot. Since a large number of particles will cause a large amount of calculation and memory consumption, a proposal distribution is used to reduce the number of particles. In addition, adaptive sampling is introduced to prevent good particles to be removed from the filter. In the proposed experiment, data of laser sensor measurements and the robot odometry are used to build the 2D map of the environment. In particular, it creates an OGM (Occupancy Grid Map), which is filled by the integer values in the range from 0 to 100. A value of 0 means completely unoccupied, 100 means fully occupied (e.g., wall), and a special value of -1 indicates an unknown area. Figure 5 shows the map of the warehouse generated by GMapping.
Once obtained the map for the experiment, the robot navigates in the environment using the AMCL (Adaptive Monte Carlo localization) approach [41]. It is a probabilistic localization system for a robot moving in a 2D space and uses a particle filter to track the pose of a robot against a known map. In particular, the algorithm estimates the pose of the robot while it moves and senses the environment, given a map of the environment. It uses a particle filter to represent the distribution of likely states, where each particle represents a possible state that is a hypothesis of where the robot is. The algorithm starts with a uniform random distribution of particles over the configuration space, meaning the robot has no information about where it is. It can be equally likely at any point in space. However, when the robot moves, it shifts the particles to predict its new state after the movement. Whenever the robot senses something, the particles are resampled based on recursive Bayesian estimation that estimates how well the actual sensed data correlate with the predicted state. Basically, when the robot observes the environment, it discards particles inconsistent with such observations and generates more particles close to those that appear consistent. In the end, the particles should converge The ROS package move_base is used to move the robot in the simulation: given a goal in the world, it will attempt to send commands to the robot to reach it. The move_base node links together a global and local planner and maintains two costmaps, one for the global planner and one for a local planner, to accomplish navigation tasks.

D. RFID TAG LOCALIZATION ALGORITHM
In order to locate the position of the tags in the environment, the method described in the previous work [12] is used. The proposed method leverages a phase-distance model, exploits the synthetic aperture approach and unwrapping techniques for facing phase ambiguity and multipath phenomena. Indeed, considering the variations of the signal phase concerning the value assumed at a given reference time, namely the relative phase history of the complex signal, the constant φ 0 (phase offset) can be removed from (3), obtaining: The unwrapping technique adjusts the phase angles by adding multiple cycles when absolute jumps between consecutive phase samples are greater than or equal to the jump tolerance π. The constraint for the spatial sampling is chosen according to the Shannon theorem. It guarantees that the difference between two adjacent phase samples is lower than π preventing the phase unwrapping technique from failing. Given a general scenario in which a tag is located at position RF id and the reader antenna is mounted on a robot moving from position AP 0 to position AP 1 , as depicted in figure  6, the distance between the tag and AP 0 can be written as r and the distance between the tag and AP 1 as r + ∆r. Knowing ∆φ, it is possible to obtain ∆r via unwrapping. The distance d between AP 0 and AP 1 can be alternatively computed through the robot odometry or a more precise SLAM algorithm. Nevertheless, the only unknown variable to solve the localization problem is the distance r that will be found by circles intersection.
Choosing a value R as guess for r, it is possible to generate a circle with radius R centered in AP 0 and a circle with radius R + ∆r centered in AP 1 . In the most general case, the circles will intersect in two points that are symmetric with respect to the AP 0 AP 1 segment. A unique solution would exist if 2R + ∆r = d, while no solution can be found if 2R + ∆r < d. Figure 7 shows graphically the situation. The locus of all possible intersections can be obtained varying the value of R iteratively. The solution of this procedure is a hyperbola by definition, and its mathematical model is derived by analytic calculus. Therefore, trilateration applied on consecutive phase readings allows finding hyperbolae as the localization solution space. Analytic calculus is used to compute intersections among the conics that estimate the tag position. Starting from an initial position of the reader antenna and a nominal distance derived from the unwrapped phase history, a new conic is generated according to the above formulations for any movement of the robot, and hence the antenna, greater than an assigned stride size. Concurrently, a vector containing the current position of the reader antenna and the current unwrapped phase distance is stored. The next step of the algorithm performs the intersection between the novel hyperbola and all the previously obtained hyperbolae. The unwrapped phase distance phiDist n , and an estimation of the quality of the localization guess (E) would be allocated for each resulting intersection point. Therefore, the solution of the localization problem is the best estimation of the tag position, obtained by solving an optimization problem considering the set of all the found hyperbola intersections.
Such a method proved to be robust to the robot localization accuracy. Therefore, the use of the GMapping and AMCL algorithms in place of the original SlamCGS [42] does not alter the performance of the tag localization algorithm.

IV. DISCUSSION
In order to validate the simulator, the RFID tag localization algorithm described in section III-D has been tested using the data generated by the simulator in the warehouse scenario previously introduced. Ten tags have been placed on the ten racks, and the reader antenna has been installed on the p3at mobile robot. While the robot navigates autonomously in the scene employing the implemented SLAM algorithm, the reader antenna acquires the phase and the RSSI values by each tag within the receiving range. Table 1 shows the parameters of the reader antennas passed to the simulator for the tests. It is worth noticing that the values phase noise and rssi noise are some user tunable quantities that are multiplied to the normal distributions that model n φ and n RSSI in equation 4 and 5, respectively. the The trajectory followed by the mobile robot, the reference tag locations, and the reconstructed tag localizations are depicted in Figure 8 with a black line, filled magenta diamonds, and blue cross, respectively. The algorithm obtained a mean accuracy error of 15 mm on a path of about 22 meter. Figure 9 gives the VOLUME 4, 2016  estimation error for each tag with a max error of 39 mm and a min error of about 3 mm. Therefore, the localization method achieved comparable performance with the one presented in [12]. The proposed simulator is not limited to cases with one FIGURE 8: Tags localization results using the Hyperbole intersections algorithm FIGURE 9: Estimation error for each tag reader antenna moving on a plane but also can be used for tag localization algorithms that require a reader antenna moving even on the Z-axis. Figure 10 shows an example of the mobile robot equipped with the same reader antenna, which, however, can also move vertically within a range of 1.5 meters in the same scenario with just one tag. Figure  11 gives the unwrapped phase distance obtained by the phase measurement during the motion. The same concept of moving an element of the RFID instrumentation can also be applied to tags for tracking problems.
In addition, the simulator allows using multiple readers antenna at the same time for those algorithms that need to triangulate data for localizing the tag. Figures 12 and 13 depict the RSSI signal values in dBm of two antennas in the same scenario: one is attached to the mobile robot moving in the plane, while the other one is in a fixed position. For the moving antenna, figure 12 shows only the values for one tag, while figure 13 displays the RSSI values of all the available tags within the measuring range of the fixed antenna. The As can be seen from the experiment of tags localization using the hyperbole intersection method, the simulator allows for a quite good level of data fidelity to reality. The other examples presented in this section give an overview of the high potentiality of the simulator that can provide support for several functionalities that cover a huge variety of localization and tracking algorithms for the RFID community that are not elsewhere available in simulations.

V. CONCLUSION
Radio Frequency Identification (RFID) technology is becoming more and more popular in the new era of Industry 4.0, especially in the context of warehouse management, retails,  and, more in general, logistics thanks to the declining cost and the improved durability and sensitivity. RFID systems can be used for objects identification, localization, and tracking, facilitating everyday operators' efforts. However, the deployment in real-world application scenarios is crucial and takes time. Indeed, the choice of tags and/or readers' locations is not trivial and requires analyzing many conditions. If some weaknesses appear in the design, the arrangement must be reconsidered from scratch, and such kinds of situations are time and cost-consuming. Therefore, a simulator that allows checking apriori the position of tags and reader antennas by testing the developed localization and tracking algorithm can be beneficial.
The proposed work presents a novel RFID simulator that serves this purpose. It is integrated into Gazebo, a widely used robotic framework, to reach a broad audience and allows modeling the environment of interest and testing the deployment of RFID tags and reader antennas before being installed in the real scenario. The simulator gives the possibility to use multiple tags and reader antennas and place them in any position. In addition, depending on the requirement of the used localization and tracking algorithm, the reader antenna can be single or multiple, fixed or moving in the 2D space or even in the Z-axis, giving high flexibility to the user. Validating the performance of the algorithms, possible weaknesses that could arise in simulation may be fixed before facilities are placed on the field. The simulator provides phase and RSSI signals for each tag in the scenario, and every reader antenna is parametrized to mimic different antennas from different vendors.
In the essay, several proofs of the capabilities of the simulator are given. In particular, a warehouse scenario has been proposed, and a localization algorithm that uses the phase unwrapping technique and the hyperbole intersection method has been tested employing a reader antenna mounted on a mobile robot. While the robot navigates autonomously VOLUME 4, 2016 in the environment thanks to a SLAM algorithm, the reader antenna acquires the phase signal from the tags located on the racks of the warehouse. The estimation error of the algorithm is comparable to the one obtained in a real scenario in [12] showing realistic results.
Existing RFID simulators are old and focus on the lowlevel RFID protocol. The proposed simulator instead concentrates on the high-level data to test and validate localization and tracking algorithms. It provides many functionalities, and it is also integrated into a robotic framework that gives the possibility to merge several research fields.