An Improved Binary Search Anti-Collision Protocol for RFID Tag Identification

: Radio frequency identification (RFID) has been widespread used in massive items tagged domains. However, tag collision increases both time and energy consumption of RFID network. Tag collision can seriously affect the success of tag identification. An efficient anti-collision protocol is very crucially in RFID system. In this paper, an improved binary search anti-collision protocol namely BRTP is proposed to cope with the tag collision concern, which introduces a Bi-response mechanism. In Bi-response mechanism, two groups of tags allowed to reply to the reader in the same slot. According to Bi-response mechanism, the BRTP strengthens the tag identification of RFID network by reducing the total number of queries and exchanged messages between the reader and tags. Both theoretical analysis and numerical results verify the effectiveness of the proposed BRTP in various performance metrics including the number of total slots, system efficiency, communication complexity and total identification time. The BRTP is suitable to be applied in passive RFID systems.


Introduction
Radio frequency identification (RFID) is one of the most important automatic identification technologies used for identifying data stored in a tag's microchip using RF waves by wireless channel [Su, Sheng, Leung et al. (2019)]. Due to many merits such as non-contact, large data storage, and reusability, etc., RFID has been widely used in object management. As one of the ten emerging technologies in 21st century [He, Xie, Xie et al. (2019); Okhovvat and Kangavari (2019)], RFID is increasingly and ubiquitously digitizing the physical environment by attaching tiny tags to objects and people. Generally, core parts of an RFID network contain a reader and multiple low-cost tags. A tag is equipped with an unique identifier (ID) or electronic product code (EPC) when it is produced. The reader obtains the tag IDs through data exchange between them over a shared channel. When more than one tag reply IDs simultaneously to the reader, tag collision will inevitably occur and none of IDs can be successfully obtained by the reader [Klair, Chin and Raad (2010)]. The tag collision can seriously affect the success of tag identification. Therefore, an efficient anti-collision protocol is very crucially in RFID system. This paper focuses the tag collision issue and the corresponding anti-collision protocol for solving it. The mainstream anti-collision protocols can be divided into Aloha-based and tree-based protocols. The principle of Aloha-based protocols is based on random backoff mechanism. Thus, as a representative of a probabilistic protocol, Aloha-based protocol can be further divided into Pure Aloha (PA), Slotted Aloha, Frame Slotted Aloha (FSA), and Dynamic Frame Slotted Aloha (DFSA) [Porta, Maselli and Petrioli (2010); Chen, Liu, Ma et al. (2018); ]. In Aloha-based protocols, each tag responds to the reader with ID information at a randomly assigned slot. If a collision is detected, a tag should be required to retransmit its ID. The implementation process of Aloha-based protocols is straight and easy, but its system efficiency is usually low especially as the number of tags increases. In addition, due to the randomness of Alohabased protocols, they suffer from the tag starvation problem that some tags may not be successfully identified for a long time period. As a contrary, tree-based protocols eliminate the tag starvation problem very well. In essence, tree-based protocols do not cause tag starvation and can be divided into Query tree (QT) Jia, Feng and Yu (2012)] protocol, Binary tree (BT) [Guo, Hen and Wang (2016) ;Su, Sheng and Xie et al. (2019)] protocol and Binary search (BS) [Choi, Lee and Du (2010); Kim and Vinck (2018)] protocol. Among them, QT protocol is memoryless and generally has the advantages that tags do not need to be equipped with a counter, a number generator or memory like BT or Aloha-based protocol does. In the QT protocol, each tag is designed to own a prefix matching circuit that replaces the random number generator and counters in the Aloha-based protocols. From this point of view, the QT protocol is more suitable for low-cost tags. The reader probes tags by iteratively sending the query prefix, and the tags judge whether its IDs match the prefix according to the built-in matching circuit. The matching results are true, the involved tags return their IDs information, otherwise they are waiting for the next query. The reader maintains a pool to store the prefixes. The whole identification process is terminated when the stack is empty. Tag collision is a serious concern of the traditional QT protocol since there can be many collision queries during the tag identification process especially in a dense RFID network. Therefore, in order to improve the identification performance of QT protocol, many protocols have been presented in literatures [Jia, Feng and Yu (2012) ;Su, Han and Wen (2014) ;Shi, Wei and Huang (2008) ;Liu, Qian, Zhao et al. (2014)]. Jia et al. proposed and analyzed [Jia, Feng and Yu (2012)] an efficient anti-collision protocol for RFID tag identification named collision tree (CT) protocol, which eliminates the empty nodes of traditional QT protocol and thus enhance the identification efficiency up to 0.5. Su et al. [Su, Han and Wen (2014)] proposed a consecutive collision bits mapping algorithm (CCMA), which can further reduce the number of total queries by using M-ary collision arbitration mechanism. However, many additional mapping commands are introduced in RFID tag identification process which also increases the identification time. The performance of CCMA will be affected by the IDs distribution in the reader vicinity. Shi et al. [Shi, Wei and Huang (2008)] proposed an algorithm of Jumping Dynamic Search (JDS) Tree, which can reduce the transmission overhead by dynamically adjusting the search commands of the reader and the length of the return information of the tag, in addition, the back-paging strategy is introduced in the algorithm, and when the reader detects no collision occurs, the next search goes back to the parent node rather than restarting the search from the root node, which reduces the number of searches for the system, however, when the collision happens continuously, the algorithm does not make the corresponding optimization, but continues to carry on the backward search, the recognition efficiency is relatively low. Liu et al. [Liu, Qian, Zhao et al. (2014)] presented an adaptive collision tree (ACT) protocol, where the collision arbitration is based on M-ary tree according to the characteristics of the maximum two collision bits, the split of the algorithm is adjusted to binary tree division or quad-tree division. Although the ACT reduces the number of collision queries, it also introduces the empty queries, the efficiency of ACT still needs to be improved. Based on the above analysis, an excellent anti-collision protocol should meet three characteristics: 1) high identification accuracy, 2) minimal identification latency and 3) low time and energy consumption. In this paper, a novel anti-collision protocol for RFID tag identification namely Bi-response based tree protocol (BRTP) with improved performance has been proposed. In BRTP, the tag response can be split into two subcycles, in which two subsets of tags respond to the reader according to the Bi-response pattern. Both theoretical analysis and numerical results show that the BRTP outperforms the previous wisdoms in various aspects including system efficiency, total identification time and communication complexity. The rest of this paper is organized as follows. Section 2 gives preliminary information, such as Manchester code and related previous works. Section 3 describes the proposed BRTP in detail. The performance analysis of BRTP is given in Section 4, followed by the performance evaluation results presented in Section 5. Finally, Section 6 draws conclusions.

Preliminaries and related works
In this paper, our RFID scenario includes one fixed reader and many passive tags with low cost. Initially, the reader has no prior knowledge of tag cardinality or IDs of tags. This paper exclusively focuses on tag collision problem, namely obtaining all IDs of a given set of tags in time and energy efficient way.

Manchester code and bit tracking technology
QT protocols often use the bit tracking technology as a method of detecting the position of collided bits. Bit tracking is a technology that uses Manchester code ; Su, Chen, Sheng et al. (2017)] to identify the location of a collision bit, which represents a certain value of a bit using the voltage transition within a fixed time (called period). A bit "0" is defined as low-to-high voltage transition, while a bit "1" is defined as high-to-low voltage transition. In RFID systems, each tag returns data based on Manchester coding method. Thus, if two tags simultaneously transmit a bit of different values, then the high-to-low and low-to-high transitions of the received bit cancel each other out. Therefore, observed in Fig. 1, it is very intuitive and effective to use bit tracking technology to locate individual collision bits. Fig. 1 illustrates an example of Manchester code. The IDs of tag 1 and tag 2 are "01010011" and "00111001", respectively. When both tag 1 and tag 2 choose a same slot to respond with IDs using Manchester code, the mixed string at the reader side is "0xx1x0x1", where "x" means a collided bit. The example shows collisions in 2nd, 3rd, 5th, and 7th bits. The information obtained using bit tracking technology helps to further divide the collided tags into subsets during subsequent identification process, allowing the reader to identify them more efficiently and quickly.

Query tree (QT) protocol
The query tree (QT) protocol is based on reader-talk-first model, i.e., the reader sends a query prefix to probe whether a tag ID contains a specific prefix. Only tags whose IDs match the prefix can reply to the query command. If only one tag replies, it can be successfully identified by the reader. If there are more than one tag reply to the reader, a collision occurs, and the reader updates prefix by appending "0" and "1" to the previous prefix, respectively. The reader recursively probes the tags until all tags are successfully identified. The limitation of original QT protocol is obvious. If no tag replies to the reader in QT protocol, many additional empty queries will be generated. For example, the IDs of the two tags are different except for the last bit, the rest bits are the same. In order to identify these two tags, the reader needs to spend a lot of additional empty time slots. Therefore, the performance of the original QT protocol is very low. Later researchers used bit tracking technology to pinpoint the exact location of collision bits to improve identification performance. In the following, we introduce several representative QT protocols with bit tracking technology.

Collision tree (CT) protocol
CT protocol only focuses on collision bits and group collided tag set according to the highest collision bit in each query round. The tag receiving the query command only needs to return the remaining ID information except the matched part to the prefix.
Compared with the original QT protocol, the CT protocol removes empty queries in the identification process and reduces the number of transmitted bits.

Consecutive collision bits mapping (CCMA) protocol
CCMA protocol [Su, Han and Wen (2014)] is QT protocol based on multi-ary search. This protocol introduces custom query commands and collision bit mapping mechanism. The function of the collision bit mapping mechanism is to map an 2-bit collision bits into a 4-bit string containing only one "1". If the reader detects that the first and second collision bits are consecutive bits, then the reader will send a custom command QueryP to make the collided tags return 4-bit mapped data, which contains the collision information.
The reader can accurately recover the upper two collision bits of collided tags according to the mapped data, so as to generate the following queries. If the first and second collision bits are non-continuous, the reader will use the CT protocol to identify the tags.

Bit query strategy based M-ary query tree (BQMT) protocol
To fully explore collided bits and empty queries in the tag identification process, a bit query method is presented recently [Su, Chen, Sheng et al. (2017)]. The bit query method allows the tag to reply to the reader with a mapped bit string instead of its ID sequence. Compared to traditional ID query, the bit query not only remove empty queries, but can separate collided tags into many disjoint subsets and efficiently use the collided bits as well. According to bit query method, a bit query based M-ary query tree protocol is proposed, which iteratively resolves collisions by forming a M-ary traversal tree, and optimally switches from bit query mode to ID query mode for improving the identification efficiency.

Definitions
This section introduces the Bi-response based tree protocol (BRTP) in detail. And several definitions are presented at first. Feature bit: In the proposed BRTP, the feature bit is used by the tags to decide and choose one sub-cycle to transmit their IDs based on the Bi-response mechanism if their IDs match the common prefix from the reader's command. For example, assuming P1P2...Pk is the common prefix send by the reader, and R1R2...RL is a tag ID, if P1P2...Pk=R1R2...Rk, then Rk+1 is the feature bit. It is noted that if k=L, the reader is able to obtain the tag ID directly according to the duality of a binary value. Sub-cycle: In tag identification process, an identification cycle is defined as the time required for the reader and tags to complete a communication once. Such cycle includes the command sent by the reader until the reader receives the tag response, as shown in Fig. 2. Compared to conventional QT-like protocols, the proposed BRTP identifies more than one tags in a slot by means of Bi-response mechanism. Specifically, the reader splits a cycle into two parts: sub-cycle A and sub-cycle B. In sub-cycle A, the reader sends a query command to probe tags, and the tags whose IDs match the common prefix and the feature bit is 0 will feed back to the reader's query. In sub-cycle B, the tags whose IDs match the prefix and the feature bit is 1 will respond to the reader's query. Bi-response mechanism: As discussed above, the tags select responding sub-cycles to reply to the reader's query in a slot according to feature bit. Specifically, the tags feed back to the reader in sequence, first the tags with feature bit equals to 0 in sub-cycle A, then the tags with the feature bit equals to 1 in sub-cycle B.

Algorithm description
The detailed workflow of the proposed BRTP is illustrated in Fig. 3. Same as previous QT protocols, the reader also maintains a stack (it can be viewed as a prefix pool) to record and dynamically renew the query prefixes based on the collision information. Initially, the reader pops a prefix from the stack and sends a probe command with the prefix (an initial prefix is an empty string ε) to tags. The tags waiting to be identified within the reader coverage compare their IDs with the prefix and feed back to the query based on the Bi-response mechanism and the value of their feature bit. If the ID matches the prefix and the feature bit is "0", the tag responds with the rest ID after the feature bit in sub-cycle A. Similarly, if the ID matches the prefix and the feature bit is "1", the tag responds with the rest ID after the feature bit in sub-cycle B. If a collision occurs, the reader will generate new prefixes and push them into the stack according to the resolved data. And then the reader transmits query command (Com_Str,pre1,pre2) to probe tags in the following slots, where a parameter Com_Str denotes the common data part before the highest collision bit [Su, Sheng, Wen et al. (2016)]. If a slot is readable, the reader can obtain the ID of the tag. The reader repeatedly probes all the tags within its coverage until the entire stack is empty. Since BRTP probes more than one tag with Bi-response mechanism, it significantly reduces the communication time between a reader and tags. Tab. 1 describes in detail the complete communication process using BRTP to identify five tags whose IDs are "00111010", "10111110", "00001000", "01110001", and "11110101", respectively. As can be observed in Tab. 1, in each slot, there are tags from different groups responding to the reader query simultaneously in separated sub-cycles respectively with their rest parts of IDs if their IDs match the prefix. It is worth noting that from Fig. 3 and Tab. 1, the slot type in BRTP can be divided into three outcomes.  Successful slot: If the tag response can be received without no collision information, then the slot is named as a successful slot. In the example depicted in Tab. 1. the slot <3> and slot <4> are successful slots. In these two slots, the reader successfully identifies two tags, (A, C) and (B, E), respectively. Collision slot: If collision information is detected in both sub-cycles, the slot is called a collision slot. In the slot, the reader cannot obtain any useful tag ID information. Identifiable collision slot: If the collision information is detected in only one sub-cycle, and a certain tag ID is successful obtained in another sub-cycle, the slot is called an identifiable collision slot. Observed from the example, in Tab. 1, slot <2> is an identifiable collision slot. As described in Tab. 1, the proposed BRTP only takes four slots to achieve the compete identification of five given tags. Compared to existing anti-collision solutions, BRTP significantly reduces the number of queries. Although the time duration of an individual slot is prolonged, as the total number of queries is reduced, both time and energy efficiency will be greatly improved.

Algorithm description
To better highlight the advantages of the proposed BRTP, we made a detailed performance analysis of BRTP in this section. Through analysis, we can derive the following lemmas. Lemma 1. Considering that in an RFID network, the cardinality of tag set is n, then the minimum system efficiency of BRTP is 1. Proof: If the bi-response mechanism is not introduced, the identification process of the BRTP can be regarded as a complete binary tree, where an internal node on the tree corresponds to a collision node, and a leaf node corresponds to a tag. Suppose the number of tags to be identified is n, the number of internal nodes in Ni, the number of leaf nodes is Nl, and the total number of nodes in the binary tree is Nt, we can have Lemma 2. Assume the number of tags to be identified is n, then average communication complexity of BRTP can be approximated as Kcmd+1.5LID, where Kcmd and LID denote the length of reader's command and tag's full ID, respectively. Proof: Let Ct (n), CR (n), and CT (n) denote the total communication complexity, the communication complexity at reader side, and the communication complexity at tag side, respectively. We have where Since bit "0" and "1" appear with a probability of 0.5 in the tag identification process, according to statistical probability, ave fdb L can be approximated as 0.5LID, thus we have

Performance evaluation
In this section, we verify the performance of BRTP by selecting several excellent protocols including CCMA [Su, Han and Wen (2014)], CT [Jia, Feng and Yu (2012)], and BQMT [Su, Chen, Sheng et al. (2017)] for comparison. According to standard specifications, the data transmission rate is 160 kbps. We use MATLAB R2016a to simulate the identification of 50 to 500 non-duplicate tag IDs with 96 bits. The communication media is considered as no error-prone, as same as that in the previous literatures [Porta, Maselli and Petrioli (2010); Chen, Liu, Ma et al. (2018); Zhang, Zhang and Tang (2013); ; Zhu and Yum (2010)]. To ensure the accuracy of the experiment, all simulation results are the average of the results of the program running 1000 times independently. Fig. 4 shows comparison of the number of total slots of all selective protocols when the number of tags is between 50 and 500. As can be observed from Fig. 4, the number of total slots spent by the four protocols from high to low are CCMA, CT, BQMT, and BRTP, respectively. The reason is that the designed Bi-response mechanism enables multiple tags to feed back to the reader with their IDs in a same slot and thus significantly reduces the total number of queries. Specifically, the BRTP saves the total number of slots of CCMA, CT, and BQMT by an average of 54.9%, 50.1%, and 26.7%, respectively. , the system efficiency a common metric to evaluate the identification performance of RFID network by using anti-collision protocols. From Fig. 5, it can be observed that similar performance trends as in Fig. 4 can be found. The system efficiency of most protocols exceeds 0.5. Among the various protocols, the system efficiency from high to low is BRTP, BQMT, CT, and CCMA, respectively. Specifically, the BRTP improves the system efficiency of CCMA, CT, and BQMT by an average of 121.8%, 100.6%, and 36.5%, respectively. However, Considering the differences in the duration of time slots between different protocols, the actual performance improvement needs to consider factors such as communication complexity and total identification time. Therefore, next, we will discuss and compare the impact of these factors on performance.  Fig. 6 describes the communication complexity of all comparative protocols when the tag cardinality is from 50 to 500. From the results observed in this experiment, it can be found that the performance ranking of each protocol is different from that observed in Fig. 4 and Fig. 5. For example, the system efficiency of CCMA is higher than that of CT. However, CMMA is outperforms CT in terms of communication complexity. The reason is that although CCMA protocol consumes a large number of time slots than that of CT protocol, the duration of many slots is shorter than that of CT, so its total amount of transmitted bits is lower than the CT. Thus, the time efficiency of CCMA is potentially higher than CT. We can also observed that the proposed BRTP maintains the best performance in communication complexity. Specifically, the BRTP reduces the amount of transmitted bits of CCMA, CT, and BQMT by an average of 27.7%, 35.9%, and 19.5%, respectively. Fig. 7 further compares the total identification time of all comparative protocols when the number of tags is from 50 to 500. Because the total identification time takes into account the total time overhead of the reader and tags communication, it can reflect the time performance of the protocols. As can be observed in Fig. 7, the observed ranking is similar to that in Fig. 6. The proposed BRTP consumes the least time to identify the same batch of tags. Specifically, the BRTP reduces the total identification time of CCMA, CT, and BQMT by an average of 27.6%, 35.9%, and 19.5%, respectively.

Conclusions
In this paper, we presented an improved binary search protocol namely BRTP. The proposed introduces a novel collision arbitration mechanism called Bi-response mechanism. In Bi-response mechanism, multiple tags are allowed to feed back to the reader in a slot. Depending on the designed Bi-response mechanism, the proposed BRTP reduces the number of total slots significantly, communication complexity and total identification time. Both theoretical analysis and simulation results further indicates that the proposed BRTP outperforms the previous solutions. The BRTP is suitable to be applied in passive RFID systems.