Measurement 78 (2016) 73–82
Contents lists available at ScienceDirect
Measurement journal homepage: www.elsevier.com/locate/measurement
A low-cost centimeter-level acoustic localization system without time synchronization Caiming Tan a, Xinhua Zhu a,⇑, Yan Su a, Yu Wang a, Zhiqiang Wu a, Dongbing Gu b a b
School of Mechanical Engineering, Nanjing University of Science and Technology, Nanjing 210094, China School of Computer Science and Electronic Engineering, University of Essex, Essex CO4 3SQ, UK
a r t i c l e
i n f o
Article history: Received 3 June 2015 Received in revised form 28 August 2015 Accepted 30 September 2015 Available online 9 October 2015 Keywords: Acoustic ranging Time synchronization Localization Indoor positioning
a b s t r a c t In this paper, we present a range-based localization method without time synchronization. It uses only a speaker, a microphone, and some forms of device-to-device communication such as WIFI radio; thus, it is easily applied in most commercial off-the-shelf mobile devices such as cell phones. The localization scheme is composed of two stages. We obtain the initial distances between the moving object and the anchors in the first stage using a BeepBeep ranging system, in which they both send and receive sound signals. In the second stage, which is the main localization stage, the difference distances between the moving object and the anchors can be obtained using a OneBeep ranging system. Only the located object must emit sound signals periodically, and all of the anchors including the located object should receive the sound signals in the OneBeep system. The distances between the moving object and all the anchors can be obtained by adding the difference distances to the initial distances, and then, the moving object can be located. A localization experiment was conducted in a 6 9 m room with weak reflection, and the localization can reach centimeter-level accuracy in 5 min. Ó 2015 Published by Elsevier Ltd.
1. Introduction Many range-based localization algorithms have previously been proposed, of which the Time of Arrival (TOA) and Time Difference of Arrival (TDOA) are popular. In the TOA method, the sender–receiver distance is the product of the propagation time and the propagation speed, and given the speed, the distance can be obtained by measuring the propagation time [1,2]. Time synchronization between the sender and receiver is required in TOA [3]. To compute the distance between the transducers (speakers) and the object to be localized (microphone), TOA measurements of acoustic signals that consisting of Binary Phase Shift Keying modulated Gold sequences are performed as in [4]. A previous paper [5] presented an ⇑ Corresponding author. E-mail address:
[email protected] (X. Zhu). http://dx.doi.org/10.1016/j.measurement.2015.09.037 0263-2241/Ó 2015 Published by Elsevier Ltd.
acoustic localization system for indoor use that was based on the TOA and fingerprinting technique. Experimental results showed that the location system generally provide an accuracy of less than 10 cm. TDOA is generally known as the method that obtains the difference distances between the sender and different receivers by measuring the time difference of the signal arriving to different anchors. At least three receivers are needed in the two-dimensional position program. Given the difference distance between the sender and two of the receivers, the sender should be in a hyperbolic curve due to the difference distance and the given position of the receivers. With the addition of a second hyperbolic curve, an intersection can be formed, that is the position of the sender. Time synchronization between the sender and receiver is not needed in TDOA, but the time synchronization between the receivers is required. TDOA is widely used to locate sound sources [6–9].
74
C. Tan et al. / Measurement 78 (2016) 73–82
Because time synchronization is usually required in TOA and TDOA, more hardware and software components are necessary and accordingly affect the localization accuracy. Therefore, research on localization without time synchronization is of interests [10–16]. Whistle, a TDOA-based localization method, was proposed in [15]. Time synchronization between the receivers was not needed because of the addition of a reference anchor that also sent signals. The distances between the reference anchor and other receivers were known, and the time arrival difference between the signals from the sender and the reference anchor could be obtained according to the local clock of each receiver. Then, the difference time of the signal from the sender to different receivers could be obtained. Whistle was implemented on commercial off-the-shelf cell phones with acoustic signals and generally reaches a localization accuracy of less than 30 cm. The sender–receiver difference distance can be obtained by measuring the time arrival difference between two time nodes when the signal is sent. Given the initial sender–receiver distance, the distance at any time node can be obtained by adding the sender–receiver difference distance to the initial distance. This method is called the inter-node time difference-of-arrival (ITDOA) [13]. The inter-node sending difference time can be obtained based solely on the sender, and the corresponding inter-node receiving difference time can be obtained based solely on the receiver. If the distance between the sender and receiver remains unchanged, then the two difference times should be the same. Otherwise, the difference in the two difference times multiplied by the signal propagation velocity is the sender–receiver difference distance between the two time nodes. We observed that time synchronization is not needed at this time. Simulations for the ITDOA method have been studied, but few real experiments have been conducted [13,14]. The BeepBeep ranging system without clock synchronization between devices is proposed in [16], and it achieves approximately 1 or 2 cm of accuracy within a range of more than 10 m. As shown in Fig. 1, A sends the signal at time t As , and B receives the signal at time t Br ; if A and B are time synchronized well, then the distance can be obtained using the TOA method. In the case without time synchronization, B sends a signal after B receives the signal from A at time t Bs , and A receives the signal from B at time t Ar . The distance can be obtained by multiplying the propagation speed by half of ½ðtAr tAs Þ ðtBr t Bs Þ, which is called the elapsed time between the two time-of-arrivals (ETOA), where ðtAr tAs Þ is based solely on the clock of A, and ðtBr tBs Þ is based solely on the clock of B; clock synchronization between the devices is no longer required. However, the distance obtained using the BeepBeep
Fig. 1. Event sequences in the BeepBeep ranging procedure.
ranging system is uncertain if either device moves during the gap between the times that they send their signals, namely, t As and tBs . Moreover, if the distance between more than two devices must be measured, then each device should send the sound signal once successively, thus, the measurement cycle is too long. The BeepBeep system can be used as a ranging scheme but is not suitable for locating a moving object. We proposed the OneBeep ranging system, which is a kind of ITDOA method, to help locate a moving object. As shown in Fig. 1, only the moving object A is required to emit the signal periodically. The initial distance should be given in ITDOA and can be obtained using the BeepBeep ranging system. Thus, we realized that to locate a moving object both the BeepBeep and OneBeep systems must be used. We performed our experiments using laptops. Because the microphone and loudspeaker for each laptop are not close, the distance between them in the BeepBeep ranging system should be accounted for, which is not discussed in [16]. The localization scheme including the BeepBeep and OneBeep systems is a pure software solution and uses only a speaker, a microphone, and some form of device-to-device communication, such as WIFI radio. This approach is easily applied to robots, smart phones and other devices. The remainder of this paper is organized as follows: We review the related audio ranging work in Section 2. The overall ranging mechanism of our work is presented in Section 3. In Section 4, we present the detailed OneBeep ranging mechanism. The error of the OneBeep ranging system is analyzed in Section 5. We review and supplement the BeepBeep ranging mechanism in Section 6. The localization experiments using the BeepBeep ranging system and OneBeep ranging system are described in Section 7. Section 8 concludes the paper.
2. Related work Many range-based localization algorithms using acoustic signals have been proposed recently. There are basically four types of measurements of acoustic signals among the existing works: TOA [4,5,17], TDOA [6–9,18,19], direction of arrival (DOA) [20], and received signal energy [21]. In the cricket systems [17], TOAs of ultrasound signals from the emitters at known positions to the receiver to be located are measured. The RF signals are employed for synchronization of TOA measurements. TOA measurements of acoustic signal consisting of Binary Phase Shift Keying modulated Gold sequences are performed in [4]. A reference microphone at a fixed location is used for determining the delays for each speaker. Because the fixed speakers and the microphone to be located share a CPU or clock, time synchronization is not a prominent problem here. A classic sound source localization method based on TDOA estimation is presented in [18] using 8 microphones. The work in [19] deals with the problem of localizing and tracking a moving speaker using a microphone array consisting of four omnidirectional microphones. The proposed algorithm is based on estimating TDOA by maximizing the weighted cross-correlation function in
C. Tan et al. / Measurement 78 (2016) 73–82
order to determine the azimuth angle of the detected speaker. Ref. [20] studies the DOA estimation of reflections in short time windows of room impulse responses measured with a spherical microphone array. An energybased localization system is proposed in [21], in which the positions of speakers are estimated in an ad hoc microphone array setting. High accuracy ranging is typically achieved through measuring TOA information of acoustic signals. But the precision of TOA measurement remains a big challenge in any system implementation. In practice, TOA measurement is often done with both sides taking a timestamp of their respective local clock at the moment the signal is emitted or received. There are three intrinsic uncertainties in this process that can contribute to the ranging inaccuracy: the possible clock skew and drift between devices, the possible misalignment between the sender timestamp and the actual signal emission, and the possible delay of a sound signal arrival being recognized at receiver [16,22]. The tests on two COTS mobile devices in [16] reveals that the latter two delays can easily add up to several milliseconds on average, which translates to nearly one meter of ranging error. By using sample counting from both sender and receiver, the BeepBeep and OneBeep mechanisms mitigates all the uncertainties listed above, which could achieve good accuracy but use only most basic set of hardware.
75
Fig. 3. The hardware in the OneBeep ranging procedure.
Using the two steps, the distance between any two laptops can be obtained. Keeping several laptops static as the anchors, the moving laptop can be located given the distances between the moving one and the anchors. 4. OneBeep ranging mechanism 4.1. Basic ranging scheme As shown in Figs. 3 and 4, laptop A emits the sound signal through its speaker SA at time t 1 . Both microphone M A and microphone M B record the sound signal. The time when the signal arrives at laptop A or B is marked as t A1 or t B1 , respectively. After a period of time, laptop A emits the second sound signal through its speaker SA at t2 . The time when the second signal arrives at laptop A or B is marked as t A2 or tB2 , respectively. If the distance between A and B remains unchanged, then Eq. (1) holds.
3. Overall localization mechanism
t B2 tB1 ¼ t A2 t A1
We start by describing the basic ranging procedures with only two laptops: A and B. Each laptop has a speaker, a microphone, and WIFI radio. Usually, each laptop has a separate left and right speaker. To prevent crosstalk, only one speaker is used. The distance between the laptop A and laptop B is obtained through the two steps:
In contrast, if the distance between A and B changes between t1 and t2 , then Eq. (1) is incorrect. If we assume that the distance between A and B at t1 is s1 , and the distance at t 2 is s2 , then, we have
Step 1: In the beginning, both remain static. BeepBeep method is used to obtain the initial distance, as shown in Fig. 2. Step 2: After obtaining the initial distance, either one of the two objects begin to move. OneBeep method is applied to obtain the difference distance. The absolute distance between the two could be obtained by adding the difference distance to the initial distance obtained in Step 1, as shown in Fig. 3.
Fig. 2. The hardware in the BeepBeep ranging procedure.
ð1Þ
s1 ¼ v ðtB1 t A1 Þ
ð2Þ
s2 ¼ v ðtB2 t A2 Þ
ð3Þ
Ds ¼ s2 s1 ¼ v ½ðt B2 t A2 Þ ðt B1 tA1 Þ ¼ v ½ðtB2 t B1 Þ ðt A2 tA1 Þ
ð4Þ
where v is the speed of sound. Here, Ds is the difference in the distance from A to B between t1 and t 2 . According to (4), if the value of ðt B2 t B1 Þ and the value of ðt A2 tA1 Þ are known, then Ds can be calculated. The value of ðt A2 t A1 Þ completely depends on the clock of A, and the value of ðtB2 tB1 Þ completely depends on the clock of B. There is no need to synchronize the clocks of A and B in the OneBeep ranging system.
Fig. 4. Event sequences in the OneBeep ranging procedure.
76
C. Tan et al. / Measurement 78 (2016) 73–82
To compute the time difference, each laptop samples the sound signal from the microphone at a fixed frequency. The elapsed time between the two arrival times can be directly computed by counting the number of samples between the arrivals of the two signals. With this counting, we have
nA2 nA1 fA
ð5Þ
nB2 nB1 ¼ fB
ð6Þ
tA2 t A1 ¼
tB2 t B1
Ds ¼ v
nB2 nB1 nA2 nA1 fB fA
ð7Þ
where nxy denotes the index of the sample point of the microphone of laptop x at instant t xy , and f A and f B are the sampling frequencies of the microphones of laptops A and B, respectively. Here, Ds is the difference in the distance from A to B between t1 and t2 . More precisely, Ds is the difference in the distance from the speaker of laptop A to the microphone of laptop B.
5.1. Theoretical analysis We model the error of the sampling frequency of the microphones in (8) and (9).
f A ¼ f s þ f bA þ f dA
ð8Þ
f B ¼ f s þ f bB þ f dB
ð9Þ
where f s is the accurate sampling frequency of the microphones of each laptop, f bx is the constant biased error in the sampling frequency of the microphone of laptop x, and f dx is the drift error in the sampling frequency of the microphone of laptop x. If the error in the sampling frequency of the microphones is considered, then the sampling frequency will be time-varying. We have
Z nA2 nA1 ¼
t A2 tA1
Z nB2 nB1 ¼
f A dt
ð10Þ
f B dt
ð11Þ
t B2 tB1
According to (1), (7)–(11), we have 4.2. Acoustic signal design and detection To detect the sound signal effectively when ambient noise is present, the sound signal is set to a linear chirp signal because a linear chirp signal has a good autocorrelation property. In general, the speakers and microphones in the laptops use a narrow spectrum band that corresponds to the human voice. Therefore, the frequency range of the linear chirp signal is set to be between 2 and 6 kHz. In our implementation, the length of the sound signal is set to 50 ms. We also find that the sound waveform that is played out has very large distortion in the first few milliseconds. To avoid this distortion, we precede the chirp signal with five milliseconds of a 2 kHz cosine waveform [16]. The sound signal is detected by a correlation with the reference chirp signal in the time domain. The sampling frequency of the microphones of each laptop is set at 48,000 Hz. Because the length of the chirp signal is 50 ms, the number of chirp signals should be 2400. The microphones of each laptop will record the sound continuously, starting from the moment when the OneBeep system begins to work. The data from the microphones are correlated with the reference signal, and the maximum peak is located; this maximum peak is the location of the sound signal if there is only weak background noise and weak reflection in the room. 5. OneBeep ranging error analysis In the actual experiment, the actual sampling frequency of the microphone of each laptop is not exactly 48,000 Hz. The sampling frequency has biased error and drift error, both of which depend on the characteristics of the microphones. The error of the sampling frequency will cause error in the difference distance in the OneBeep ranging system.
Ds ¼ v
R tB2 t B1
ðf bB þ f dB Þdt
R tA2 t A1
ðf bA þ f dA Þdt
fs
ð12Þ
Because we assume the distance between laptop A and B remains unchanged, Ds should be zero. Then, Ds in (12) can be viewed as the error in the difference distance that is caused by the inaccurate sampling frequency of the microphones in the OneBeep ranging system. However, it is difficult to use (12) to compute the error due to the unknown parameters in (12). Instead, an approximate practical analysis is provided. 5.2. Practical analysis Now, laptop A emits a sound signal with a period of T. Laptops A and B both receive the sound signal from A. The number of samples between time ðk 1ÞT and kT for A and B are nA ðkÞ and nB ðkÞ, respectively. Let nðkÞ ¼ nB ðkÞ nA ðkÞ. Then, the difference distance between time ðk 1ÞT and kT is given by
DsðkÞ ¼
nðkÞ v fs
ð13Þ
The difference distance between time kT and the beginning is given by
DlðkÞ ¼
k X
Pk
DsðiÞ ¼
i¼1
i¼1 nðiÞ
fs
v
ð14Þ
If the distance between A and B remains unchanged, then nðkÞ should be zero. In practice, nðkÞ is not at zero because of the inaccurate sampling rate of the microphones. To compensate for the error, we have
Pk
DlðkÞ ¼
i¼1 nðiÞ
fs
N0 k
v
ð15Þ
C. Tan et al. / Measurement 78 (2016) 73–82
77
where N 0 is a compensation parameter. After the compensation, DlðkÞ should be zero when A and B remain static. According to (15), we have:
N0 ðkÞ ¼
k 1X nðiÞ k i¼1
ð16Þ
To evaluate the influence on the ranging accuracy because of the inaccurate sampling rate, an experiment is conducted. Two laptops, A and B are placed next to each other and remain static. Laptop A emits the sound signal in a period of 5 s, and both A and B receive the sound signal from A. The compensation parameter N 0 can be calculated according to (16) at the kth period. We plot a graph to show the values of the compensation parameter N 0 at each kth period in Fig. 5. An accurate compensation value N 0 is obtained when an ideal value of DlðkÞ is known (here, DlðkÞ ¼ 0 because the two laptops remain static). In practical applications, b 0 is DlðkÞ is unknown and must be found. If an estimate N
Fig. 6. The difference distance error at the 125th period with the estimate b 0 is proportional to the area of the shadow. compensation value N
used as the compensation value, then we have
D^lðkÞ ¼
Pk
i¼1 nðiÞ
b0 k N
fs
D~lðkÞ ¼ D^lðkÞ DlðkÞ ¼
v
b 0 k½N0 ðkÞ N v fs
ð17Þ
ð18Þ
b 0 to make D~lðkÞ Now, the question is how to estimate N b 0 ¼ 5:22 as an example. as small as possible. Take N According to (18), the difference distance error caused by the inaccurate sampling rate of the microphones at the 125th period is proportional to the area of the shadow in Fig. 6. Intuitively, the shade in any kth period should be made as small as possible with an appropriate estimate b 0 . A practical method is to obtain compensation value N b 0 by the data during the estimate compensation value N the incipient periods. According to (17), D^lðkÞ can be computed by letting b N 0 ¼ N 0 ð50Þ, as shown in Fig. 7. b 0 is estimated by using the data in the first 50 N experimental periods, and then, the difference distance of
Fig. 7. The difference distance calculated by the OneBeep ranging system.
the following 150 experimental periods can be calculated by (17). The corresponding time is 150 5 = 750 s, with a difference distance error of approximately 0.32 m. As shown in Fig. 5, the difference distance error caused by the inaccurate sampling rate of the microphones grows over time because the difference of the constant biases in the sampling rates shown in (8) and (9) can be compensated in this way; however, there is drift in the sampling rate, which is time-variant. 6. BeepBeep ranging mechanisms We can only obtain the difference distance by the OneBeep ranging mechanism. To obtain the absolute distance, the initial absolute distance should be given first; therefore, we use the BeepBeep ranging system to obtain the absolute distance [16]. 6.1. Basic ranging scheme
Fig. 5. The compensation parameter N 0 at the kth period.
To obtain the distance using the BeepBeep ranging system, both laptops should emit the sound signal once. As shown in Fig. 8, laptop A emits the sound signal at time t1 , and laptop A and laptop B receive the sound signal at
78
C. Tan et al. / Measurement 78 (2016) 73–82
Fig. 8. The event sequences in the BeepBeep ranging procedure.
time t A1 and t B1 , respectively. Then, laptop B emits the sound signal at time t2 , and laptop B and laptop A receive the sound signal at time t B2 and t A2 , respectively. Assume that the distance between A and B is s, and that they both remain static. We have
s ¼ v ðt B1 t A1 Þ
ð19Þ
s ¼ v ðt A2 t B2 Þ
ð20Þ
where yields
s¼
v
is the speed of the sound. Adding (19) and (20)
1 v ½ðtA2 tA1 Þ ðtB2 tB1 Þ 2
tA2 t A1 ¼
nA2 nA1 fA
ð22Þ
tB2 t B1 ¼
nB2 nB1 fB
ð23Þ
1 n n n n v A2 A1 B2 B1 2 fA fB
laptop B emits the sound signal at time t2 , laptop A receives the sound signal at time t A2 , and laptop B receives the sound signal at time t B2 . We have
SA M A ¼ v ðtA1 t 1 Þ ð21Þ
where the value of ðt A2 tA1 Þ completely depends on the clock of A, and the value of ðtB2 t B1 Þ completely depends on the clock of B. To compute the time difference, each laptop samples the sound signal from the microphone at a fixed frequency. The elapsed time between the two arrival times can be directly computed by counting the number of samples between the arrivals of the two signals. With this counting, we have
s¼
Fig. 9. Structure and the relative positions of the two laptops.
ð24Þ
where nxy denotes the index of the sample point of the microphone of laptop x at instant t xy , and f A and f B are the sampling frequencies of the microphones of laptops A and B, respectively. 6.2. A supplementary BeepBeep ranging mechanism According to (24), s is the distance between A and B. In fact, because the speaker and the microphone of each laptop are not sufficiently close to each other, the distance between them must be accounted for. As shown in Fig. 9, OA is the center of laptop A, SA is the position of the speaker of A, and MA is the position of the microphone of A. The same is true for laptop B. The microphone is usually positioned on top of the screen surface. To obtain the position of the microphone, the angle between the screen and keyboard should be measured. In practical experiments, for convenience, the angle is set to 120° as shown in Fig. 9. As shown in Fig. 8, laptop A emits the sound signal at time t1 , laptop A receives the sound signal at time t A1 , and laptop B receives the sound signal at time t B1 . Then,
ð25Þ
SA M B ¼ v ðtB1 t 1 Þ
ð26Þ
SB M B ¼ v ðtB2 t 2 Þ SB M A ¼ v ðtA2 t 2 Þ
ð27Þ ð28Þ
According to (25)–(28), we have
1 v ½ðtA2 tA1 Þ ðtB2 tB1 Þ 2 1 ¼ v f½ðt A2 t 2 Þ ðt A1 t1 Þ ½ðt B2 t2 Þ ðt B1 t1 Þg 2 SA M B SA M A SB MA SB M B ¼ þ ð29Þ 2 2
R¼
where R can be obtained using the BeepBeep ranging system. However, R is not the exact distance between laptops A and B when the distance between the speaker and the microphone of each laptop is considered. In Fig. 9, laptops A and B are placed at different heights by the value Dh. Then, b is the angle between the directions of the two laptops, and a is the angle between the center-to-center direction of two laptops and the reference direction. Here, Dh; a and b are measured manually. The coordinate system OA xyz, which is marked as bA , is the body coordinate system of A, and the coordinate system OB xyz, which is marked as bB , is the body coordinate system of B. The coordinates of OA ; M A and SA in the bA frame can be obtained by manual measurement. Similarly, the coordinates of OB ; M B ! and SB in the bB frame can also be obtained. OA OB denotes bA
! OA OB described by coordinates in the bA frame. Assuming that the value of OA OB is r, we have
! OA OB
bA
¼ ½r sin a; r cos a; Dh
ð30aÞ
2
C bbAB
3 cos b sin b 0 6 7 ¼ 4 sin b cos b 0 5 0 0 1
T
! OB MB
bA
! ¼ C bbAB OB M B
bB
ð30bÞ
ð30cÞ
79
C. Tan et al. / Measurement 78 (2016) 73–82
! O B SB
! ¼ C bbAB OB SB
bA
ð30dÞ
bB
! SA M B
! ! ! ¼ OA SA þ OA OB þ OB M B
ð30eÞ
! SA M A
! ! ¼ OA SA þ OA M A
ð30fÞ
! SB M A
! ! ! ¼ OB SB OA OB þ OA M A
ð30gÞ
! SB M B
! ! ¼ OB SB þ OB MB
ð30hÞ
bA
bA
bA
bA
R¼
bA
bA
bA
bA
bA
bA
bA
! SA MB
! SA M A bA bA 2
bA
bA
bA
þ
! SB MA
! SB M B bA bA 2
ð30iÞ
where j j is the norm operator, and C bbAB is the coordinate transformation matrix from the bA frame to the bB frame. According to (30), r can be obtained given R, and then, it is easy to obtain SA M B or SB M A . 7. Localization experiment An experiment was conducted to evaluate the effect of locating the moving object. Four laptops are located in the four corners and remain static. The moving laptop E is put on the handcart as the object to be located, as shown in Fig. 10. The index of the sample point at the time of the arrival of the sound signal is obtained by each laptop, and then, it is sent to laptop E through WLAN radio for further computation in laptop E. The floor is made of regular stripes. We placed the laptops along the lines on the floor. As shown in Fig. 11, the handcart moves along the trajectory P0–P1–P2–P3–P4–P0–P1–P5–P6–P4–P0 to simulate a localization scenario. According to the trajectory, the handcart will pass through P0 three times during the beginning, middle and final instances of time in the experiment. The difference distance should be the same as the beginning in P0 during these three instances of time, which can be used as a high precision measurement to evaluate the accuracy of the OneBeep ranging system. The handcart
Fig. 11. Floor plan of the test room.
must stay in P0 for approximately 1 min in the beginning to obtain the distances between each laptop using the BeepBeep ranging system, and the estimate compensation b 0 , as shown in (17), can be obtained to compensate value N the sampling rate differences according to Section 5.2. Then, we push the handcart along the trajectory, and the OneBeep ranging system produces the localization result. The distances shown in Fig. 11 are measured manually using a fabric tape measure. The localization experiments include two stages. The BeepBeep ranging system obtains the initial distances in the first stage, and then, the OneBeep ranging system locates the moving laptop E. 7.1. BeepBeep ranging system In the beginning, laptop E stays in P0, and all of the laptops remain static. A, B, C, D and E send a sound signal successively, and afterward, we can calculate all of the distances between the laptops. To improve the accuracy of the distances, we can repeat the BeepBeep approach many times, and obtain the average of the distances. Because the distance between the microphone and the loudspeaker for each laptop is more than 20 cm long, which is much longer than the BeepBeep ranging precision, we refer to Section 6.2 to calculate the exact distances between the two laptops. The environmental temperature is a variable that can affect the velocity of sound. We use a digital thermometer to measure the environmental temperature. Eq. (31) shows the mathematical equation of the environmental temperature and the sound velocity in air.
rffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi Temp m=s v ðTempÞ ¼ 331:3 1 þ 273:15
Fig. 10. Indoor testbed for the localization experiment.
ð31Þ
where Temp is the temperature value measured in degrees centigrade. The resolution of the thermometer is 0.1 °C. The environmental temperature changes slowly with the time, and the temperature measured is actually the temperature where the thermometer is placed, as shown in Fig. 10. Because the localization error is much higher than the
80
C. Tan et al. / Measurement 78 (2016) 73–82
error caused by the temperature, we did not extensively consider the temperature element, such as temperature changes over time and space. We repeated the BeepBeep ranging method 17 times. R can be computed between the laptop E and each of the other laptops using (29). Because there are 17 results for each R, the standard deviation can be computed to help evaluate the precision of the BeepBeep ranging system. The mean of each R is used for further computation (see Table 1). Rmean is the mean of the direct results from the BeepBeep ranging system, as shown in (29), and Rstd is the standard deviation from the 17 results for each R. Here, r is the distance between the centers of the two laptops, which is computed according to (30), and rruler denotes the distance measured manually. Then, Dr is the difference between rruler and r. More accurately, the difference distance in the OneBeep ranging system is between the speaker of the moving laptop E and the microphone of each anchor. The initial value of SE M A ; SE M B ; SE M C and SE M D should be given by the BeepBeep ranging system according to (30). The computed results are SE M A ¼ 2:4982 m; SE M B ¼ 2:8888 m; SE M C ¼ 3:0485 m and SE M D ¼ 2:6139 m.
Table 1 Measurement results for the initial distances using BeepBeep ranging system.
Rmean Rstd (m) r r ruler (m) Dr
EA
EB
EC
ED
2.1600 0.0012 2.3940 2.396 0.002
2.4642 0.0024 2.5748 2.580 0.005
2.6187 0.0018 2.8191 2.801 0.018
2.1683 0.0015 2.6297 2.632 0.002
7.2. OneBeep ranging system After obtaining the initial value of SE M A ; SE M B ; SE M C and SE M D , the next step is to find the time of the OneBeep ranging system. Only laptop E emits the sound signal in a one-second interval, and all of the microphones of the five laptops work together. As E moves, the time-variant difference distances, which are DSE M A ; DSE M B ; DSE M C and DSE MD , can be obtained using the OneBeep ranging system. Then, the absolute value of SE M A ; SE M B ; SE M C and SE M D at any second can be computed by adding the known initial value coming from the BeepBeep ranging system. We establish a navigation coordinate system O xy where the center of laptop A is in the origin of the coordinate, the x-axis is along AB, and the y-axis is along AD, as shown in Fig. 11. The coordinates of E in O xy can be calculated by computing the intersection of the four spheres using a general localization similar to GPS. Every effort was made to enable the accurate movement of the handcart along the trajectory shown in b 0 , as shown in (17), is computed using the data Fig. 11. N in the first one minute when all of the laptops stay static. The difference distance between the located laptop E and the other four laptops (anchors) using the OneBeep ranging system is computed and is shown in Fig. 12. Because laptop E will stop moving for a while at position P0 during the beginning, middle and final instances of time in this experiment, the difference distance should be nearly zero at the three points. The maximum error of the difference distance is approximately 0.025 m, as shown in Fig. 12, which should be mainly caused by the drift in the sampling rate of the microphones, as explained in Section 5. The calculated trajectory in the two-dimensional space using the BeepBeep and OneBeep ranging systems is shown in Fig. 13. The calculated trajectory is for the right speaker of laptop E.
Fig. 12. Difference distances between laptop E and the other four laptops using the OneBeep ranging system.
C. Tan et al. / Measurement 78 (2016) 73–82
Fig. 13. Localization results of laptop E using the BeepBeep and OneBeep localization systems.
The inaccuracy of the sampling rate of the microphones is the main cause of the localization error, although we have proposed a method for estimating the frequency differences in Section 5.2 that greatly reduces the localization error. The constant bias of the sampling rate can be compensated, in contrast to the drift in the sampling rate, which changes slowly with time. The localization error caused by the drift in the sampling rate increases over time. As shown in Fig. 12, the error in the difference distance in the middle time is smaller than that at the final time, as in the analysis in Section 5. That relationship is a weakness in the ITDOA-based ranging system [14]. The accuracy of the ITDOA-based ranging system (OneBeep) can be ensured only for a limited period of time due to the drift in the sampling rate. However, in this localization scheme, the error of the OneBeep ranging system that is caused by the drift in the sampling rate could be further compensated using the BeepBeep ranging system. In other words, when the moving object is detected to be somewhat motionless during the OneBeep stage, the BeepBeep ranging systems works for a short time to obtain the absolute distances at a much higher accuracy, and then, the inaccuracy in the sampling rate can be compensated according to (17). This method can ensure the accuracy for a long time period of localization. 8. Conclusions We propose the ITDOA-based OneBeep ranging system to locate a moving object. The initial distances between the devices should be given, which can be accomplished using the BeepBeep ranging system when all of the laptops remain static at the beginning. Then, the OneBeep ranging system initiates when the located laptop begins to move. Because only the difference distances between the moving laptop and the anchors can be obtained in the OneBeep system, the initial distances should be added, and then, the moving laptop can be located according to its distances to the other anchors. Both the BeepBeep and OneBeep
81
ranging systems require only a microphone, a loudspeaker and some form of device-to-device communication such as WIFI radio, and time synchronization is not required. As a result, the localization scheme is quite convenient for application in robots, cell phones and other devices without any additional hardware, and it reaches centimeterlevel localization accuracy. The ranging error grows over time for the ITDOA-based ranging system because of the drift in the sampling rate of the microphone for the OneBeep ranging system. We use the sampling data when all of the laptops remain static to estimate the sampling frequency difference between the different laptops. However, the sampling frequency difference could not remain stable because of the drift in the sampling frequency. In this localization scheme, the BeepBeep ranging system can be used to obtain the distance at a much higher accuracy in the OneBeep stage, and then, we can update the sampling frequency difference between different laptops in such a way that the localization of BeepBeep and OneBeep systems can maintain a high localization accuracy for a very long time. Acknowledgments This study was supported by the Funding Program for Graduate Student Research and Innovation in Jiangsu Province, China (Grant no. CXLX11_0239). The authors would like to thank Jieliang Shen and Surui Yao for their help with the experiments. References [1] I. Guvenc, C.-C. Chong, A survey on TOA based wireless localization and NLOS mitigation techniques, IEEE Commun. Surv. Tutorials 11 (2009) 107–124. [2] A. Boukerche, H.A.B. Oliveira, E.F. Nakamura, A.A.F. Loureiro, Localization systems for wireless sensor networks, IEEE Wireless Commun. 14 (2007) 6–12. [3] H. Liu, H. Darabi, P. Banerjee, J. Liu, Survey of wireless indoor positioning techniques and systems, IEEE Trans. Syst. Man Cybernet. Part C – Appl. Rev. 37 (2007) 1067–1080. [4] C. Sertat03l, M.A. Alt03nkaya, K. Raoof, A novel acoustic indoor localization system employing CDMA, Digital Signal Process. 22 (2012) 506–517. [5] N. Aloui, K. Raoof, A. Bouallegue, S. Letourneur, S. Zaibi, Performance evaluation of an acoustic indoor localization system based on a fingerprinting technique, EURASIP J. Appl. Signal Process. 2014 (2014) 1–16. [6] K.D. Frampton, Acoustic self-localization in a distributed sensor network, IEEE Sensors J. 6 (2006) 166–172. [7] J.-M. Valin, F. Michaud, J. Rouat, D. Létourneau, Robust sound source localization using a microphone array on a mobile robot, in: IROS 2003, Proceedings of the 2003 IEEE/RSJ International Conference on Intelligent Robots and Systems, 2003, IEEE, 2003, pp. 1228–1233. [8] Q. Liang, B. Zhang, C. Zhao, Y. Pi, TDOA for passive localization: underwater versus terrestrial environment, IEEE Trans. Parallel Distrib. Syst. 24 (2013) 2100–2108. [9] M.S. Brandstein, H.F. Silverman, A practical methodology for speech source localization with microphone arrays, Comput. Speech Lang. 11 (1997) 91–126. [10] T. Damarla, L.M. Kaplan, G.T. Whipps, Sniper localization using acoustic asynchronous sensors, IEEE Sensors J. 10 (2010) 1469–1478. [11] A. Canclini, E. Antonacci, A. Sarti, S. Tubaro, Acoustic source localization with distributed asynchronous microphone networks, IEEE Trans. Audio Speech Lang. Proc. 21 (2013) 439–443. [12] M. Compagnoni, P. Bestagini, E. Antonacci, A. Sarti, Localization of acoustic sources through the fitting of propagation cones using multiple independent arrays, IEEE Trans. Audio Speech Lang. Proc. 20 (2012) 1964–1975.
82
C. Tan et al. / Measurement 78 (2016) 73–82
[13] S.Y. Park, H.-s. Ahn, W. Yu, A simple object tracking system using ITDOA without time synchronization, in: The 9th International Conference on Advanced Communication Technology, 2007, pp. 2026–2028. [14] T. Li, A. Ekpenyong, Y.-f. Huang, A location system using asynchronous distributed sensors, in: Infocom 2004, Twenty-third Annual Joint Conference of the IEEE Computer and Communications Societies, 2004. [15] B. Xu, G. Sun, R. Yu, Z. Yang, High-accuracy TDOA-based localization without time synchronization, IEEE Trans. Parallel Distrib. Syst. 24 (2013) 1567–1576. [16] C. Peng, G. Shen, Y. Zhang, Y. Li, K. Tan, BeepBeep: a high accuracy acoustic ranging system using COTS mobile devices, in: Proceedings of the 5th International Conference on Embedded Networked Sensor Systems, ACM, Sydney, Australia, 2007, pp. 1–14. [17] N.B. Priyantha, A. Chakraborty, H. Balakrishnan, The cricket locationsupport system, in: Proceedings of the 6th Annual International Conference on Mobile Computing and Networking, ACM, Boston, Massachusetts, USA, 2000, pp. 32–43.
[18] J.M. Valin, F.o. Michaud, J. Rouat, D. Letourneau, Robust sound source localization using a microphone array on a mobile robot, in: Proceedings International Conference on Intelligent Robots and Systems, 2003, pp. 1228–1233. [19] I. Markovi04, I. Petrovi04, Speaker localization and tracking with a microphone array on a mobile robot using von Mises distribution and particle filtering, Rob. Autonom. Syst. 58 (2010) 1185–1196. [20] S. Tervo, A. Politis, Direction of arrival estimation of reflections from room impulse responses using a spherical microphone array, Proc. IEEE/ACM Trans. Audio Speech Lang. 23 (2015) 1539–1551. [21] M. Chen, Z. Liu, L.W. He, P. Chou, Z. Zhang, Energy-based position estimation of microphones and speakers for ad hoc microphone arrays, in: Applications of Signal Processing to Audio and Acoustics, 2007 IEEE Workshop on, 2007, pp. 22–25. [22] F. Sivrikaya, B. Yener, Time synchronization in sensor networks: a survey, IEEE Network 18 (2004) 45–50.