Top Banner
The Cricket Indoor Location System Nissanka Bodhi Priyantha and Michel Goraczko MIT Computer Science and Artificial Intelligence Lab http://nms.lcs.mit.edu/cricket
29

The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Apr 24, 2018

Download

Documents

ngodien
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

The Cricket Indoor Location System

Nissanka Bodhi Priyantha

and

Michel Goraczko

MIT Computer Science and Artificial Intelligence Lab

http://nms.lcs.mit.edu/cricket

Page 2: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket

• Location for mobile applications– Resource discovery

– Human/Robot navigation/tracking

– Games

• Location-aware sensing– Routing

– Data dissemination

– Annotating data with location information

Page 3: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Resource Discovery

“Print map on a color printer,”and system sends data to thenearest available color printer

Page 4: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Virtual/Physical Games

Page 5: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Location-Aware Sensing• Ubiquitously deployed

networked sensors can enable new forms of monitoring and control– Tracking assets (RF-ID

tags)– Monitoring conditions– Traffic, facilities, physical

plant, leaks, smoke, fire…• Sensor streams usually need

to be annotated with location and time for them to be useful

• Goal: Cricket-enabled sensors

Temperature, light, sound sensors, buzzer

Temperature, light, sound sensors, buzzer

Page 6: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Functionality: Space, Position, Orientation

Room 7(N)

Room 7(S)

Co

rrid

or (x y z)

● Space: Rooms, parts of rooms● Position: Coordinates● Orientation: Direction vector

Cricket provides all three

Page 7: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Design Goals for Cricket

• Must operate well indoors• Must scale to large numbers of devices• Should not violate user location privacy• Must be easy to deploy and administer• Should have low energy consumption

Page 8: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket Architecture

Beacon

Listener

Passive listeners + active beacons scales well, helps preserve user privacyDecentralized network of autonomous beacons

info = “a1”

info = “a2”

Estimate distancesto infer location

Page 9: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Obtain linear distance estimatesPick nearest to infer “space”Solve for device’s (x, y, z)Determine w.r.t. each beacon and deduce orientation vector

SPACE = NE43-510COORD = (146 272 0)

Page 10: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

• A beacon transmits an RF and an ultrasonic signal simultaneously– RF carries location data, ultrasound is a narrow

pulse

• The listener measures the time gap between the receipt of RF and ultrasonic signals– Velocity of ultrasound << velocity of RF

Determining Distance

RF data(space name)

Beacon

Listener

Ultrasound(pulse)

Page 11: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Multiple Beacons Cause Complications

• Beacon transmissions are uncoordinated

• Ultrasonic pulses reflect off walls

These make the correlation problem hard and can lead to incorrect distance estimates

Solution: Distributed scheduling algorithms

Beacon A Beacon B

tRF B RF A US B US A

Incorrect distance

Listener

Page 12: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Solution

• Distributed beacon scheduling– Carrier-sense + randomized transmission (reduces

chances of concurrent beaconing)– Idle time between beacon chirps to allow ultrasound

to “die down”– Another possibility is distributed TDMA

• Listener inference algorithm– Processing distance samples to estimate location– Key problem is outlier rejection

Page 13: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Example Estimation Algorithm:Windowed MinMode

Distance(feet)

Frequency

A B

5 10

5

109Majority

6.47.2Mean (feet)

86Mode (feet)

86Actual distance (feet)

BA

Page 14: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Kalman Filter: For Mobile Listeners

● Min-mode based estimation is “slow”– Needs multiple samples from a beacon

– Poor performance with mobile listeners● Solution: Use a Kalman filter based estimator

– Kalman filter uses a “predict and correct” approach to filter outliers

Page 15: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Beacon Autoconfiguration

● For listeners to compute their position,beacons need to transmit their locations

● Problem: How do beacons determine their locations?– Manual configuration (e.g., counting ceiling tiles) is

possible but tedious● Goal: Scalable autoconfiguration

Page 16: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Beacon Autoconfiguration: For a Small Number of Beacons

● Place the listener under each beacon and collect distances to each beacons

● Calculate inter-beacon distances● Calculate beacon coordinates

– Selecet three initial beacons and assign coordiantes– Trangulate the others using these three

dA dB

dABA

B

dA dB

dABA

B

Page 17: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Beacon Autoconfiguration:Anchor Free Localization (AFL)

● For large number of beacons● AFL is a two phase distributed algorithm for

node localization– Phase 1: Fold-free initialization'– Phase 2: Optimization

● AFL needs local inter-beacon distances– Cricket beacons cannot measure interbeacon

distances● Listener-assisted AFL

– Use a mobile listener to patch-together disconncted beacons

Page 18: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket Hardware Platforms

• Two platforms– CF interface

– Rs232 interface

• Both platforms can be software configured as a Beacon or a Listener– Unused submodules can be powered down to save

energy

• Can be programmed using a standard Mica programming board (MIB-510CA)

Page 19: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket Hardware

Page 20: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket Block Diagram

u-controllerAtmega 128L

RF interfaceCC1000

Ultrasonic Tx

Ultrasonic Rx

Temperature Sensor

51-pin mote interface

• Ultrasonic transmitter

– 40kHz piezo transmitter

– Driven by a 12V square wave

• Ultrasonic receiver

– 40kHz piezo sensor

– Two amplifier stages followed by an envelope detector

– Second amp stage has software adjustable gain

Serial IDSerial IDHost InterfaceCF or RS 232

Page 21: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket Block Diagram

• RF interface– CC1000 based – similar to Mica2– Additionally, there is a carrier threshold detector

• Mote connector – Can interface with a Mica sensor board or a Mica– Communication with Mica through RS232 or I2C

interface

• Temperature sensor– On-board temperature sensor– Used to offset ultrasonic velocity change with

temperature

Page 22: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Ultrasonic Ranging Characteristics

• Radiation pattern– Easy to block the signal at the transmitter, but

not at the receiver

Page 23: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket Precision

● Distance estimation performance● Area coverage

– Error vs distance● Beacon density

Page 24: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Distance Estimation Performance

Page 25: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Coverage Area

● Ultrasound range is 10.5 meters● Radio range must be larger then ultrasound

0 50 100 150 200 250 300 350 400 4500

50

100

150

200

250

300

350

400

450

500

True Distance vs mesured distance

True distance

Mes

ured

dis

tanc

e

Page 26: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

TinyOS architecture and implementation

● Application (CricketBeacon and CricketListener)

● Modification to the radio stack● Ultrasound activation● Compensation● Scheduling

Receive(30ms + 1-3ms)

Idle state(800-1200ms)

Send

If failed*

* The receive while is reset each time a beacon is heard

Page 27: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket API

● Serial/CF port API ASCII Binary (not implemented yet)

● TinyOS API

module Cricket { command getDistance( int Beaconid) command BeaconRecord getClosestBeacon(int order) event beaconUpdate(BeaconRecord rec) event beaconChanged()}

example:

Page 28: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket Serial APISerial

Beacon Listener Command Direction Parameters TypeParameter Description Read Write Read Write ASCII BIN Get Output Put Input ASCII BIN

ASCII/BIN Mode • • • • MD 0x01 <mode> <mode> String[1] Char

Node ID Unique node id • • ID 0x02 <id> N/A String[16] Long

Space Name User specified space id • • • • SN 0x03 <name> <name> String[12] String[12]

Distance • • DB 0x04 <distance units> <distance units> string[5],string[2] ushort,char

Duration • DR 0x05 <duration units> <duration units> string[5],string[2] ushort,char

Coordinates • • • • PC 0x06 <tag x y z units> <tag x y z units> String[1],3*string[6],string[2] Char,3*short,char

Sleep • • SL 0x07 <low high units> <low high units> 2*string[5],string[2] 2*ushort,char

Ultrasound lifetime • • • • UL 0x08 <lifetime units> <lifetime units> string[5],string[2] ushort,char

Temperature Temperature on the node • • TP 0x09 <temp units> <temp units> string[5],string[2] ushort,char

Battery Level • • BL 0x0A <level> <level> String[5] Short

Uptime Time since powered up • • UP 0x0B <units> <time units> string[5],string[2] ushort,char

Version Software version • • VR 0x0C None <version> String[5] String[5]

Filter Event filter • • FL 0x0D <filter expression> <filter expression> String[128] String[128]

User defined User defined • • DG 0xFF <user string> <variable> String[128] Variable

Communication protocol to use

Distance between the lis-tener and the beacon

Ultrasound time of flight (uncorrected)

Coordinates of the node (x y z)

Sleep range between beacon chirp

The ultrasound life be-fore the wave attenuate

Reading of the voltage level from the battery

Page 29: The Cricket Indoor Location System - NCAR Earth … · SPACE = NE43-510 COORD = (146 272 0) ... Cricket API Serial/CF port ... The Cricket Indoor Location System Created Date: 1/8/2004

Cricket Demo

● Ranging● 2D localisation demo● ASCII serial API demo