chunyi peng guobin(jacky) shen, yongguang zhang, yanlin li, kun tan microsoft research asia...

21
Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS Mobile Devices

Upload: jermaine-ring

Post on 14-Dec-2015

218 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Chunyi PengGuobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan

Microsoft Research Asia

BeepBeep:

A High Accuracy Acoustic Ranging System using COTS Mobile Devices

Page 2: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Ranging, basic to localization

• Many excellent systems– Cricket (Mobicom’00)– RIPS (Sensys’05)– ENSBox (Sensys’06)– …

• Hardware and algorithmic innovation

2

Page 3: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Our motivation

• Proximity detection between devices– Among portable devices

• MobiUS (Mobisys’07)

– Between portable and non-portable devices• Phone to PC, Xbox, Printers, Projectors …

Page 4: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

The requirement

• A widely applicable solution– Work on COTS devices

• No additional hardware (e.g., ultrasound)• Pure user space software (no change to OS/driver)

– Not dependent on infrastructure • Applicable in spontaneous, ad hoc situations

– Minimum set of sensors

• High accuracy!

Page 5: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

A matter of time measurement

• Mostly, based on time-of-flight measurement– Distance = speed x time– Sound often chosen

• Slower speed => less demanding on time accuracy

• Still, a challenging task– 1 ms error in time = 34 cm error in distance

• 1 cm ranging accuracy requires 30us timing accuracy

– Extremely challenging on COTS/software

Page 6: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

The root cause of inaccuracy – three uncertainties

• Clock synchronization uncertainty• Sending uncertainty

time

...t0 = wall_clock();write(sound_dev, signal);...

software issuing command

sound leavesspeaker

unknown delays (software, system,

driver, hardware, …)

?

...read(sound_dev, signal);t1 = wall_clock();...

software aware of arrival

soundreaches mic

unknown delays (hardware, interrupt,

driver, scheduling, …)

?

• Receiving uncertainty

Page 7: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Effects of the sending and receiving uncertainties

• Example measurement of the lower bound on COTS mobile devices (HP iPAQ rw6828)– Highly fluctuating, appears unpredictable– Easily adds up to 1-2 ms (=> a few feet error)

CPU idle CPU heavily loaded

Page 8: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Our approach – BeepBeep

• A simple and effective solution– Each device just needs to emit a sound signal and

record them simultaneously– Only require a speaker, a mic, and some way of

communicating with the other device

• Achieving 1cm accuracy while satisfying all the requirements

Page 9: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Beepbeep’s basic procedureDevice A Device B

DAB=|ETOAA-ETOAB|/2

A’s recording B’s recording

ETOAA ETOAB

1. Device A emits a beep while both recording

2. Device B emits another beep while both continue recording

3. Both devices detect TOA of the two beeps and obtain respective ETOAs

4. Exchange ETOAs and calculate the distance

Page 10: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Mathematical derivation

tA3

2nd Beep

tB3

tB2

1st Beep

tB1

tA0

tA1

ETOAA

ETOAB

dB,A+dA,B= c·[(tA3-tA1)-(tB3-tB1)] +dA,A+dB,B

= c·(ETOAA-ETOAB)+dA,A +dB,B

dB,A-dA,A = c·(tB1-tA1)

dA,B-dB,B = c·(tA3-tB3)

Page 11: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Key techniques, effects and rationale (I)

• Self-recording – Record signals from both the other party and itself– Establish the starting reference point of the whole

ranging process– Duplex audio channel

• Two-way sensing– Avoid clock synchronization uncertainty– To capture the ending reference point of the whole

ranging process• not attempt to capture any system time info

Page 12: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Key techniques, effects and rationale (II)

• Sample counting– Avoid referring to system clocks for timing info– Dedicated A/D converter, w/ fixed sampling rate

• Achievable precision is determined by the sampling frequency: 0.8cm at 44.1kHz sampling rate

• Putting together: – Bypass all the three uncertainties by making time

measurement irrelevant to system clocks

Page 13: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Engineering Challenges (I)Signal Design

• Good signal design helps detection – Easily detectable in digital recording– Robust against ambient noise– Robust against acoustic distortion

• Low-fidelity speaker & mic in COTS mobile device

– Within hardware capability• Most COTS devices have limited voice frequency range

• Our empirical design (“chirp” sound)– 50ms long, shifting frequency from 2 to 6 kHz

Page 14: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Engineering Challenges (II)Signal Detection Algorithm Design

• Efficient and fast signal detection algorithm– Quickly locate possible signal regions

• Robust against low SNR– Utilize noise floor to boost SNR

• Combat multipath effect– Multipath: big issue indoor environment– We derived special algorithm to detect first “sharp

peak” signal correlation

Page 15: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Engineering Challenges (III)

• Protocol design– Coordinate two (or more) devices in entire ranging

process– Minimize ranging time duration

• Device form factor– Speaker/mic’s placement affect ranging results

• Vary from one device model to another

– Need calibration to adjust ranging calculation

Page 16: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

System Implementation

• Platform: Windows Mobile 5.0– Sound: “wave” API– Communication: “WinSock” (WiFi or Bluetooth)

• Software architecture– User-mode dynamic linkable library– As service for other applications

• Test devices– Dopod838– HP iPAQ 6828

Page 17: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Evaluation

Case-A: Indoor, quiet Case-B: Indoor, noisy Case-C: Outdoor, car park entrance Case-D: Outdoor, subway station50 runs each setting

ExprSetting

OperationRange

Conf.Level

AA(|Err|)cm

MA(|Err|)cm

A(Std)cm

M(Std)cm

Case-A 4.0m 94% 0.9 1.4 1.2 1.9

Case-B 4.0m 94% 1.1 1.7 1.0 1.3

Case-C 12m 98% 2.7 3.8 1.0 2.1

Case-D 10m 92% 1.0 2.2 1.4 1.6

Page 18: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Summary

• Identified three uncertainties and mitigated them with three key technologies– Two-way sensing– Self-recording– Sample counting

• BeepBeep provides a simple ranging solution– Achieves 1cm accuracy– On very basic hardware set– Purely in software (user-space)

Page 19: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Thanks!

• Demo session. Welcome to try BeepBeep!

• Software downloads: http://research.microsoft.com/wn/beepbeep.aspx

Page 20: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Backup

Page 21: Chunyi Peng Guobin(Jacky) Shen, Yongguang Zhang, Yanlin Li, Kun Tan Microsoft Research Asia BeepBeep: A High Accuracy Acoustic Ranging System using COTS

Lower bound of sending and receiving uncertainties