0% found this document useful (0 votes)
9 views25 pages

Unit-5 Tiny Os

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views25 pages

Unit-5 Tiny Os

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 25

UNT- V

SENSOR NETNDRK

SENSOR-ODE ARDWARE

BER KELEY MOTES


CHALEN6)ES
PROG RAM MING)
[3] PLATFORMS
SOF 7WARE
NODE LEVEL
43
. ] TINY os
G.2) nesC

AbpL ICATONS
C5J UNAUTHORIZED ACTIVTY
DETECTIN NETWOR,
A SENSOR
Us/NG
HABITAT AONITORIN.
EOR
s-27 wSN
SENSOR MODE HA RDWARE

Theieae 3catgous hardcae


detinecl gorsersot.
c) Aygormentd gereval- poupose
Compulus,
(q) elealz EmBeddedsensos

ysten on-chip(SeC males)


(i) Acgmentedgererat- purpose
Comptesj
ooles enftker
shelßo stch as
RTOS
brotocol a u s Bluetooh, and

capababat,
Due to oone pnocessg
to ononepadoetg
aceommDdat wAle eDSS.
Enampe loo pouer pes
Eobeldes.
leusto)
-lengnds,
u) Dediatl Embeddedsensoy do
These ypes platyom ue
Dommeetel BbaShelfccors)
ormale ahd Cormmcnicatis.
PESpots atleast
taaolcoTS,
> Due to
Cagaye
BeLkelay
ULLA mmedusa

chsp (sc)'
omast dust
Ls Eamplesi BwRc prcorado nlo
PAsTA ode
Chpl
based onhio lenee
> The platgem
dlastg CsoDO, rens,
nolokes tbbld lowpoe
L23 BERKELEY MOTES,
bmbedley
KOnooleshatShares
O h a e s thesae
Thts the bae
anchtac luse,

lompantsm +Mca2 2Dot


Renel Rer Mlca
MOTE. WeC
TYPE
ch°p A TOL9B ATnaqa lb3L
4MHZJ 8MHZ
MCU 4MHZ,GbiE MHZ,bE
Ype
progran J6 l28

RemCKB) 4
AT45DBOj4B
ExtenaL chop 24 LC256
non-volahtemnecn SPr
Memny
St2e ke) 32
Coin Cell
|Default TYpe Ce
piweY
Sonse YpIcal
4000
54 2850

TRIO00
Radlo Sbe9) mhz
Freguny
Ran 40

oglula on jobt key


MICA MOTE
2 DU
Dt has buo CpU elestgn, The mais
eg Contlley eMcU) a Atmel ATeglcg
takslere o Aulas-pMoesS.
pralz and mueh lers capabte
MCU
Abmel lo- prDtesoY Rs mly aete cehen
the MCU ps
Mce has mtegald
The ATonegatoL
lash memOy 4KB
572 Ke
ata memoH
boane Coponens to
akmaleoot
neided to achiene
Bzent.
Mote kas aspuala sfoke
Mea e t that hslla
meney
used to sloe
E termal R8
por batehprousyg and
Stog
olata aplocati'ons.
mole
TRIO00 epst peating
al 916 MHZ
bardl.
ExpPSION CONECYpR
5) PIN T/o
&
analg

Io3
Unigu ATmga Merocontholer.

Co-proe
ransmntisto >Hardnse
Aeceleraot
SP/
BUS

TR OO0 Exlmale
Yadio baseiveo
glash
MAy |678 C3)
Pqune MICA mote anclacluse
hardoaece eleratos
50 kbps,
ransmeHONrale
pnpment a 4o kbes
banSmesson hange ps
L The mamen
geet penSpe
about Boo feet
57 pPrr o
mels buppot a
eotens Pon Conneetor.
secae Tlo boands
Qelats lonelad
Sensors, boara canbe
pmal Tlo c0nector.
thiouehhe
1 AsensoboarlCan hoseatenpeatex
aeel
a g h S , anmeusphone
sesor,
mel megneto melr, a
aseeal lo lINT)
onobeeper
oneeten l o s he nsle to csmm
uth a p eal
u n t ala belueen
tume.
a a d o bamsnnessn besss eaeha
a manen
Comsepln ehee
der
4ms fo send
paut tatesoransceteo and tuir
whole lesleing
the hcom' 9ackets.
that Cangend one packe
The Eney the radio branscehor
only pprts
mcam
Table : power Conse mpliom
Stantp Curerl
Component Ratz bme Consumpluo
McU aclni AM42 Ma 5.5 nMA
MCU lle lMA | 6 mA
McU Suspend 22MH2 4ms L20uA
RadioCansmtt Bo ms |2mA

Radio keceAre LyolcHz 20 ms


photo resRsto 2000 Hz Oms J235 rmA

Aceeleremeles 100 H2 {0 ms

Tempeialae. 242 boO ms.


3 PROCRP MMING CHALLENGES

abbtraetton gor hmellesng Tlo, et

agplolhealiaS
enpltutly dialett mesege
Atnehonizton, Prn terpt

alocates kesouies
eni sehedeleng
Real
to mone uGent
lanbe gnthocl arty.
deinenexeceles llns tt
Enent
nlesesteng ereot
no
-

hasle he noceesed.
neek to be por
techncges ort toeel
SEamolaloneembedf o
> Thege
mau
cale upgoo pa9
S S Y s netuotclue
Cro",

tlonot

Shoel be
nnelwot
2Kenso mutiple
Respond to
ablet
dsgn platjormgpots a lngo
by protlrg dtgn tanie
netho lologycorbtrletahestrcaloeD

DesimmethDalology vardes appla


tboh-to ypials and tdyprds
tast aserser
tte
are oganizd.
sesor l o e
The golloung CAaraclaeslis
CAaraclos
Cantly asfklebe desrgr

()
Reliarlely am)
derelessSens9

olestrbulzd
o t e SensDY e
syten,
a
vrrehab

thsegonee
bwl ado

D b t l t éD
adapt
adapt to
to agg
SclA_Ra
anel Cnts eerors
oles Contenes to
-en hen the
PntensledpApose
Thenetucot Aare tad,
faled
mang ty aAplPeato,
leies an

pagramy
Resosce lonsatsi
retot tprcally
etelers sensor
-lonstarieel, which

maPren aieataon deelepmnt

(2) anScale cpto


sensor neboo
madol
enellsanal
pn

nodespns.
showal.
sfosle gor lange sae netant,
s mancallo3guieton, mmalntenasi
PrlslalBnsO
andkepu due to lange
oeasTble
thsego neasiets
nles wie be
nembs sß-mangement and
to Supp
lentue Nealooks
Data
) Akensr nlote aplreansoo
Cnenelabe abot OBEang
*gormatm
many agpltcateos ane only conees
ol2hdala
d netabou weth the cleclues
data a l a Cenlralpotnt,

an er salzes the sensor


data.

SoF TNA RE PL ATFORMS


l] ODE LEVEL

Amoclelerl platgom Canke


nocle Centie ehaael
ceAehproles pona)
heootng bs ractton aensc
nocle te hagammes.
2 canbe a Canguage platgoom
that protdes,
Lang)focen
ponna o paegrammest.
absbractk
s An os Cperaling Sysen)
the by
rotlng ouset

(2) memy tlocatbon.


3)
(4) phusphaal
TINY os
hesC

TINY modularety an
EVent-basrd os suppts ramnng by he
enen Jhaeel
Cenept conphents . 2lsepposts
pllalos onkl&0
Sensor eto
cwe consbrainasl hardwaseplatom
Anchas Beseley mos.
Compreses a tegeurreal
Components
iState mgomaln arane
o oraltasks
scle
i) pAogran enent asdl commands

lommansole
Both enents om
betueen dBeent
Cocmao chamgel
Conpn ats.
Cenponenta ae arangelhieas
Lowenel
Chially,g m low- lEne
closetohe hardoonehogh lene
the aetual
Comonmys
applation. mala
MAL
ForSanstn
oabRshirg
procec.
RoUTE
M a te
n a
RoUTER SENSE AND SEND
th netob

ACTI VE TiMER
MESSA Ges
SW

RADIO PAKET
TMP PHoTD.
-
RADrD
BYTE HW
ADL WRAPpER

FRg: Ting
Cornponent thot posdes
absrat vessro Qsryple
more
unaleEtomds hARe Compoents
i)
ij) SEat
) sop.
Frame 3.
Handleg Enent 2.
Handley Comman /
onent.
SetRat
harllers. Tasks
Avent
Hanlieo
Comgr
Frame
Jpred Stop jast
seport
an dmtty CPE
sno alsD Can
ndto
, Bast
onents Comy PEs m
an eme Aerent
leanes hanelles
on. mest handle%
o in paradgm
Commmand that,
nf- Prmptant TRe
em Snot to omothes
anothey
hondle Can amol
PN e Eas3" In tory OS, thy
hane to Aen to combleton
haso onlerupted by hardeys,
but canbe CaR)
Repeat eguest
Merotocsl
Aetematic
protoeol naekethas
leasr beenentBuce
ehethera a
Daeke
lhether

and and ttesecenl Z an


aboet
outome afAe e r a t t .
aproach
Split-phaseJoraeh
progra/mmg
Cothmand.
Kequees anel enent as te
Csnmand
Prteaeteon betueen
Haung espeirally cusng
Conpoant. anal pgramog.
ehenpt- phase
°iely useahl
os ps tte meaSt atStedan
ny aml loot-
doeumented
Lñeenikonnent pn wsN.

many apps
Cationss the anchete
empomenta
a Behedule and Sel
eheh eanbe
eachotheg.
ento
Conmponens are classsed
CompOninls
9pefes
Compnint Canneted
ane
Congigus aton modules
moe cesrG ) hieas
eho
hea abo
eh o o h e r( bloek
mplles a e baste

Oommanal
A Componenthamolles
s Eent handlins
emnetaks,
set- Q pe
Qmd a a e s e c l i e d hle
onents C6menecota e%
Comp and Comand an
a r h a l y throyh
eachoths
Hgh-lenel cmponenls psse
enintsp lswlerel Cmpo
l o m m n s to
low-level components
i)
and
nels. a enents to hek leel
6fqnals
orpoents.
HrghleLcormponenta Emplement
Bandless. anel Low-lenl
-erent Comnarnd prDceSs
Cemponents
CoMPON ENT A
PROV DES /NIEREAE
Command C-D)
Command C-D2

DnteZ
Comrnmd D|
Aent D2
TPry os lomornergaa.
Fg:

Component B
Potirfa e C
uses CommandC-D]
Cau
badle enent cD2
lompDrent hat
csesntuo7ace
Tny os
Figi

Componet

B.c

Tøry
clowe the
nents. Layer set a
ethod'Cale sß
Layevs,
ehele
a
gae ues
p
ses class an
ees,
protles, teraes EPgas,
n
as:
70AeleetA
Speteaton
ue
andanComponeE A-
resc Prein
omporert CCT)
nhas fae teon
atom Concureny
and
C3)
,icty
tauon Imple
Component
Componen ()
lwbae Tn ts
and
sppt
amdieflect
hesC
P
he
entenson an
hesC
T'imerModule f
provides {

interfaceStdControl:
interfuce Timcr01:
}
uses interface Clock as CIk;
}
interfaceStd Control{
commandresult_tinit0:

interface Timer01
commandresult_t startlchar type, uint32_t intervali:
commandresult_t stop0:
eventresult_t timer0Fire 0;
eventresult_t timerlFire0:

interface Clock
commandresult_tsetRate(char interval, char scale);
eventresult_t fire 0:

The interface definition of the Timer component in nesC andcommand calls. An


call is a method call from a lower layer component to a higher layer component,
while a command is the opposite. Note that one needs to know both the typc of the
iknownterface (providessor uses) and the direction of the method call (event or command) to
exactly whether ran
interface method isimplemented by the component or is rcquired
by the component.
4i) Components Tepleentalcn Componestg

elepencl
lerninef
r0dules,

Conna
naue
ae
moleles
appleatin loale.(
ae pnplemented
Aleras
Comporents.
by
The implementation definition of the Timer comonent in nesC.
interface Timer01:

Uses interface Clock as Clk:

1mplementation!
boolevenFlag;
commandresult tSidControl.init){
evenFlag = 0,
return call CIk.setRate( 128,4): //4 ticks per
second
and tomicityi
i) Conlwsheney nesC alerectly
Canguage exeeetton nodel
The Bney s Comnand
Reteetz the oton Sf
honghthe
Qnol t e Cotesct.
enent
Theimplementation definition of the TimerC configuration in nesC.
TimerC {
provides {
interfaceStd Control:
interface Timer01:
}

implementation
componentsTimerModule, Clock:
Std Control = TimerModule.Std Control;
Timer= TimerModule.Timeri
TimerModule.Clk ’HWClock.Clock:
clasigrd
Ceole Canbe clasirad nto

tuo types? cocle C Ac)


Asynchionos
() Synhuonos Codle (Sc)
(Gi) chableam
haom0s
Codethat ps hea
l e a s t ome
atSynchonoslocde(sc);reachable
ii) tAat ps enly rea
Coole
Jrmtases

You might also like