wireless health care monitoring system
TRANSCRIPT
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 1/111
KARNATAKA STATE OPEN UNIVERSITYMANASA GANGOTHRI, MYSORE- 570006
TITLE OF THE PROJECT REPORTWIRELESS HEALTH CARE
MONITORING SYSTEM
A PROJECT REPORT
Submitted by
NAME OF THE CANDIDATE
SUMA G.O
11 !1"LDEC06
Under the guidance of
G#$%& N'(&KANNAN
I) *'+ $' # $ (&) / & +& #$+&(&)F/+ & '2'+% / & %&3+&& /
D$* /('$n
ELECTRONICS COMMUNICATIONAND ENGINEERING
1
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 2/111
KARNATAKA STATE OPEN UNIVERSITYMANASA GANGOTHRI, MYSORE- 570006
CERTIFICATE
This is to certify that this project entitle !" W$+& &44 H&' C'+&
M/)$ /+$)3 S 4 &( # Title$##S%&'itte &y## st% ent na'e S#('G.O #####(ith Re)ister No11 !1"LDEC06 ! is s%&'itte on ! -06-
!01" !!! to the KARNATAKA STATE OPEN UNIVERSITY *
+arnata,a* In ia* in partial f%lfill'ent of the re-%ire'ents for the a(ar
of D$* /(' $) ELECTRONICSCOMMUNICATION')%
ENIGINEERING is a recor of &onafie (or,
%n erta,en &y her.hi'#
St% ent Na'e/SUMA G#O Internal G%i e Na'e/
Si)nat%re/ Desi)nation/
Date/ Internal G%i e Si)nat%re/
Date/
St% y Center Na'e/ E0ternal G%i e Na'e/
Seal of St% y Centre Desi)nation/
E0ternal G%i e Si)nat%re/
Date/ Date/
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 3/111
KARNATAKA STATE OPEN UNIVERSITYMANASA GANGOTHRI, MYSORE- 570006
TITLE OF THE PROJECT REPORTWIRELESS HEALTH CARE
MONITORING SYSTEMA PROJECT REPORT
Submitted by
NAME OF THE CANDIDATE
SUMA G.O
11 !1"LDEC06
Under the guidance of
G#$%& N'(&KANNAN
I) *'+ $' # $ (&) / & +& #$+&(&)F/+ & '2'+% / & %&3+&& /
D$* /('$n
ELECTRONICS COMMUNICATIONAND ENGINEERING
2
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 4/111
A
A
S '+'%' V$8'4 T+#4N/. 509191 , ! )% //+. L'84 ($ :/(* &;, 10 ('$)
!7 :+/44, < /:8, J' ')'3'+, =')3' /+&-11
M/) > Y&'+JUNE !01"
TA=LE OF CONTENTS
C '* &+ N/ T$ & P'3& N/
1 Itro %ction to (ireless health care 3
'onitorin) syste'
1#1 4i)#5l, sche'atic of si)nal ac-%isition 16
'o %le
Intro %ction to E'&e e syste' 17 #1 4i)# E'&e e syste' esi)n calls 18
2 Intro %ction to Sensors 2
2#1 4i)#9in )' of Te'perat%re sensor :
7 Intro %ction to Microcontroller 26
9IC1:43;;A
7#1 4i)#Internal architect%re of 2
Microcontroller 9IC1:43;;A
8 Intro %ction to Glo&al syste' 77
8#1 GSM architect%re 78
: Intro %ction <IG5EE 82
:#1 4i)# <IG5EE stac, architect%re 8;
7
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 5/111
; Intro %ction to MA= 2 :
>?olta)e con?erter@
3 Intro %ction to 9o(er S%pply :8
Intro %ction to LCD isplay ;7
16 Intro %ction to Soft(are Re-ire'ents ;3
16#1 CODINGBTrans'itter co in) 38
11 Concl%sion 162
1 5i&ilo)raphy 167
12 Appen i0 A 168
17 Appen i0 5 16:
18 Appen i0 C 16;
1: Appen i0 D 16
1; Appen i0 E 116
8
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 6/111
D&: '+' $/)
I certify that
a# The (or, containe in this report is ori)inal an has &eenone &y 'e %n er the )%i ance of 'y s%per?isor>s@#
&# The (or, has not &een s%&'itte to any other Instit%te for anye)ree or iplo'a#
c# I ha?e follo(e the )%i elines pro?i e &y the Instit%te in preparin) the report#
# I ha?e confor'e to the nor's an )%i elines )i?en in theEthical Co e of Con %ct of the Instit%te#
e# hene?er I ha?e %se 'aterials > ata* theoretical analysis*fi)%res* an te0t@ fro' other so%rces* I ha?e )i?en %e cre it tothe' &y citin) the' in the te0t of the report an )i?in) their
etails in the references# 4%rther* I ha?e ta,en per'ission fro'the copyri)ht o(ners of the so%rces* (hene?er necessary #
Si)nat%re of the St% ent
:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 7/111
A:8)/2 &%3&(&)
?T$(&4 N&2 R/(') 1 @
;
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 8/111
W$+& &44 H&' C'+& M/)$ /+$)3 S 4 &( /+ P' $&) 4 ='4&%O) IG=EE
CHAPTER 1INTRODUCTION
1.1 I) +/%#: $/)
A ?ances in (ireless sensor net(or,s ha?e opene %p ne( opport%nities in
healthcare syste's# The f%t%re (ill see the inte)ration of the a&%n ance of e0istin)
speciali e 'e ical technolo)y (ith per?asi?e* (ireless net(or,s# They (ill coBe0ist
(ith the installe infrastr%ct%re* a%)'entin) ata collection an realBti'e response#
An e0a'ple of an area in (hich f%t%re 'e ical syste's can &enefit the 'ost fro'
(ireless sensor net(or,s is inBho'e assistance# InBho'e per?asi?e net(or,s 'ay
assist resi ents &y pro?i in) 'e'ory enhance'ent* control of ho'e appliances*
'e ical ata loo,%p* an e'er)ency co''%nication# The 'ain re-%ire'ents for
(ireless ho'ecare 'onitorin) syste's > MS@ are B
• Interopera&ility
• RealBti'e ata ac-%isition an analysis
• Relia&ility an ro&%stness
• Ne( no e architect%res
1.! P+$):$* &4 /+ WHMS D&4$3)
e propose (ireless sensor net(or, > SN@ architect%re for s'art ho'ecare
that possesses the essential ele'ents of each of the f%t%re 'e ical applications*
na'ely/
• Inte)ration (ith e0istin) 'e ical practices an technolo)y*
• RealBti'e* lon)Bter'* re'ote 'onitorin)*
3
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 9/111
• Miniat%re* (eara&le sensors* an
• Assistance to the el erly an chronic patients#
It e0ten s healthcare fro' the tra itional clinic or hospital settin) to the patientFs
ho'e* ena&lin) teleBcare#
1." D&4:+$* $/) / WHMS A+: $ &: #+&
The propose MS inte)rate a coherent set of interactin) porta&le e?ices*
(hile preser?in) 'o&ility an in epen ence an &rin)in) opti'%' assistance to
'e ical s%pport# This inte)ration incl% es the follo(in) feat%res/
• A%to'atic 'onitorin) of ?ital 'e ical physiolo)ical para'eters s%ch as &o y
te'perat%re* p%lse rate an heart rate#
• Co''%nication of physiolo)ical para'eters &et(een the %ser an e0ternal
inter?enin) parties s%ch as 'e ical octors* 'e icoBsocial instit%tions or
'onitorin) centers#
The res%ltin) syste' is 'o %lar an co'prises 'iniat%ri e &o yB(orn 'o %les
that pro?i e contin%o%s 'e ical an &eha?ioral 'onitorin) >p%lse rate* &o y
te'perat%re an acti?ity@#The 'onitore para'eters are (ireless >IEEE 36 #18#7
9AN protocol@ an trans'itte to a &ase station that is connecte to the
GSM.G9RS or Lan Line internet ser?ice# The &ase station processes an relays the
recei?e para'eters an sen s alar's to the e0ternal people s%ch as socioB'e ical
'onitorin) centers* nei)h&ors an 'e ical octors* (hoe?er is &est s%ite to
inter?ene epen in) on the type of alar'# hen the lin, is esta&lishe * the %ser 'ay
spea, (ith healthcare professionals#
1. H'+%2'+& ')% S/ 2'+& R& #$+&(&) 4
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 10/111
H'+%2'+& // 4B 9IC 1:43;;A* 01:BLCD* RS 2 * 36 #18#7 'o %le* GSM
'o e' (ith 9C interface* 5o y te'perat%re sensor* eart rate 'eas%re'ent
sensor* p%lse rate 'eas%re'ent sensor* User Mo&ile phone#
S/ 2'+& // 4B De?elop'ent tool M9LA5 ?;#7 * har (are Co'piler B IB
Tech 9IC* C 9ro)ra''er B 9IC 4lash* ar (are Si'%lation tool B 9rote%s ?:#
Sp7#
= /:8 4: &(' $: / & 4$3)' ': #$4$ $/) (/%# &B
4i)%re 1#1/ 5loc, sche'atic of the si)nal ac-%isition 'o %le
16
9%lse ratesensor
5o yte'pera
t%re sensor
eart RateSensor
S i )n
a l
c on
i t i oni n
)
9ICMicrocontroller (ith 16B5ITADC
IEEE802.15.4WPA
!rotoco"
9atient
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 11/111
4i)%re 1#1 sho(s the &loc, sche'atic ia)ra' of the si)nal ac-%isition 'o %le
(hich is the trans'itter part of the project#
4i)%re 1# sho(s the &ase station of ho'e care e'&e e syste' (hich is therecei?er part of the project#
='4& S ' $/) / /(&-:'+& &(<&%%&% 4 4 &(B
4i)%re1# / 5ase Station of ho'eBcare e'&e e syste'
A '+(4 / & E; &+)' P&/* &B
11
9ICMicro
Controller
IEEE0!.15.WPAN
*+/ /:/
GSM MODEM
GSM.G9R S
SERHICE
Care ta,er >an @ Nei)h&ors >an @Me ical octors
MO5ILE
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 12/111
4i)%re 1#2/ Alar's to the E0ternal 9eople
4i)%re 1#2 in icates the 'o&ile to (hich the 'essa)es fro' the 'o e' present in &ase station of ho'ecare e'&e e syste' are sent# This 'i)ht &e the 'o&ile of a
careta,er of the patient or a nei)h&or or a 'e ical octor or a relation to the patient#
1.5 O< &: $ &
Inspite of the i'pro?e'ent of co''%nication lin, an espite of all
pro)resses in a ?ance co''%nication technolo)ies* there are still ?ery fe(f%nctionin) co''ercial (ireless 'onitorin) syste's* (hich are 'ost
offBline* an there are still a n%'&er of iss%es to eal (ith# Therefore* there
is a s tron) nee for in?esti)atin) the possi&ility of esi)n an
i'ple'entation of an interacti?e realBti'e (ireless co''%nication syste'#
In this connection* a )eneric realBti'e (ireless co''%nication syste' has
&een esi)ne for short an lon) ter' re'ote patientB'on itorin)* %sin)
(ireless protocol# The pri'ary f%nction of this syste' is to 'onitor thete'perat%re* press%re an eart 5eat of the 9atient# The Data collecte &y
the sensors are sent to a Microcontroller at the trans'ittin) en # The
Microcontroller isplays the ?al%es in the LCD an then it is trans'itte ?ia
<i)&ee on the trans'itter si e to the recei?er# At the recei?in) en a recei?er
i)&ee is %se to recei?e the ata an is fe to another Microcontroller*
(hich is then isplaye o?er the LCD isplay# If there is any e?iation in
any para'eter in the patientFs stat%s* an alar' is so%n e to alert the
concerne octor or the atten ant an a 'essa)e is sent ?ia GSM to the
'o&ile of a care ta,er >or@ a octor#
1.6 COMPONENTS USED
C/(*/)&) 4 S*&:$ $:' $/)4
1
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 13/111
1# Step Do(n Transfor'er /> 26.1 H@ No
# Dio es />1N766;@ 1 Nos
2# Capacitors /1666 4 1 No* p4B Nos
7# Re)%lators /;31 No* ;368 2 No8# Li)ht E'ittin) Dio es /LEDJs :Nos
:# 9IC 'icrocontroller /1:f3;;A No
;# Crystal Oscillator /7M 1No
3# Transistor /5C87;B1No
# 5% er /1 ?oltsB1No
16# Te'perat%re sensor /1No
11# 9ress%re sensor /1N
1 # GSM 'o e' /1No
12# LCD 1:0 / No
17# Resistors /226 K 1Nos*16 +KB 8 Nos
1 +K Nos
1.7 O+3')$ ' $/) / T &4$4
In the first chapter the 'ain o&jecti?e of the project*the re-%ire'ents of (ireless
health care 'onitorin) syste' *its architecht%re an the har (are an soft are
re-%ire'ents ha?e &een isc%sse #the secon %nit eals (ith the e#'&e e
syste's*&loc, ia)ra's an circ%it ia)ra's of trans'itter an recei?er are
isc%sse # In the thir chapter the ifferent sensors %se are isc%sse in etail#fo%rth
Chapter eals (ith all the 9IC 'icrocontroller 1:43;;A an its architecht%re in
etail # In the fifth chapter ?ario%s aspects of GSM are isc%sse in etail# si0th
chapter eals in etail (ith the i)&ee an its applications# The se?enth chapter eals
(ith MA= 2 an its %sa)e# In the ei)hth chapter po(er s%pply %nit an re)%lators
are isc%sse # LCD is isc%sse in the ninth chapter# Soft (are re-%ire'ents are
isc%sse in the tenth chapter# Co in) is e0plaine in the ele?enh chapter
1. CONCLUSION
12
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 14/111
MS esi)n* o&jecti?e of the project is isc%sse an the co'ponents %se are
intro %ce in this chapter#
CHAPTER !
INTRODUCTION TO EM=EDDED SYSTEM
!.1 I) +/%#: $/)
E'&e e Syste' is a co'&ination of har (are an soft(are %se to achie?e
a sin)le specific tas,# An e'&e e syste' is a 'icrocontrollerB&ase * soft(are
ri?en* relia&le* realBti'e control syste'* a%tono'o%s* or h%'an or net(or,
interacti?e* operatin) on i?erse physical ?aria&les an in i?erse en?iron'ents an
sol into a co'petiti?e an cost conscio%s 'ar,et#
An e'&e e syste' is not a co'p%ter syste' that is %se pri'arily for
processin)* not a soft(are syste' on 9C or UNI=* not a tra itional &%siness or
scientific application# i)hBen e'&e e lo(er en e'&e e syste's#
i)hBen e'&e e syste' B Generally 2 * :7 5it Controllers %se (ith OS#
E0a'ples 9ersonal Di)ital Assistant an Mo&ile phones etc #Lo(er en e'&e e
syste's B Generally 3*1: 5it Controllers %se (ith an 'ini'al operatin) syste's an
har (are layo%t esi)ne for the specific p%rpose# E0a'ples S'all controllers an
e?ices in o%r e?ery ay life li,e ashin) Machine* Micro(a?e O?ens* (here they
are e'&e e in#
!.! S 4 &( D&4$3) C' 4
17
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 15/111
4i)%re #1 sho(s the pictorial representation of E'&e e syste' esi)n
calls on 'any isciples >i#e@ in ?ario%s fiel s the e'&e e syste's are %se #
4i)%re #1/ E'&e e syste' esi)n calls on 'any isciples
!." T & E(<&%%&% S 4 &( D&4$3) C : &
18
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 16/111
4i)%re # / H Dia)ra' of e'&e e syste' esi)n
ere (e isc%ss the role of si'%lation soft(are* realBti'e syste's an ata
ac-%isition in yna'ic test applications# Tra itional testin) is referre to as "static$
testin) (here f%nctionality of co'ponents is teste &y pro?i in) ,no(n inp%ts an
'eas%rin) o%tp%ts# To ay there is 'ore press%re to )et pro %cts to 'ar,et faster#
This has le to a nee for " yna'ic$ testin) (here co'ponents are teste
(hile in %se (ith the entire syste' either real or si'%late # 5eca%se of cost an
safety concerns* si'%latin) the rest of the syste' (ith realBti'e har (are is
preferre to testin) co'ponents in the act%al real syste'#
The ia)ra' sho(n in fi)%re # is the "H Dia)ra'$ that is often %se to
escri&e the e?elop'ent cycle# Ori)inally e?elope to encaps%late the esi)n
process of soft(are applications* 'any ifferent ?ersions of this ia)ra' can &e
fo%n to escri&e ifferent pro %ct esi)n cycles# ere (e ha?e sho(n one e0a'ple
of s%ch a ia)ra' representin) the esi)n cycle of e'&e e control applications
co''on to a%to'oti?e* aerospace an efense applications#
In this ia)ra' the )eneral pro)ression in ti'e of the e?elop'ent sta)es is
sho(n fro' left to ri)ht# Note ho(e?er that this is often an iterati?e process an the
act%al e?elop'ent (ill not procee linearly thro%)h these steps# The )oal of rapi
e?elop'ent is to 'a,e this cycle as efficient as possi&le &y 'ini'i in) the
iterations re-%ire for a esi)n# If the 0Ba0is of the ia)ra' is tho%)ht of as ti'e* the
)oal is to narro( the "H$ as '%ch as possi&le an there&y re %ce e?elop'ent ti'e#
The yBa0is of this ia)ra' can &e tho%)ht of as the le?el at (hich the syste'co'ponents are consi ere # Early on in the e?elop'ent* the re-%ire'ents of the
o?erall syste' '%st &e consi ere #
As the syste' is i?i e into s%&Bsyste's an co'ponents* the process
&eco'es ?ery lo(Ble?el o(n to the point of loa in) co e onto in i?i %al
processors# After(ar s co'ponents are inte)rate an teste to)ether %ntil s%ch
1:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 17/111
ti'e that the entire syste' can enter final pro %ction testin)# Therefore the top of
the ia)ra' represents the hi)hBle?el syste' ?ie( an the &otto' of the ia)ra'
represents a ?ery lo(Ble?el ?ie( .
• H ia)ra' escri&es lots of applications eri?e fro' soft(are
e?elop'ent#
• Reason for shape* e?ery phase of esi)n re-%ires a co'pli'entary test phase#
i)hBle?el to lo(Ble?el ?ie( of application#
• This is a si'plifie ?ersion#
•
Loop 5ac, . Iterati?e process* =Ba0is is ti'e >s%' %p@#
!. C '+': &+$4 $:4 / E(<&%%&% S 4 &(
An e'&e e syste' is any co'p%ter syste' hi en insi e a pro %ct other
than a co'p%ter#
There (ill enco%nter a n%'&er of iffic%lties (hen (ritin) e'&e e syste'
soft(are in a ition to those (e enco%nter (hen (e (rite applications
T +/#3 *# O%r syste' 'ay nee to han le a lot of ata in a short
perio of ti'e#
R&4*/)4& O%r syste' 'ay nee to react to e?ents -%ic,ly
T&4 '<$ $ Settin) %p e-%ip'ent to test e'&e e soft(are can &e
iffic%lt
D&<#3'<$ $ itho%t a screen or a ,ey&oar * fin in) o%t (hat the
soft(are is oin) (ron) >other than not (or,in)@ is a tro%&leso'e
pro&le'
R& $'<$ $ e'&e e syste's '%st &e a&le to han le any sit%ation
(itho%t h%'an inter?ention
1;
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 18/111
M&(/+ 4*':& Me'ory is li'ite on e'&e e syste's* an yo%
'%st 'a,e the soft(are an the ata fit into (hate?er 'e'ory e0ists
P+/3+'( $)4 ' ' $/) yo% (ill nee special tools to )et yo%r soft(are
into e'&e e syste's
P/2&+ :/)4#(* $/) 9orta&le syste's '%st r%n on &attery po(er* an
the soft(are in these syste's '%st conser?e po(er
P+/:&44/+ /34 co'p%tin) that re-%ires lar)e a'o%nts of C9U ti'e can
co'plicate the response pro&le'
C/4 Re %cin) the cost of the har (are is a concern in 'any e'&e esyste' projects soft(are often operates on har (are that is &arely
a e-%ate for the jo&#
E'&e e syste's ha?e a 'icroprocessor. 'icrocontroller an a 'e'ory#
So'e ha?e a serial port or a net(or, connection# They %s%ally o not ha?e
,ey&oar s* screens or is, ri?es#
!.5 A** $:' $/)4• Military an aerospace e'&e e soft(are applications
• Co' '%nicat ion Appl icat ions
• In %str ia l a%to 'a t ion an process contro l sof t (are
!.6 C '44$ $:' $/)
•
Real Ti'e Syste's• RTS is one (hich has to respon to e?ents (ithin a specifie ea line#
• A ri)ht ans(er after the ea line is a (ron) ans(er
!.7 RTS C '44$ $:' $/)
• ar Real Ti'e Syste's
13
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 19/111
• Soft Real Ti'e Syste'
!.7.1 H'+%2'+& R&' T$(& S 4 &(B
ar realBti'e syste's ha?e ?ery narro( response ti'e#• E0a'ple/ N%clear po(er syste'* Car iac pace'a,er#
!.7.! S/ 2'+& R&' T$(& S 4 &(B
Soft realBti'e syste's ha?e re %ce constrains on lateness &%t still '%st
operate ?ery -%ic,ly an repeata&le#
• E0a'ple/ Rail(ay reser?ation syste' ta,es a fe(
e0tra secon s the ata re'ains ?ali #
!. L')3#'3&4 U4&%
• C
• CPP
• Qa?a
• Lin%0
• A a
• Asse'&ly
!. = /:8 D$'3+'(4
1
9IC 1:43;;A
LCD
<IG5EE
TEM9ERATURESENSOR
9RESSURESENSOR
EART 5EATSENSOR
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 20/111
4i)%re #2/ 5loc, Dia)ra' of Trans'itter
4i)%re #7/ 5loc, ia)ra' of recei?er
!.10 C$+:#$ D$'3+'(4
4i)%re #8 an fi)%re #: represents the circ%it ia)ra' of the trans'itter an
recei?er# The har (are present in the circ%it co'prises of/
•
Microcontroller 9IC1:43;;A
• Sensors/
Te'perat%re sensor/ LM28
9ress%re Sensor/ M9=16
eart &eat sensor/ LM283
6
9O ER SU99L
9IC 1:43;;A
<IG5EE
LCD
9O ER SU99L
GSMMODEM
5U<<ER
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 21/111
• <i)&ee 'o %les
• GSM 'o e'
• 9o(er S%pply
• MA= 2
• LCD
1
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 22/111
4i)%re #8/ Circ%it Dia)ra' of Trans'itter
4i)%re #:/ Circ%it Dia)ra' of Recei?er
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 23/111
!.11 C/): #4$/)
E'&e e Syste' is e0plaine an the &loc, an circ%it ia)ra's %se in the
project are isc%sse #
CHAPTER - "
SENSORS
".1 I) +/%#: $/)
A sensor is a trans %cer (hich con?erts physical -%antities to electrical-%antities#
".! P+&44#+& S&)4/+ MP 10
The M9=16 e?ice is silicon pie o resisti?e press%re sensors pro?i in) a
?ery acc%rate an linear ?olta)e o%tp%t irectly proportional to the applie press%re#
These stan ar * lo( cost* %nco'pensate sensors per'it 'an%fact%rers to esi)n
an a their o(n e0ternal te'perat%re co'pensation an si)nal con itionin)
net(or,s# Co'pensation techni-%es are si'plifie &eca%se of the pre icta&ility of
Motorola s sin)le ele'ent strain )a%)e esi)n# 4i)%re 2#1 sho(s a sche'atic of theinternal circ%itry on the stan alone press%re sensor chip an fi)%re 2# sho(s the
press%re sensor %se
".!.1 F&' #+&4B
• Lo( Cost
• 9atente Silicon Shear Stress Strain Ga%)e Desi)n• Ratio 'etric to S%pply Holta)e
• Easy to Use Chip Carrier 9ac,a)e Options
• Differential an Ga%)e Options
• D%ra&le Epo0y Uni &o y Ele'ent or Ther'oplastic
• >99S@ S%rface Mo%nt 9ac,a)e
2
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 24/111
".!.! A** $:' $/) E;'(* &4B
•
Air Mo?e'ent Control• En?iron'ental Control Syste's
• Le?el In icators
• Lea, Detection
• Me ical Instr%'entation
• In %strial control
• 9ne%'onic control syste'
4i)%re 2#1/ internal circ%it of press%re sensor
4i)%re 2# / M9=16 press%re Sensor
"." T&(*&+' #+& 4&)4/+ LM"5 B
7
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 25/111
The LM28 series are precision inte)rate Bcirc%it te'perat%re sensors*
(hose o%tp%t ?olta)e is linearly proportional to the Celsi%s >Centi)ra e@ te'perat%re#
The LM28 th%s has an a ?anta)e o?er linear te'perat%re sensors cali&rate in
+el?in* as the %ser is not re-%ire to s%&tract a lar)e constant ?olta)e fro' its o%tp%tto o&tain con?enient Centi)ra e scalin)# The LM28 oes not re-%ire any e0ternal
cali&ration or tri''in) to pro?i e typical acc%racies of 1V7 C at roo' te'perat%re
an 2V7 C o?er a f%ll W88 to P186 C te'perat%re ran)e#
Lo( cost is ass%re &y 'i'in) an cali&ration at the (afer le?el# The
LM28 s lo( o%tp%t i'pe ance* linear o%tp%t* an precise inherent cali&ration 'a,e
interfacin) to rea o%t or control circ%itry especially easy# It can &e %se (ith sin)le
po(er s%pplies* or (ith pl%s an 'in%s s%pplies# As it ra(s only :6 XA fro' its
s%pply* it has ?ery lo( selfBheatin)* less than 6#1 C in still air# The LM28 is rate to
operate o?er a W88 to P186 C te'perat%re ran)e* (hile the LM28C is rate for a
W76 to 116 C ran)e >W16 (ith i'pro?e acc%racy@# The LM28 series is a?aila&le
pac,a)e in her'etic TOB7: transistor pac,a)es* (hile the LM28C* LM28CA* an
LM28D are also a?aila&le in the plastic TOB transistor pac,a)e# The LM28D is also
a?aila&le in an 3Blea s%rface 'o%nt s'all o%tline pac,a)e an a plastic TOB 6
pac,a)e# 4i)%re 2#2 sho(s the pin ia)ra' an fi)%re 2#7 sho(s the te'perat%re
sensor %se in the project
".".1 F&' #+&4B
• Cali&rate irectly in Celsi%s >Centi)ra e@
• Linear P 16#6 'H. C scale factor
• 6#8 C acc%racy )%arantee a&le >at P 8 C@
• Rate for f%ll W88 to P186 C ran)e
• S%ita&le for re'ote applications
• Lo( cost %e to (aferBle?el tri''in)
• Operates fro' 7 to 26 ?olts
8
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 26/111
• Less than :6 XA c%rrent rain
• Lo( selfBheatin)* 6#63 C in still air
• Nonlinearity only 1V7 C typical n Lo( i'pe ance o%tp%t* 6#1 for 1 'A
loa
4i)%re 2#2/ 9in Dia)ra' of Te'perat%re Sensor
4i)%re 2#7/ LM28 Te'perat%re Sensor
".".! A** $:' $/)4B
The LM28 can &e applie easily in the sa'e (ay as other inte)rate Bcirc%it
te'perat%re sensors# It can &e )l%e or ce'ente to a s%rface an its te'perat%re (ill
&e (ithin a&o%t 6#61 C of the s%rface te'perat%re# This pres%'es that the a'&ient
air te'perat%re is al'ost the sa'e as the s%rface te'perat%re if the air te'perat%re
(ere '%ch hi)her or lo(er than the s%rface te'perat%re* the act%al te'perat%re of
the LM28 ie (o%l &e at an inter'e iate te'perat%re &et(een the s%rface
te'perat%re an the air te'perat%re# This is especially tr%e for the TOB plastic
:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 27/111
pac,a)e* (here the copper lea s are the principal ther'al path to carry heat into the
e?ice* so its te'perat%re 'i)ht &e closer to the air te'perat%re than to the s%rface
te'perat%re#
To 'ini'i e this pro&le'* &e s%re that the (irin) to the LM28* as it lea?es
the e?ice* is hel at the sa'e te'perat%re as the s%rface of interest# The easiest (ay
to o this is to co?er %p these (ires (ith a &ea of epo0y (hich (ill ins%re that the
lea s an (ires are all at the sa'e te'perat%re as the s%rface* an that the LM28
ie s te'perat%re (ill not &e affecte &y the air te'perat%re# The TOB7: 'etal
pac,a)e can also &e sol ere to a 'etal s%rface or pipe (itho%t a'a)e# Of co%rse*
in that case the HW ter'inal of the circ%it (ill &e )ro%n e to that 'etal#
Alternati?ely* the LM28 can &e 'o%nte insi e a seale Ben 'etal t%&e* an
can then &e ippe into a &ath or scre(e into a threa e hole in a tan,# As (ith any
IC* the LM28 an acco'panyin) (irin) an circ%its '%st &e ,ept ins%late an ry*
to a?oi lea,a)e an corrosion# This is especially tr%e if the circ%it 'ay operate at
col te'perat%res (here con ensation can occ%r# 9rinte Bcirc%it coatin)s an
?arnishes s%ch as %' seal an epo0y paints or ips are often %se to ins%re that
'oist%re cannot corro e the LM28 or its connections#
These e?ices are so'eti'es sol ere to a s'all li)htB(ei)ht heat fin* to
ecrease the ther'al ti'e constant an spee %p the response in slo(lyB'o?in) air#
On the other han * a s'all ther'al 'ass 'ay &e a e to the sensor* to )i?e the
stea iest rea in) espite s'all e?iations in the air te'perat%re#
". H&'+ <&' S&)4/+ LM"5 B
eart &eat is sense &y %sin) a hi)h intensity type LED an LDR# The fin)er
is place &et(een the LED an LDR# As Sensor a photo io e or a photo transistor
can &e %se # The s,in 'ay &e ill%'inate (ith ?isi&le >re @ %sin) trans'itte or
reflecte li)ht for etection# The ?ery s'all chan)es in reflecti?ity or in
;
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 28/111
trans'ittance ca%se &y the ?aryin) &loo content of h%'an tiss%e are al'ost
in?isi&le# Hario%s noise so%rces 'ay pro %ce ist%r&ance si)nals (ith a'plit% es
e-%al or e?en hi)her than the a'plit% e of the p%lse si)nal#
The ne( si)nal processin) approach presente here co'&ines analo) an i)italsi)nal processin) in a (ay that &oth parts can &e ,ept si'ple &%t in co'&ination are
?ery effecti?e in s%ppressin) ist%r&ance si)nals# The set%p escri&e here %ses a re
LED for trans'itte li)ht ill%'ination an a LDR as etector# ith only sli)ht
chan)es in the prea'plifier circ%it the sa'e har (are an soft(are co%l &e %se
(ith other ill%'ination an etection concepts# The etectors photo c%rrent >AC
9art@ is con?erte to ?olta)e an a'plifie &y an operational a'plifier >LM283@#
O%tp%t is )i?en to another nonBin?ertin) inp%t of the sa'e LM283 here the secon
a'plification is one# The ?al%e is preset in the in?ertin) inp%t* the a'plifie ?al%e
is co'pare (ith preset ?al%e if any a&nor'al con ition occ%rs it (ill )enerate an
interr%pt to the controller AT3 C 681 .#
". .1 F&' #+&4B
• eat &eat in ication &y LED
• Instant o%tp%t i)ital si)nal for irectly connectin) to 'icrocontroller
• Co'pact Si e
• Operatin) Holta)e P8H DC re)%late
• Operatin) C%rrent 166 'A
• O%tp%t Data Le?el 8H TTL le?el
• eart 5eat etection In icate &y LED an O%tp%t i)h 9%lse
• Li)ht so%rce ::6n' S%per Re LED
". .! A** $:' $/)4B
• Di)ital eart Rate 'onitor
• 9atient Monitorin) Syste'
• 5ioB4ee &ac, control of ro&otics an applications
3
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 29/111
4i)%re2#8 escri&es the internal circ%it of heart &eat sensor an fi)%re 2#: sho(s the
LM283 sensor of heart &eat sensor an fi)%re 2#; sho(s the si'%lation )raph of
heart &eat of the person#
Figure 3.5: Internal circuit of Heart beat Sensor
4i)%re 2#:/ LM283 eart&eat Sensor
".5 C/): #4$/)
The press%re* te'perat%re an heart&eat sensors are isc%sse # Usin) sensorsthe Analo) o%tp%ts are o&taine (hich are in electrical for' .
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 30/111
CHAPTER
MICROCONTROLLER PIC16F 77A
.1 I) +/%#: $/)
The 9IC is a 'icrocontroller (hich consists of an in&%ilt ADC* USART (hich are
'ainly %se in this project# ADC is %se for the con?ersion of Analo) o%tp%t of
sensors to i)ital an USART for serial asynchrono%s co''%nication#
.! M$:+/:/) +/ &+ C/+& F&' #+&4
Y i)hBperfor'ance RISC C9U#
Y Only 28 sin)le (or instr%ctions to learn#
Y All sin)le cycle instr%ctions e0cept for pro)ra' &ranches (hich are t(o cycle#
Y Operatin) spee / DC B 6 M cloc, inp%t DC B 66 ns instr%ction cycle#
Y Up to 3+ 0 17 (or s of 4LAS 9ro)ra' Me'ory* Up to 2:3 0 3 &ytes of Data
Me'ory >RAM@ Up to 8: 0 3 &ytes of EE9ROM ata 'e'ory#
Y 9in o%t co'pati&le to the 9IC1:C;25.;75.;:.;;
Y Interr%pt capa&ility >%p to 17 so%rces@
Y Ei)ht le?el eep har (are stac,
Y Direct* in irect an relati?e a ressin) 'o es#
Y 9o(erBon Reset >9OR@#
Y 9o(erB%p Ti'er >9 RT@ an Oscillator StartB%p Ti'er >OST@#
Y atch o) Ti'er > DT@ (ith its o(n onBchip RC oscillator for relia&le operation#
26
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 31/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 32/111
Y Ti'er1/ 1:B&it ti'er.co%nter (ith prescaler* can &e incre'ente %rin) sleep ?ia
e0ternal crystal.cloc,
Y Ti'er / 3B&it ti'er.co%nter (ith 3B&it perio re)ister* prescaler an postscaler
Y T(o Capt%re* Co'pare* 9 M 'o %les B Capt%re is 1:B&it* 'a0# Resol%tion is 1 #8 ns
B Co'pare is 1:B&it* 'a0# Resol%tion is 66 ns
B 9 M 'a0# Resol%tion is 16B&it
Y 16B&it '%ltiBchannel Analo)BtoBDi)ital con?erter
Y Synchrono%s Serial 9ort >SS9@ (ith S9IZ >Master Mo e@ an I C >Master.Sla?e@
Y Uni?ersal Synchrono%s Asynchrono%s Recei?er Trans'itter >USART.SCI@ (ith B
&it a ress etection
Y 9arallel Sla?e 9ort >9S9@ 3B&its (i e* (ith e0ternal RD* R an CS controls
>76.77Bpin only@
Y 5ro(nBo%t etection circ%itry for 5ro(nBo%t Reset >5OR@
. A+: $ &: #+&
2
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 33/111
4i)%re 7# / Internal Architect%re of 'icrocontroller 9IC1:43;;A
.5 P$) D&4:+$* $/)
.5.1 OSC19CLKIB
Oscillator crystal or e0ternal cloc, inp%t >or@ Oscillator crystal inp%t or
e0ternal cloc, so%rce inp%t# ST &%ffer (hen confi)%re in RC 'o e other(ise
CMOS# E0ternal cloc, so%rce inp%t# Al(ays associate (ith pin f%nction OSC1 >see
OSC1.CL+I* OSC .CL+O pins@#
.5.! OSC!9CLKOB
22
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 34/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 35/111
9ORTA is a :B&it (i e* &i irectional port# The correspon in) ata irection
re)ister is TRISA# Settin) a TRISA &it >[ 1@ (ill 'a,e the correspon in) 9ORTA
pin an inp%t >i#e#* p%t the correspon in) o%tp%t ri?er in a i)h I'pe ance 'o e@#
Clearin) a TRISA &it >[ 6@ (ill 'a,e the correspon in) 9ORTA pin an o%tp%t >i#e#* p%t the contents of the o%tp%t latch on the selecte pin@# Rea in) the 9ORTA re)ister
rea s the stat%s of the pins* (hereas (ritin) to it (ill (rite to the port latch# All (rite
operations are rea B'o ifyB(rite operations# Therefore* a (rite to a port i'plies that
the port pins are rea the ?al%e is 'o ifie an then (ritten to the port ata latch#
9in RA7 is '%ltiple0e (ith the Ti'er6 'o %le cloc, inp%t to &eco'e the
RA7.T6C+I pin# The RA7.T6C+I pin is a Sch'itt Tri))er inp%t an an openB rain
o%tp%t# All other 9ORTA pins ha?e TTL inp%t le?els an f%ll CMOS o%tp%t ri?ers#
Other 9ORTA pins are '%ltiple0e (ith analo) inp%ts an the analo) HRE4 inp%t
for &oth the A.D con?erters an the co'parators# The operation of each pin is
selecte &y clearin).settin) the appropriate control &its in the ADCON1 an .or
CMCON re)isters# The TRISA re)ister controls the irection of the port pins e?en
(hen they are &ein) %se as analo) inp%ts# The %ser '%st ens%re the &its in the
TRISA re)ister are 'aintaine set (hen %sin) the' as analo) inp%ts#
Note/ On a 9o(erBon Reset* these pins are confi)%re as analo) inp%ts an rea as
\6 # The co'parators are in the off > i)ital@#
.6.! PORT= ')% TRIS= R&3$4 &+B
9ORT5 is an 3B&it (i e* &i irectional port# The correspon in) ata irection
re)ister is TRIS5# Settin) a TRIS5 &it >[ 1@ (ill 'a,e the correspon in) 9ORT5
pin an inp%t >i#e#* p%t the correspon in) o%tp%t ri?er in a i)hBI'pe ance 'o e@#
Clearin) a TRIS5 &it >[ 6@ (ill 'a,e the correspon in) 9ORT5 pin an o%tp%t >i#e#*
p%t the contents of the o%tp%t latch on the selecte pin@# Three pins of 9ORT5 are
'%ltiple0e (ith the InBCirc%it De&%))er an Lo(BHolta)e 9ro)ra''in) f%nction/
R52.9GM* R5:.9GC an R5;.9GD#
4o%r of the 9ORT5 pins* R5;/R57* ha?e an interr%ptionB chan)e feat%re#
Only pins confi)%re as inp%ts can ca%se this interr%pt to occ%r >i#e#* any R5;/R57
28
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 36/111
pin confi)%re as an o%tp%t is e0cl% e fro' the interr%ptionB chan)e co'parison@#
The inp%t pins >of R5;/R57@ are co'pare (ith the ol ?al%e latche on the last
rea of 9ORT5# The "'is'atch$ o%tp%ts of R5;/R57 are OR e to)ether to
)enerate the R5 port chan)e interr%pt (ith fla) &it R5I4 >INTCON]6^@#
This interr%pt can (a,e the e?ice fro' Sleep# The %ser* in the Interr%pt
Ser?ice Ro%tine* can clear the interr%pt in the follo(in) 'anner/
a@ Any rea or (rite of 9ORT5# This (ill en the 'is'atch con ition#
&@ Clear fla) &it R5I4#
A 'is'atch con ition (ill contin%e to set fla) &it R5I4# Rea in) 9ORT5
(ill en the 'is'atch con ition an allo( fla) &it R5I4 to &e cleare # The interr%ptB
onBchan)e feat%re is reco''en e for (a,eB%p on ,ey epression operation an
operations (here 9ORT5 is only %se for the interr%ptBonBchan)e feat%re# 9ollin) of
9ORT5 is not reco''en e (hile %sin) the interr%ptBonB chan)e feat%re# This
interr%ptBonB'is'atch feat%re* to)ether (ith soft(are confi)%ra&le p%llB%ps on these
fo%r pins* allo( easy interface to a ,eypa an 'a,e it possi&le for (a,eB%p on ,ey
epression#
.6." PORTC ')% TRISC R&3$4 &+B
9ORTC is an 3B&it (i e* &i irectional port# The correspon in) ata irection
re)ister is TRISC# Settin) a TRISC &it >[ 1@ (ill 'a,e the correspon in) 9ORTC
pin an inp%t >i#e#* p%t the correspon in) o%tp%t ri?er in a i)hB I'pe ance 'o e@#
Clearin) a TRISC &it >[ 6@ (ill 'a,e the correspon in) 9ORTC pin an o%tp%t >i#e#*
p%t the contents of the o%tp%t latch on the selecte pin@# 9ORTC is '%ltiple0e (ith
se?eral peripheral f%nctions >Ta&le 7B8@# 9ORTC pins ha?e Sch'itt Tri))er inp%t
&%ffers# hen the I C 'o %le is ena&le * the 9ORTC]7/2^ pins can &e confi)%re
(ith nor'al I C le?els* or (ith SM5%s le?els* &y %sin) the C+E &it
>SS9STAT]:^@# hen ena&lin) peripheral f%nctions* care sho%l &e ta,en in
efinin) TRIS &its for each 9ORTC pin# So'e peripherals o?erri e the TRIS &it to
'a,e a pin an o%tp%t* (hile other peripherals o?erri e the TRIS &it to 'a,e a pin an
2:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 37/111
inp%t# Since the TRIS &it o?erri e is in effect (hile the peripheral is ena&le * rea B
'o ify (rite instr%ctions >5S4* 5C4* =OR 4@ (ith TRISC as the estination*
sho%l &e a?oi e # The %ser sho%l refer to the correspon in) peripheral section for
the correct TRIS &it settin)s#
.6. PORTD ')% TRISD R&3$4 &+B
9ORTD is an 3B&it port (ith Sch'itt Tri))er inp%t &%ffers# Each pin is
in i?i %ally confi)%ra&le as an inp%t or o%tp%t# 9ORTD can &e confi)%re as an 3B
&it (i e 'icroprocessor port >9arallel Sla?e 9ort@ &y settin) control &it* 9S9 MODE
>TRISE]7^@# In this 'o e* the inp%t &%ffers are TTL#
.6.5 PORTE ')% TRISE R&3$4 &+B
9ORTE has three pins >RE6.RD.AN8* RE1. R.AN: an RE .CS.AN;@
(hich are in i?i %ally confi)%ra&le as inp%ts or o%tp%ts# These pins ha?e Sch'itt
Tri))er inp%t &%ffers# The 9ORTE pins &eco'e the I.O control inp%ts for the
'icroprocessor port (hen &it 9S9MODE >TRISE]7^@ is set# In this 'o e* the %ser
'%st 'a,e certain that the TRISE] /6^ &its are set an that the pins are confi)%re
as i)ital inp%ts# Also* ens%re that ADCON1 is confi)%re for i)ital I.O# In this'o e* the inp%t &%ffers are TTL# Re)ister 7B1 sho(s the TRISE re)ister (hich also
controls the 9arallel Sla?e 9ort operation# 9ORTE pins are '%ltiple0e (ith analo)
inp%ts#
hen selecte for analo) inp%t* these pins (ill rea as \6 s# TRISE controls#
The irection of the RE pins* e?en (hen they are &ein) %se as analo) inp%ts# The
%ser '%st 'a,e s%re to ,eep the pins confi)%re as inp%ts (hen %sin) the' as analo)
inp%ts#
.7 M&(/+ O+3')$ ' $/)
There are three 'e'ory &loc,s in each of the 9IC1:43;=A e?ices# The
pro)ra' 'e'ory an ata 'e'ory ha?e separate &%ses so that conc%rrent access can
2;
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 38/111
occ%r an is etaile in this section# The EE9ROM ata 'e'ory an flah pro)ra'
'e'ory is also etaile #
.7.1 P+/3+'( M&(/+ O+3')$ ' $/)B
The 9IC1:43;=A e?ices ha?e a 12B&it pro)ra' co%nter capa&le of
a ressin) an 3+ (or 0 17 &it pro)ra' 'e'ory space# The 9IC1:43;:A.3;;A
e?ices ha?e 3+ (or s 0 17 &its of 4lash pro)ra' 'e'ory* (hile
9IC1:43;2A.3;7A e?ices ha?e 7+ (or s 0 17 &its# Accessin) a location a&o?e the
physically i'ple'ente a ress (ill ca%se a (raparo%n # The Reset ?ector is at
6666h an the interr%pt ?ector is at 6667h#
The ata 'e'ory is partitione into '%ltiple &an,s (hich contain theGeneral 9%rpose Re)isters an the Special 4%nction Re)isters# 5its R91 >Stat%s]:^@
an R96 >Stat%s]8^@ are the &an, select &its# Each &an, e0ten s %p to ;4h >1 3
&ytes@# The lo(er locations of each &an, are reser?e for the Special 4%nction
Re)isters# A&o?e the Special 4%nction Re)isters are General 9%rpose Re)isters*
i'ple'ente as static RAM# All i'ple'ente &an,s contain Special 4%nction
Re)isters# So'e fre-%ently %se Special 4%nction Re)isters fro' one &an, 'ay &e
'irrore in another &an, for co e re %ction an -%ic,er access#
4.7.2 D' ' M&(/+ O+3')$ ' $/)B
The ata 'e'ory is partitione into '%ltiple &an,s (hich contain the
General 9%rpose Re)isters an the Special 4%nction Re)isters# 5its R91 >Stat%s]:^@
an R96 >Stat%s]8^@ are the &an, select &its# Each &an, e0ten s %p to ;4h >1 3
&ytes@# The lo(er locations of each &an, are reser?e for the Special 4%nction
Re)isters# A&o?e the Special 4%nction Re)isters are General 9%rpose Re)isters*i'ple'ente as static RAM# All i'ple'ente &an,s contain Special 4%nction
Re)isters# So'e fre-%ently %se Special 4%nction Re)isters fro' one &an, 'ay &e
'irrore in another &an, for co e re %ction an -%ic,er access#
.7." D' ' EEPROM ')% F '4 P+/3+'( M&(/+ B
23
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 39/111
The ata EE9ROM an 4lash pro)ra' 'e'ory is rea a&le an (rita&le
%rin) nor'al operation >o?er the f%ll HDD ran)e@# This 'e'ory is not irectly
'appe in the re)ister file space# Instea * it is in irectly a resse thro%)h the
Special 4%nction Re)isters# There are si0 S4Rs %se to rea an (rite this 'e'ory#Y EECON1
Y EECON
Y EEDATA
Y EEDAT
Y EEADR
Y EEADR
. T$(&+4B
. .1 T$(&+0 M/%# &B
The Ti'er6 'o %le ti'er.co%nter has the follo(in) feat%res/
Y 3B&it ti'er.co%nter
Y Rea a&le an (rita&le
Y 3B&it soft(are pro)ra''a&le prescaler
Y Internal or e0ternal cloc, select
Y Interr%pt on o?erflo( fro' 44h to 66h
Y E )e select for e0ternal cloc,
Ti'er 'o e is selecte &y clearin) &it T6CS >O9TION_REG]8^@# In Ti'er
'o e* the Ti'er6 'o %le (ill incre'ent e?ery instr%ction cycle >(itho%t prescaler@#
If the TMR6 re)ister is (ritten* the incre'ent is inhi&ite for the follo(in) t(o
instr%ction cycles# The %ser can (or, aro%n this &y (ritin) an a j%ste ?al%e to the
TMR6 re)ister#
. .! T$(&+0 I) &++#* B
The TMR6 interr%pt is )enerate (hen the TMR6 re)ister o?erflo(s fro'
44h to 66h# This o?erflo( sets &it TMR6I4 >INTCON] ^@# The interr%pt can &e
'as,e &y clearin) &it TMR6IE >INTCON]8^@# 5it TMR6I4 '%st &e cleare in
soft(are &y the Ti'er6 'o %le Interr%pt Ser?ice Ro%tine &efore reBena&lin) this
2
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 40/111
interr%pt# The TMR6 interr%pt cannot a(a,en the processor fro' Sleep since the
ti'er is sh%tBoff %rin) Sleep#
. ." T$(&+1 M/%# &B
The Ti'er1 'o %le is a 1:B&it ti'er.co%nter consistin) of t(o 3B&it re)isters
>TMR1 an TMR1L@ (hich are rea a&le an (rita&le# The TMR1 re)ister pair
>TMR1 /TMR1L@ incre'ents fro' 6666h to 4444h an rolls o?er to 6666h# The
TMR1 interr%pt* if ena&le * is )enerate on o?erflo( (hich is latche in interr%pt
fla) &it* TMR1I4 >9IR1]6^@# This interr%pt can &e ena&le . isa&le &y settin) or
clearin) TMR1 interr%pt ena&le &it* TMR1IE >9IE1]6^@# Ti'er1 can operate in one
of t(o 'o es/
Y As a Ti'er
Y As a Co%nter
The operatin) 'o e is eter'ine &y the cloc, select &it* TMR1CS
>T1CON]1^@#In Ti'er 'o e* Ti'er1 incre'ents e?ery instr%ction cycle# In Co%nter
'o e* it incre'ents on e?ery risin) e )e of the e0ternal cloc, inp%t# Ti'er1 can &e
ena&le . isa&le &y settin).clearin) control &it* TMR1ON >T1CON]6^@#Ti'er1
also has an internal "Reset inp%t$# This Reset can &e )enerate &y either of the t(o
CC9 'o %les# Sho(s the Ti'er1 Control re)ister# hen the Ti'er1 oscillator is
ena&le >T1OSCEN is set@* the RC1.T1OSI.CC9 an RC6.T1OSO.T1C+I pins
&eco'e inp%ts# That is* the TRISC]1/6^ ?al%e is i)nore an these pins rea as \6 #
. . T$(&+! M/%# &B
Ti'er is an 3B&it ti'er (ith a prescaler an a postscaler# It can &e %se as
the 9 M ti'e &ase for the 9 M 'o e of the CC9 'o %le>s@# The TMR re)ister is
rea a&le an (rita&le an is cleare on any e?ice Reset# The inp%t cloc, >4OSC.7@
has a prescale option of 1/1* 1/7 or 1/1:* selecte &y control &its
T C+9S1/T C+9S6 >T CON]1/6^@# The Ti'er 'o %le has an 3B&it perio
re)ister* 9R # Ti'er incre'ents fro' 66h %ntil it 'atch 9R an then resets to 66h
on the ne0t incre'ent cycle# 9R is a rea a&le an (rita&le re)ister# The 9R
re)ister is initiali e to 44h %pon Reset# The 'atch o%tp%t of TMR )oes thro%)h a
76
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 41/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 42/111
Y A.D Res%lt Lo( Re)ister >ADRESL@
Y A.D Control Re)ister 6 >ADCON6@
Y A.D Control Re)ister 1 >ADCON1@
The ADCON6 re)ister* sho(n in Re)ister 11B1* controls the operation of the A.D'o %le# The ADCON1 re)ister* sho(n in Re)ister 11B * confi)%res the f%nctions of
the port pins# The port pins can &e confi)%re as analo) inp%ts >RA2 can also &e the
?olta)e reference@ or as i)ital I.O#
.11 S ): +/)/#4 ')% A4 ): +/)/#4 C/((#)$:' $/)4
There are t(o &asic types of serial co''%nications* synchrono%s an
asynchrono%s# ith synchrono%s co''%nications* the t(o e?ices initially
synchroni e the'sel?es to each other* an then contin%ally sen characters to stay in
sync# E?en (hen the ata is not really &ein) sent* a constant flo( of &its allo(s each
e?ice to ,no( (here the other is at any )i?en ti'e# That is* each character that is
sent is either act%al ata or an i le character# Synchrono%s co''%nications allo(s
faster ata transfer rates than asynchrono%s 'etho s* &eca%se a itional &its to 'ar,
the &e)innin) an en of each ata &yte are not re-%ire # The serial ports on I5M
style 9Cs are asynchrono%s e?ices an therefore only s%pport asynchrono%s serialco''%nications# Asynchrono%s 'eans no "synchroni ation$* an th%s oes not
re-%ire sen in) an recei?in) i le characters# o(e?er* the &e)innin) an en of
each &yte of ata '%st &e i entifie &y start an stop &its# The start &it in icates
(hen the ata &yte is a&o%t to &e)in an the stop &it si)nals (hen it en s# The
re-%ire'ent to sen these a itional t(o &its ca%ses asynchrono%s co''%nication to
&e sli)htly slo(er than synchrono%s ho(e?er it has the a ?anta)e that the processor
oes not ha?e to eal (ith the a itional i le characters#
.1! S&+$' C/((#)$:' $/)
A serial port sen s an recei?es ata one &it at a ti'e o?er one (ire# hile it
ta,es ei)ht ti'es as lon) as to transfer each &yte of ata this (ay* only a fe( (ires
7
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 43/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 44/111
5esi es the synchroni ation pro?i e &y the %se of start an stop &its* an
a itional &it calle a parity &it 'ay optionally &e trans'itte alon) (ith the ata# A
parity &it affor s a s'all a'o%nt of error chec,in)* to help etect ata corr%ption that
'i)ht occ%r %rin) trans'ission .
.1!. C'< & L&)3 4B
The MA=B 2 stan ar i'poses a ca&le len)th li'it of 86 feet# o% can
%s%ally i)nore this "stan ar $* since a ca&le can &e as lon) as 16666 feet at &a%
rates %p to 1 66 if yo% %se a hi)h -%ality* (ell shiel e ca&le# The e0ternal
en?iron'ent has a lar)e effect on len)ths for %nshiel e ca&les
.1" C/): #4$/)
9IC 'icrocontroller (ith its a ?ance feat%res li,e re %ce instr%ction set*
in&%ilt atch o) Ti'er* A%to'atic sleep 'o e* in&%ilt ADC an USART pro?i es
?ario%s n%'&er of applications#
CHAPTER - 5
GLO=AL SYSTEM FOR MO=ILE COMMUNICATION
77
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 45/111
5.1 I) +/%#: $/)
Glo&al syste' for 'o&ile co''%nication >GSM@ is a )lo&ally accepte
stan ar for i)ital cell%lar co''%nication# GSM is the na'e of a stan ar i ation
)ro%p esta&lishe in 1 3 to create a co''on E%ropean 'o&ile telephone stan ar
that (o%l for'%late specifications for a panBE%ropean 'o&ile cell%lar ra io syste'
operatin) at 66 M * It is esti'ate that 'any co%ntries o%tsi e of E%rope (ill join
the GSM partnership#
Cell%lar is one of the fastest )ro(in) an 'ost e'an in)
teleco''%nications applications# Thro%)ho%t the e?ol%tion of cell%lar
teleco''%nications* ?ario%s syste's ha?e &een e?elope (itho%t the &enefit of
stan ar i e specifications# This presente 'any pro&le's irectly relate to
co'pati&ility* especially (ith the e?elop'ent of i)ital ra io technolo)y# The GSM
stan ar is inten e to a ress these pro&le's#
4ro' 1 3 to 1 38 isc%ssions (ere hel to eci e &et(een &%il in) an
analo) or i)ital syste'# After '%ltiple fiel tests* a i)ital syste' (as a opte for
GSM# The ne0t tas, (as to eci e &et(een a narro( or &roa &an sol%tion# In May
1 3;* the narro(&an ti'e i?ision '%ltiple access >TDMA@ sol%tion (as chosen#
GSM pro?i es reco''en ations* not re-%ire'ents# The GSM specifications efinethe f%nctions an interface re-%ire'ents in etail &%t o not a ress the har (are#
The reason for this is to li'it the esi)ners as little as possi&le &%t still to 'a,e it
possi&le for the operators to &%y e-%ip'ent fro' ifferent s%ppliers# The GSM
net(or, is i?i e into three 'ajor syste's/ the s(itchin) syste' >SS@* the &ase
station syste' >5SS@* an the operation an s%pport syste' >OSS@#
5.! GSM A+: $ &: #+&
78
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 46/111
4i)%re 8#1/ GSM Architect%re
5." T & S2$ : $)3 S 4 &(
The s(itchin) syste' >SS@ is responsi&le for perfor'in) call processin) an
s%&scri&erBrelate f%nctions# The s(itchin) syste' incl% es the follo(in) f%nctional
%nits#
o'e Location Re)ister > LR@ The LR is a ata&ase %se for stora)e
an 'ana)e'ent of s%&scriptions# The LR is consi ere the 'ost i'portant
ata&ase* as it stores per'anent ata a&o%t s%&scri&ers* incl% in) a s%&scri&erFs
7:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 47/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 48/111
5.".".1 =SC The 5SC pro?i es all the control f%nctions an physical lin,s
&et(een the MSC an 5TS# It is a hi)hBcapacity s(itch that pro?i es f%nctions s%ch
as han o?er* cell confi)%ration ata* an control of ra io fre-%ency >R4@ po(er
le?els in &ase transcei?er stations# A n%'&er of 5SCs are ser?e &y an MSC#5.".".! =TS The 5TS han les the ra io interface to the 'o&ile station# The 5TS
is the ra io e-%ip'ent >transcei?ers an antennas@ nee e to ser?ice each cell in the
net(or,# A )ro%p of 5TSs are controlle &y a 5SC#
5.". T & O*&+' $/) ')% S#**/+ S 4 &(B
The operations an 'aintenance center >OMC@ is connecte to all e-%ip'ent
in the s(itchin) syste' an to the 5SC# The i'ple'entation of OMC is calle the
operation an s%pport syste' >OSS@# The OSS is the f%nctional entity fro' (hich
the net(or, operator 'onitors an controls the syste'# The p%rpose of OSS is to
offer the c%sto'er costBeffecti?e s%pport for centrali e * re)ional* an local
operational an 'aintenance acti?ities that are re-%ire for a GSM net(or,# An
i'portant f%nction of OSS is to pro?i e a net(or, o?er?ie( an s%pport the
'aintenance acti?ities of ifferent operation an 'aintenance or)ani ations#
5.".5. A%%$ $/)' F#): $/)' E &(&) 4B
5.".5.1 M&44'3& C&) &+ M E The M=E is a no e that pro?i es inte)rate
?oice* fa0* an ata 'essa)in)# Specifically* the M=E han les short 'essa)e
ser?ice* cell &roa cast* ?oice 'ail* fa0 'ail* eB'ail* an notification#
5.".5.! M/<$ & S&+ $:& N/%& MSN The MSN is the no e that han les the
'o&ile intelli)ent net(or, >IN@ ser?ices
# 5.".5." G' &2' M/<$ & S&+ $:&4 S2$ : $)3 C&) &+ GMSC A )ate(ay is a
no e %se to interconnect t(o net(or,s# The )ate(ay is often i'ple'ente in an
MSC# The MSC is then referre to as the GMSC#
5.".5. G4( I) &+2/+8$)3 U)$ GIWU The GI U consists of &oth har (are
an soft(are that pro?i es an interface to ?ario%s net(or,s for ata co''%nications#
73
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 49/111
Thro%)h the GI U* %sers can alternate &et(een speech an ata %rin) the sa'e
call# The GI U har (are e-%ip'ent is physically locate at the MSC.HLR
5. GSM C& # '+ N& 2/+8
GSM is a cell%lar net(or,* (hich 'eans that 'o&ile phones connect to it &y
searchin) for cells in the i''e iate ?icinity# GSM net(or,s operate in fo%r ifferent
fre-%ency ran)es# Most GSM net(or,s operate in the 66 M or 1366 M &an s#
So'e co%ntries in the A'ericas >incl% in) Cana a an the Unite States@ %se the
386 M an 1 66 M &an s &eca%se the 66 an 1366 M fre-%ency &an s
(ere alrea y allocate # The rarer 766 an 786 M fre-%ency &an s are assi)ne in
so'e co%ntries (here these fre-%encies (ere pre?io%sly %se for firstB)eneration
syste's#
GSMB 66 %ses 3 6 18 M to sen infor'ation fro' the 'o&ile station to
the &ase station >%plin,@ an 28 :6 M for the other irection > o(nlin,@*
pro?i in) 1 7 R4 channels >channel n%'&ers 1 to 1 7@ space at 66 , # D%ple0
spacin) of 78 M is %se # In so'e co%ntries the GSMB 66 &an has &een e0ten e
to co?er a lar)er fre-%ency ran)e# This Fe0ten e GSMF* EBGSM* %ses 336 18 M
>%plin,@ an 8 :6 M > o(nlin,@* a in) 86 channels >channel n%'&ers ;8 to
16 2 an 6@ to the ori)inal GSMB 66 &an # Ti'e i?ision '%ltiple0in) is %se to
allo( ei)ht f%llBrate or si0teen halfBrate speech channels per ra io fre-%ency channel#
There are ei)ht ra io ti'eslots >)i?in) ei)ht &%rst perio s@ )ro%pe into (hat is
calle a TDMA fra'e# alf rate channels %se alternate fra'es in the sa'e ti'eslot#
The channel ata rate for all 3 channels is ;6#322 ,&it.s* an the fra'e %ration is
7#:18 's#
GSM has %se a ?ariety of ?oice co ec s to s-%ee e 2#1 , a% io into
&et(een 8#: an 12 ,&it.s# Ori)inally* t(o co ecs* na'e after the types of ata
channel they (ere allocate * (ere %se * calle alf Rate >8#: ,&it.s@ an 4%ll Rate
>12 ,&it.s@# These %se a syste' &ase %pon linear pre icti?e co in) >L9C@# In
7
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 50/111
a ition to &ein) efficient (ith &itrates* these co ecs also 'a e it easier to i entify
'ore i'portant parts of the a% io* allo(in) the air interface layer to prioriti e an
&etter protect these parts of the si)nal
5.5 GSM N& 2/+8 C '44$ $:' $/)
There are fi?e ifferent cell si es in a GSM net(or, 'acro* 'icro* 9ico* fe'to an
%'&rella cells#
The co?era)e area of each cell ?aries accor in) to the i'ple'entation
en?iron'ent# Macro cells can &e re)ar e as cells (here the &ase station antenna is
installe on a 'ast or a &%il in) a&o?e a?era)e roof top le?el# Micro cells are cells(hose antenna hei)ht is %n er a?era)e roof top le?el they are typically %se in
%r&an areas# 9ico cells are s'all cells (hose co?era)e ia'eter is a fe( o en
'eters they are 'ainly %se in oors# 4e'to cells are cells esi)ne for %se in
resi ential or s'all &%siness en?iron'ents an connect to the ser?ice pro?i er s
net(or, ?ia a &roa &an internet connection# U'&rella cells are %se to co?er
sha o(e re)ions of s'aller cells an fill in )aps in co?era)e &et(een those cells#
Cell hori ontal ra i%s ?aries epen in) on antenna hei)ht* antenna )ain an
propa)ation con itions fro' a co%ple of h%n re 'eters to se?eral tens of
,ilo'eters# The lon)est istance the GSM specification s%pports in practical %se is
28 ,ilo'eters > 'i@# There are also se?eral i'ple'entations of the concept of an
e0ten e cell* (here the cell ra i%s co%l &e o%&le or e?en 'ore* epen in) on the
antenna syste'* the type of terrain an the ti'in) a ?ance#
In oor co?era)e is also s%pporte &y GSM an 'ay &e achie?e &y %sin) an
in oor pico cell &ase station* or an in oor repeater (ith istri&%te in oor antennas
fe thro%)h po(er splitters* to eli?er the ra io si)nals fro' an antenna o%t oors to
the separate in oor istri&%te antenna syste'# These are typically eploye (hen a
lot of call capacity is nee e in oors* for e0a'ple in shoppin) centers or airports#
86
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 51/111
o(e?er* this is not a prere-%isite* since in oor co?era)e is also pro?i e &y inB
&%il in) penetration of the ra io si)nals fro' near&y cells#
The 'o %lation %se in GSM is Ga%ssian 'ini'%'Bshift ,eyin) >GMS+@* a,in of contin%o%sBphase fre-%ency shift ,eyin)# In GMS+* the si)nal to &e
'o %late onto the carrier is first s'oothe (ith a Ga%ssian lo(Bpass filter prior to
&ein) fe to a fre-%ency 'o %lator* (hich )reatly re %ces the interference to
nei)h&orin)
5.6 GSM +')4($ &+
One of the ,ey feat%res of GSM is the S%&scri&er I entity Mo %le >SIM@*co''only ,no(n as a SIM car # The SIM is a etacha&le s'art car containin) the
%serFs s%&scription infor'ation an phone &oo,# This allo(s the %ser to retain his or
her infor'ation after s(itchin) han sets# Alternati?ely* the %ser can also chan)e
operators (hile retainin) the han set si'ply &y chan)in) the SIM# So'e operators
(ill &loc, this &y allo(in) the phone to %se only a sin)le SIM* or only a SIM iss%e
&y the' this practice is ,no(n as SIM loc,in) * an is ille)al in so'e co%ntries#
5.7 GSM 4&:#+$
GSM (as esi)ne (ith a 'o erate le?el of sec%rity# The syste' (as
esi)ne to a%thenticate the s%&scri&er %sin) a preBshare ,ey an challen)eB
response # Co''%nications &et(een the s%&scri&er an the &ase station can &e
encrypte # The e?elop'ent of UMTS intro %ces an optional USIM * that %ses a
lon)er a%thentication ,ey to )i?e )reater sec%rity* as (ell as '%t%ally a%thenticatin)
the net(or, an the %ser B (hereas GSM only a%thenticates the %ser to the net(or,
>an not ?ice ?ersa@# The sec%rity 'o el therefore offers confi entiality an
a%thentication* &%t li'ite a%thori ation capa&ilities* an no nonBrep% iation # GSM
%ses se?eral crypto)raphic al)orith's for sec%rity# The A8.1 an A8. strea'
ciphers are %se for ens%rin) o?erBtheBair ?oice pri?acy# A8.1 (as e?elope first
an is a stron)er al)orith' %se (ithin E%rope an the Unite States A8. is (ea,er
81
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 52/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 53/111
7@ 5ase %pon 'at%re an fiel Bpro?en platfor'* &ac,e %p &y o%r s%pport ser?ice*
fro' efinition to esi)n an pro %ction#
5.10 C/): #4$/)GSM is a cell%lar net(or,* (hich 'eans that 'o&ile phones connect to it &y
searchin) for cells in the i''e iate ?icinity# Architect%re* S(itchin) syste' an
classification are isc%sse #
CHAPTER - 6
IG=EE
82
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 54/111
6.1 I) +/%#: $/)
The na'e <i)5ee is eri?e fro' the erratic i))in) patterns 'any &ees
'a,e &et(een flo(ers (hen collectin) pollen# This is e?ocati?e of the in?isi&le (e&s
of connections e0istin) in a f%lly (ireless en?iron'ent# The stan ar itself is
re)%late &y a )ro%p ,no(n as the <i)5ee Alliance , (ith o?er 186 'e'&ers
(orl (i e#
hile 5l%etooth foc%ses on connecti?ity &et(een lar)e pac,et %ser
e?ices* s%ch as laptops* phones* an 'ajor peripherals* <i)5ee is esi)ne to
pro?i e hi)hly efficient connecti?ity &et(een s'all pac,et e?ices# As a res%lt ofits si'plifie operations* (hich are one to t(o f%ll or ers of 'a)nit% e less
co'ple0 than a co'para&le 5l%etooth e?ice* pricin) for <i)5ee e?ices is
e0tre'ely co'petiti?e* (ith f%ll no es a?aila&le for a fraction of the cost of a
5l%etooth no e#
<i)5ee e?ices are acti?ely li'ite to a thro%)hBrate of 86+&ps* operatin)
on the #7 G ISM &an * (hich is a?aila&le thro%)ho%t 'ost of the (orl #
<i)5ee has &een e?elope to 'eet the )ro(in) e'an for capa&le
(ireless net(or,in) &et(een n%'ero%s lo(Bpo(er e?ices# In in %stry <i)5ee is
&ein) %se for ne0t )eneration a%to'ate 'an%fact%rin)* (ith s'all trans'itters in
e?ery e?ice on the floor* allo(in) for co''%nication &et(een e?ices to a
central co'p%ter # This ne( le?el of co''%nication per'its finelyBt%ne re'ote
'onitorin) an 'anip%lation# In the cons%'er 'ar,et <i)5ee is &ein) e0plore
for e?erythin) fro' lin,in) lo(Bpo(er ho%sehol e?ices s%ch as s'o,e alar's to
a central ho%sin) control %nit* to centrali e li)ht controls#
The specifie 'a0i'%' ran)e of operation for <i)5ee e?ices is 86 feet
>;:'@* s%&stantially f%rther than that %se &y 5l%etooth capa&le e?ices* altho%)h
sec%rity concerns raise o?er snipin) 5l%etooth e?ices re'otely* 'ay pro?e to
hol tr%e for <i)5ee e?ices as (ell#
87
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 55/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 56/111
tal, only to an 44D# An R4D is inten e for applications that are e0tre'ely si'ple*
s%ch as a li)ht s(itch or a passi?e infrare sensor they o not ha?e the nee to sen
lar)e a'o%nts of ata an 'ay only associate (ith a sin)le 44D at a ti'e#
Conse-%ently* the R4D can &e i'ple'ente %sin) 'ini'al reso%rces an 'e'orycapacity#
6.! N& 2/+8 /*/ /3$&4
Depen in) on the application re-%ire'ents* an IEEE 36 #18#7 LRB 9AN
'ay operate in either of t(o topolo)ies/ the star topolo)y or the peerBtoBpeer
topolo)y# 5oth are sho(n in 4i)%re 0# In the star topolo)y the co''%nication is
esta&lishe &et(een e?ices an a sin)le central controller* calle the 9ANcoor inator# A e?ice typically has so'e associate application an is either the
initiation point or the ter'ination point for net(or, co''%nications#
A 9AN coor inator 'ay also ha?e a specific application* &%t it can &e %se to
initiate* ter'inate* or ro%te co''%nication aro%n the net(or,# The 9AN
coor inator is the pri'ary controller of the 9AN# All e?ices operatin) on a net(or,
of either topolo)y shall ha?e %ni-%e :7B &it a resses# This a ress 'ay &e %se for
irect co''%nication (ithin the 9AN* or a short a ress 'ay &e allocate &y the
9AN coor inator (hen the e?ice associates an %se instea #
The 9AN coor inator 'i)ht often &e 'ains po(ere * (hile the e?ices (ill
'ost li,ely &e &attery po(ere # Applications that &enefit fro' a star topolo)y
incl% e ho'e a%to'ation* personal co'p%ter >9C@ peripherals* toys an )a'es* an
personal health care#
8:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 57/111
4i)%re :#1/ star an peer to peer Topolo)ies
The peerBtoBpeer topolo)y also has a 9AN coor inator ho(e?er* it iffers
fro' the star topolo)y in that any e?ice 'ay co''%nicate (ith any other e?ice as
lon) as they are in ran)e of one another# 9eerBtoBpeer topolo)y allo(s 'ore co'ple0
net(or, for'ations to &e i'ple'ente * s%ch as 'esh net(or,in) topolo)y#
Applications s%ch as in %strial control an 'onitorin)* (ireless sensor net(or,s*
asset an in?entory trac,in)* intelli)ent a)ric%lt%re* an sec%rity (o%l &enefit fro'
s%ch a net(or, topolo)y# A peerBtoBpeer net(or, can &e a hoc* selfBor)ani in)* an
selfBhealin)# It 'ay also allo( '%ltiple hops to ro%te 'essa)es fro' any e?ice to
any other e?ice on the net(or,# S%ch f%nctions can &e a e at the hi)her layer* &%tare not part of this stan ar #
Each in epen ent 9AN selects a %ni-%e i entifier# This 9AN i entifier allo(s
co''%nication &et(een e?ices (ithin a net(or, %sin) short a resses an ena&les
trans'issions &et(een e?ices across in epen ent net(or,s#
6." A+: $ &: #+&
The IEEE 36 #18#7 architect%re is efine in ter's of a n%'&er of &loc,s inor er to si'plify the stan ar # These &loc,s are calle layers# Each layer is
responsi&le for one part of the stan ar an offers ser?ices to the hi)her layers# The
layo%t of the &loc,s is &ase on the open syste's interconnection >OSI@ se?enBlayer
'o el# The interfaces &et(een the layers ser?e to efine the lo)ical lin,s that are
escri&e in this stan ar # An LRB 9AN e?ice co'prises a 9 * (hich contains
8;
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 58/111
the ra io fre-%ency >R4@ transcei?er alon) (ith its lo(Ble?el control 'echanis'* an
a MAC s%&Blayer that pro?i es access to the physical channel for all types of
transfer# 4i)%re :# sho(s these &loc,s in a )raphical representation
4i)%re :# / $3=&& 4 ':8 '+: $ &: #+&
The %pper layers* sho(n in 4i)%re y* consist of a net(or, layer* (hich
pro?i es net(or, confi)%ration* 'anip%lation* an 'essa)e ro%tin)* an an
application layer* (hich pro?i es the inten e f%nction of the e?ice#
6.".1 P 4$:' ' &+ PHY B
The 9 pro?i es t(o ser?ices/ the 9 ata ser?ice an the 9
'ana)e'ent ser?ice interfacin) to the physical layer 'ana)e'ent entity >9LME@
ser?ice access point >SA9@ >,no(n as the 9LMEBSA9@# The 9 ata ser?ice
ena&les the trans'ission an reception of 9 protocol ata %nits >99DUs@ across
the physical ra io channel# The feat%res of the 9 are acti?ation an eacti?ation
83
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 59/111
of the ra io transcei?er* ED* LbI* channel selection* clear channel assess'ent
>CCA@* an trans'ittin) as (ell as recei?in) pac,ets across the physical 'e i%'#
The ra io operates at one or 'ore of the follo(in) %nlicense &an s/
•
3:3 3:3#: M >e#)#* E%rope@• 6 3 M >e#)#* North A'erica@
• 766 732#8 M >(orl (i e@
6.".! MAC 4#< ' &+B
The MAC s%& layer pro?i es t(o ser?ices/ the MAC ata ser?ice an the
MAC 'ana)e'ent ser?ice interfacin) to the MAC s%& layer 'ana)e'ent entity
>MLME@ ser?ice access point >SA9@ >,no(n as MLMEBSA9@# The MAC ata
ser?ice ena&les the trans'ission an reception of MAC protocol ata %nits >M9DUs@
across the 9 ata ser?ice# The feat%res of the MAC s%& layer are &eacon
'ana)e'ent* channel access* GTS 'ana)e'ent* fra'e ?ali ation* ac,no(le )e
fra'e eli?ery* association* an isassociation# In a ition* the MAC s%& layer
pro?i es hoo,s for i'ple'entin) applicationBappropriate sec%rity 'echanis's#
4i)%re :#2/ MAC S%&layer
8
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 60/111
6.".!.1 D' ' F+'(&B
The ata fra'e pro?i es a payloa of %p to 167 &ytes# The fra'e is n%'&ere
to ens%re that all pac,ets are trac,e # A fra'eBchec, se-%ence ens%res that pac,ets
are recei?e (itho%t error# This fra'e str%ct%re i'pro?es relia&ility in iffic%ltcon itions#
6.".!.! A:8)/2 &%3(&) ACK +'(&B
Another i'portant str%ct%re for 36 #18#7 is the ac,no(le )'ent >AC+@
fra'e# It pro?i es fee &ac, fro' the recei?er to the sen er confir'in) that the
pac,et (as recei?e (itho%t error# The e?ice ta,es a ?anta)e of specifie -%iet
ti'e &et(een fra'es to sen a short pac,et i''e iately after the ataBpac,ettrans'ission#
6.".!." MAC :/((')% +'(&B
A MAC co''an fra'e pro?i es the 'echanis' for re'ote control an
confi)%ration of client no es# A centrali e net(or, 'ana)er %ses MAC to
confi)%re in i?i %al clientsF co''an fra'es no 'atter ho( lar)e the net(or,#
6.".!. =&':/) +'(&B
4inally* the &eacon fra'e (a,es %p client e?ices* (hich listen for their
a ress an )o &ac, to sleep if they onFt recei?e it# 5eacons are i'portant for 'esh
an cl%sterBtree net(or,s to ,eep all the no es synchroni e (itho%t re-%irin) those
no es to cons%'e precio%s &attery ener)y &y listenin) for lon) perio s of ti'e#
6. D' ' T+')4 &+ M/%&Three types of ata transfer transactions e0ist# The first one is the ata
transfer to a coor inator in (hich a e?ice trans'its the ata# The secon transaction
is the ata transfer fro' a coor inator in (hich the e?ice recei?es the ata# The
thir transaction is the ata transfer &et(een t(o peer e?ices# In star topolo)y* only
t(o of these transactions are %se &eca%se ata 'ay &e e0chan)e only &et(een the
:6
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 61/111
coor inator an a e?ice# In a peerBtoBpeer topolo)y* ata 'ay &e e0chan)e
&et(een any t(o e?ices on the net(or, conse-%ently all three transactions 'ay &e
%se in this topolo)y#
The 'echanis's for each transfer type epen on (hether the net(or,s%pports the trans'ission of &eacons# A &eaconBena&le 9AN is %se in net(or,s
that either re-%ire synchroni ation or s%pport for lo( latency e?ices* s%ch as 9C
peripherals# If the net(or, oes not nee synchroni ation or s%pport for lo(Blatency
e?ices* it can elect not to %se the &eacon for nor'al transfers# o(e?er* the &eacon
is still re-%ire for net(or, isco?ery#
6.5 D& $:& T *&4
<i)&ee net(or,s %se three e?ice types/
• The net(or, coor inator 'aintains o?erall net(or, ,no(le )e# ItFs the 'ost
sophisticate of the three types an re-%ires the 'ost 'e'ory an co'p%tin)
po(er#
• The f%ll f%nction e?ice >44D ) s%pports all 36 #18#7 f%nctions an feat%res
specifie &y the stan ar # It can f%nction as a net(or, coor inator#
A itional 'e'ory an co'p%tin) po(er 'a,e it i eal for net(or, ro%terf%nctions or it co%l &e %se in net(or,Be )e e?ices >(here the net(or,
to%ches the real (orl @#
• The re %ce f%nction e?ice >R4D@ carries li'ite >as specifie &y the
stan ar @ f%nctionality to lo(er cost an co'ple0ity# ItFs )enerally fo%n in
net(or,Be )e e?ices#
6.6 S&:#+$
Sec%rity an ata inte)rity are ,ey &enefits of the <i)5ee technolo)y# <i)5ee
le?era)es the sec%rity 'o el of the IEEE 36 #18#7 MAC s%& layer (hich specifies
fo%r sec%rity ser?ices/
:1
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 62/111
• Access control the e?ice 'aintains a list of tr%ste e?ices (ithin the
net(or,#
• Data encryption* (hich %ses sy''etric ,ey 1 3B&it a ?ance encryption
stan ar #• 4ra'e inte)rity to protect ata fro' &ein) 'o ifie &y parties (itho%t
crypto)raphic ,eys#
• Se-%ential freshness to reject ata fra'es that ha?e &een replaye the
net(or, controller co'pares the freshness ?al%e (ith the last ,no(n ?al%e
fro' the e?ice an rejects it if the freshness ?al%e has not &een %p ate to a
16666666n*e( ?al%e#
6.7 C/): #4$/)
<i)&ee (ith its lon) &attery life* lo(Bcost * (ireless ran)e %p to ;6' in oors
an 766' o%t oors (ith f%ll control of trans'itte o%tp%t po(er ha?e
net(or,in) fle0i&ility to co?er entire ca'p%ses an s%pports '%ltiple net(or,
topolo)ies enco%ntere in ho'e an professional settin)s#
:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 63/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 64/111
7.! DCE ')% DTE %& $:&4B
T(o ter's yo% sho%l &e fa'iliar (ith are DTE an DCE# DTE stan s forData Ter'inal E-%ip'ent* an DCE stan s for Data Co''%nication E-%ip'ent#
These ter's are %se to in icate the pinBo%t for the connectors on a e?ice an the
irection of the si)nals on the pins# o%r co'p%ter is a DTE e?ice* (hile 'ost
other e?ices are %s%ally DCE e?ices# If yo% ha?e tro%&le ,eepin) the t(o strai)ht
then replace the ter' "DTE e?ice$ (ith yo%r 9C an the ter' DCE e?ice (ith
"re'ote De?ice$ in the follo(in) isc%ssion# The RSB 2 stan ar states that DTE
e?ices %se a 8Bpin 'ale connector* an DCE e?ices %se a 8Bpin fe'aleconnector# o% can therefore connect a DTE e?ice to a DCE %sin) a strai)ht pinB
forBpin connection# o(e?er* to connect t(o li,e e?ices* yo% '%st instea %se a
n%ll 'o e' ca&le# N%ll 'o e' ca&les cross the trans'it an recei?e lines in the
ca&le#
The DTE e?ice p%ts this line in a 'ar, con ition to tell the re'ote e?ice
that it is rea y an a&le to recei?e ata# If the DTE e?ice is not a&le to recei?e ata
>typically &eca%se its recei?e &%ffer is al'ost f%ll@* it (ill p%t this line in the space
con ition as a si)nal to the DCE to stop sen in) ata# hen the DTE e?ice is rea y
to recei?e 'ore ata it (ill place this line &ac, in the 'ar, con ition# The
co'ple'ent of the RTS (ire is CTS* (hich stan s for Clear to Sen # The DCE
e?ice p%ts this line in a 'ar, con ition to tell the DTE e?ice that it is rea y to
recei?e the ata# Li,e(ise* if the DCE e?ice is %na&le to recei?e ata* it (ill place
this line in the space con ition# To)ether* these t(o lines 'a,e %p (hat is calle
RTS.CTS or "har (are$ flo( control# The soft(are (e )e s%pports this type of flo(
control as (ell as =on.=off or "soft(are$ flo( control# Soft(are flo( control %ses
special control characters trans'itte fro' one e?ice to another to tell the other
e?ice to stop or start sen in) ata# ith soft(are flo( control the RTS an CTS
lines are not %se #
DTR stan s for Data Ter'inal Rea y# Its inten e f%nction is ?ery si'ilar to
the RTS line# DSR >Data Set Rea y@ is the co'panion to DTR in the sa'e (ay that
:7
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 65/111
CTS is to RTS# So'e serial e?ices %se DTR an DSR as si)nals to si'plify confir'
that a e?ice is connecte an t%rne on# The soft(are (e )e sets DTR to the 'ar,
state (hen the serial port is opene an lea?es it in that state %ntil the port is close #
The DTR an DSR lines (ere ori)inally esi)ne to pro?i e an alternate 'etho ofhar (are han sha,in)# It (o%l &e pointless to %se &oth RTS.CTS an DTR.DSR
for flo( control si)nals at the sa'e ti'e# 5eca%se of this DTR an DSR are rarely
%se for flo( control#
7." C/): #4$/)
MA= 2 is %se for the con?ersion of ?olta)e si)nals fro' TTL to CMOS
lo)ic an ?ice ?ersa#
:8
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 66/111
CHAPTER
POWER SUPPLY UNIT
.1 I) +/%#: $/)
4i)%re 3#1 sho(s the circ%it ia)ra' of po(er s%pply %nit a step o(n
transfor'er#
4i)%re 3#1/ circ%it ia)ra' of po(er s%pply %nit
9o(er s%pply %nit consists of follo(in) %nits/
i@ Step o(n transfor'er
ii@ Rectifier %nit
iii@ Inp%t filter
i?@#Re)%lator %nit
?@ O%tp%t filter
.! S &* %/2) T+')4 /+(&+
The Step o(n Transfor'er is %se to step o(n the 'ain s%pply ?olta)e fro'
26H AC to lo(er ?al%e# This 26 AC ?olta)e cannot &e %se irectly* th%s it is steppe
o(n# The Transfor'er consists of pri'ary an secon ary coils# To re %ce or step o(n
the ?olta)e* the transfor'er is esi)ne to contain less n%'&er of t%rns in its secon ary
::
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 67/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 68/111
4i)%re 3# / 4%ll (a?e Rectifier
."." =+$%3& +&: $ $&+B
A &ri )e rectifier 'a,es %se of fo%r io es in a &ri )e arran)e'ent to achie?e
f%llB(a?e rectification# This is a (i ely %se confi)%ration* &oth (ith in i?i %al io es
(ire as sho(n an (ith sin)le co'ponent &ri )es (here the io e &ri )e is (ire
internally#
4i)%re 3#2 5ri )e Rectifier
A io e &ri )e or &ri )e rectifier is an arran)e'ent of fo%r io es in a &ri )e
confi)%ration that pro?i es the sa'e polarity of o%tp%t?olta)e for either polarity of inp%t
?olta)e# hen %se in its 'ost co''on application* for con?ersion of alternatin) c%rrent
>AC@ inp%t into irect c%rrent >DC@ o%tp%t* it is ,no(n as a &ri )e rectifier # A &ri )e
:3
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 69/111
rectifier pro?i es f%llB(a?e rectification fro' a t(oB(ire AC inp%t* res%ltin) in lo(er
cost an (ei)ht as co'pare to a centerBtappe transfor'er esi)n#
The 4or(ar 5ias is achie?e &y connectin) the io e s positi?e (ith positi?e
of the &attery an ne)ati?e (ith &attery s ne)ati?e# The efficient circ%it %se is the 4%ll
(a?e 5ri )e rectifier circ%it# The o%tp%t ?olta)e of the rectifier is in ripple for'* the
ripples fro' the o&taine DC ?olta)e are re'o?e %sin) other circ%its a?aila&le# The
circ%it %se for re'o?in) the ripples is calle 4ilter circ%it#
. I)*# $ &+
Capacitors are %se as filter# The ripples fro' the DC ?olta)e are re'o?e an
p%re DC ?olta)e is o&taine # An also these capacitors are %se to re %ce the har'onics
of the inp%t ?olta)e# The pri'ary action perfor'e &y capacitor is char)in) an
ischar)in)# It char)es in positi?e half cycle of the AC ?olta)e an it (ill ischar)e in
ne)ati?e half cycle# So it allo(s only AC ?olta)e an oes not allo( the DC ?olta)e# This
filter is fi0e &efore the re)%lator# Th%s the o%tp%t is free fro' ripples#
There are t(o types of filters# They are
1# Lo( pass filter
# i)h pass filter
. .1 L/2 *'44 $ &+B
One si'ple electrical circ%it that (ill ser?e as a lo(Bpass filter consists of a
resistor in series (ith a loa * an a capacitor in parallel (ith the loa # The capacitore0hi&its reactance * an &loc,s lo(Bfre-%ency si)nals* ca%sin) the' to )o thro%)h the loa
instea # At hi)her fre-%encies the reactance rops* an the capacitor effecti?ely f%nctions
as a short circ%it# The co'&ination of resistance an capacitance )i?es yo% the ti'e
constant of the filter [ RC >represente &y the Gree, letter ta%@# The &rea, fre-%ency*
also calle the t%rno?er fre-%ency or c%toff fre-%ency >in hert @* is eter'ine &y the
ti'e constant/ or e-%i?alently >in ra ians per secon @/
:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 70/111
One (ay to %n erstan this circ%it is to foc%s on the ti'e the capacitor ta,es to
char)e# It ta,es ti'e to char)e or ischar)e the capacitor thro%)h that resistor/
• At lo( fre-%encies* there is plenty of ti'e for the capacitor to char)e %p to
practically the sa'e ?olta)e as the inp%t ?olta)e#
• At hi)h fre-%encies* the capacitor only has ti'e to char)e %p a s'all a'o%nt
&efore the inp%t s(itches irection# The o%tp%t )oes %p an o(n only a s'all
fraction of the a'o%nt the inp%t )oes %p an o(n# At o%&le the fre-%ency*
thereFs only ti'e for it to char)e %p half the a'o%nt
•
Another (ay to %n erstan this circ%it is (ith the i ea of reactance at a partic%larfre-%ency/
• Since DC cannot flo( thro%)h the capacitor* DC inp%t '%st flo( o%t the path
'ar,e V o%t >analo)o%s to re'o?in) the capacitor@#
• Since AC flo(s ?ery (ell thro%)h the capacitor al'ost as (ell as it flo(s
thro%)h soli (ire AC inp%t flo(s o%t thro%)h the capacitor* effecti?ely
short circ%itin) to )ro%n >analo)o%s to replacin) the capacitor (ith j%st a (ire@#
• It sho%l &e note that the capacitor is not an on.off o&ject >li,e the &loc, or
pass fl%i ic e0planation a&o?e@# The capacitor (ill ?aria&ly act &et(een these t(o
e0tre'es# It is the 5o e plot an fre-%ency response that sho( this ?aria&ility#
. .! H$3 *'44 $ &+B
The a&o?e circ%it ia)ra' ill%strates a si'ple 'RC' hi)hBpass filter# (e sho%l fin
that the circ%it passes Fhi)hF fre-%encies fairly (ell* &%t atten%ates Flo(F fre-%encies#
ence it is %sef%l as a filter to &loc, any %n(ante lo( fre-%ency co'ponents of a
co'ple0 si)nal (hilst passin) hi)her fre-%encies# Circ%its li,e this are %se -%ite a lot in
electronics as a FD#C# 5loc,F B i#e# to pass a#c# si)nals &%t pre?ent any D#C# ?olta)es fro'
)ettin) thro%)h#
;6
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 71/111
The &asic -%antities (hich escri&e this circ%it are si'ilar to those %se for the
Lo( 9ass 4ilter # In effect* this circ%it is j%st a si'ple lo(Bpass filter (ith the co'ponents
s(appe o?er# As (ith the lo(Bpass filter* the circ%itFs &eha?ior (e can &e %n erstoo as
arisin) %e to the ti'e ta,en to chan)e the capacitorFs char)e (hen (e alter the applieinp%t ?olta)e# It al(ays ta,es a finite >i#e# nonB ero@ ti'e to chan)e the a'o%nt of char)e
store &y the capacitor# ence it ta,es ti'e to chan)e the potential ifference across the
capacitor# As a res%lt* any s% en chan)e in the inp%t ?olta)e pro %ces a si'ilar s% en
chan)e on the other si e of the capacitor# This pro %ces a ?olta)e across the resistor an
ca%ses a c%rrent to flo( thoro%)h it* char)in) the capacitor %ntil all the ?olta)e falls
across it instea of the resistor#
.5 R&3# ' /+ U)$
4i)%re 3#7/ ;368 Re)%lator
Re)%lator re)%lates the o%tp%t ?olta)e to &e al(ays constant# The o%tp%t ?olta)e is
'aintaine irrespecti?e of the fl%ct%ations in the inp%t AC ?olta)e# As an then the AC
?olta)e chan)es* the DC ?olta)e also chan)es# Th%s to a?oi this Re)%lators are %se #
Also (hen the internal resistance of the po(er s%pply is )reater than 26 oh's* the o%tp%t
)ets affecte # Th%s this can &e s%ccessf%lly re %ce here# The re)%lators are 'ainly
classifie for lo( ?olta)e an for hi)h ?olta)e# 4%rther they can also &e classifie as/
i@ 9ositi?e re)%lator
1BBB^ inp%t pin
BBB^ )ro%n pin
2BBB^ o%tp%t pin
It re)%lates the positi?e ?olta)e#
;1
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 72/111
ii@ Ne)ati?e re)%lator
1BBB^ )ro%n pin
BBB^ inp%t pin
2BBB^ o%tp%t pinIt re)%lates the ne)ati?e ?olta)e#
.6 F$;&% R&3# ' /+4
4i)%re 3#8/ An assort'ent of ;300 series ICs
4i0e threeBter'inal linear re)%lators are co''only a?aila&le to )enerate fi0e
?olta)es of pl%s 2 H* an pl%s or 'in%s 8 H* H* 1 H* or 18 H (hen the loa is less than
a&o%t ; a'peres #
.7 7 05 V/ '3& R&3# ' /+
The ;368 pro?i es circ%it esi)ners (ith an easy (ay to re)%late DC ?olta)es to
8?# Encaps%late in a sin)le chip.pac,a)e >IC@* the ;368 is a positi?e ?olta)e DC
re)%lator that has only 2 ter'inals# They are/ Inp%t ?olta)e* Gro%n * O%tp%t Holta)e#
.7.1 G&)&+' F&' #+&4B
• O%tp%t C%rrent %p to 1A
• O%tp%t Holta)es of 8* :* 3* * 16* 1 * 18* 13* 7H
• Ther'al O?erloa 9rotection
• Short Circ%it 9rotection
;
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 73/111
• O%tp%t Transistor Safe Operatin) Area 9rotection
. 7 1! 1!V I) &3+' &% C$+:#$ "-T&+($)' P/4$ $ & V/ '3& R&3# ' /+
The ;31 fi0e ?olta)e re)%lator is a 'onolithic inte)rate circ%it in a TO 6
type pac,a)e esi)ne for %se in a (i e ?ariety of applications incl% in) local* on&oar
re)%lation# This re)%lator e'ploys internal c%rrent li'itin)* ther'al sh%t o(n* an safe
area co'pensation#
ith a e-%ate heatBsin,in) it can eli?er o%tp%t c%rrents in e0cess of 1#6 a'pere#
Altho%)h esi)ne pri'arily as a fi0e ?olta)e re)%lator* this e?ice can &e %se (ith
e0ternal co'ponents to o&tain a j%sta&le ?olta)es an c%rrents#
. O# *# $ &+
The 4ilter circ%it is often fi0e after the Re)%lator circ%it# Capacitor is 'ost often
%se as filter# The principle of the capacitor is to char)e an ischar)e# It char)es %rin)
the positi?e half cycle of the AC ?olta)e an ischar)es %rin) the ne)ati?e half cycle# So
it allo(s only AC ?olta)e an oes not allo( the DC ?olta)e# This filter is fi0e after the
Re)%lator circ%it to filter any of the possi&ly fo%n ripples in the o%tp%t recei?e finally#
ere (e %se 6#1 4 capacitor# The o%tp%t at this sta)e is 8H an is )i?en to the
Microcontroller# The o%tp%t ?olta)e o?ershoots (hen the loa is re'o?e or a short
clears# hen the loa is re'o?in) fro' a s(itchin) 'o e po(er s%pply (ith a LC lo(B
pass o%tp%t filter* the only thin) the control loop can o is stop the s(itchin) action so no
'ore ener)y is ta,en fro' the so%rce# The ener)y that is store in the o%tp%t filter
in %ctor is %'pe into the o%tp%t capacitor ca%sin) a ?olta)e o?ershoot#
The 'a)nit% e of the o?ershoot is the ?ector s%' of t(o ortho)onal ?olta)es* the
o%tp%t ?olta)e &efore the loa is re'o?e an the c%rrent thro%)h the in %ctor ti'es the
characteristic i'pe ance of the o%tp%t filter* <o [ >L.C@d1. # This can &e eri?e fro'
conser?ation of ener)y consi erations#
;2
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 74/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 75/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 76/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 77/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 78/111
appropriate place on the screen# Until no( (e isc%sse the operation of (ritin) an
rea in) to an LCD as if it (ere an or inary 'e'ory# 5%t this is not so# The LCD
controller nee s 76 to 1 6 'icrosecon s >%S@ for (ritin) an rea in)# Other
operations can ta,e %p to 8 'S# D%rin) that ti'e* the 'icrocontroller can not accessthe LCD* so a pro)ra' nee s to ,no( (hen the LCD is &%sy# e can sol?e this in
t(o (ays#
One (ay is to chec, the 5US &it fo%n on ata line D;# This is not the &est
'etho &eca%se LCDFs can )et st%c,* an pro)ra' (ill then stay fore?er in a loop
chec,in) the 5US &it# The other (ay is to intro %ce a elay in the pro)ra'# The
elay has to &e lon) eno%)h for the LCD to finish the operation in process#
At the &e)innin) (e 'entione that (e nee e 11 I.O lines to co''%nicate
(ith an LCD# o(e?er* (e can co''%nicate (ith an LCD thro%)h a 7B&it ata &%s#
Th%s (e can re %ce the total n%'&er of co''%nication lines to se?en# The (irin)
for connection ?ia a 7B&it ata &%s is sho(n in the ia)ra' &elo(# In this e0a'ple
(e %se an LCD isplay (ith 01: characters* la&ele LM1:= 1 &y Qapanese 'a,er
S AR9# The 'essa)e FcharacterF is (ritten in the first ro(/ an t(o special
characters F F an FgF are isplaye # In the secon ro( (e ha?e pro %ce the (or
F'i,roEle,troni,aF#
. C/): #4$/)
This 01: LCD is capa&le of isplayin) 2 characters at a ti'e# LCD
isplays are %se in the project one in the trans'itter an the other in recei?er#
;3
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 79/111
CHAPTER - 10
SOFTWARE RE UIREMENTS
10.1 I) +/%#: $/)
The soft(are tools %se for the co in) in the e0peri'ent are/
• M9LA5
• 9rotel
• 9ropic
• IBTech 9IC C Co'piler
10.! MPLA= I) &3+' $/)
M9LA5 Inte)rate De?elop'ent En?iron'ent >IDE@ is a free* inte)rate
toolset for the e?elop'ent of e'&e e applications e'ployin) MicrochipFs 9IC
'icro an s9IC 'icrocontrollers# M9LA5 IDE r%ns as a 2 B&it application on MS
in o(s* is easy to %se an incl% es a host of free soft(are co'ponents for fast
application e?elop'ent an s%perBchar)e e&%))in)# M9LA5 IDE also ser?es as a
sin)le* %nifie )raphical %ser interface for a itional Microchip an thir partysoft(are an har (are e?elop'ent tools# Mo?in) &et(een tools is a snap* an
%p)ra in) fro' the free si'%lator to M9LA5 ICD or the M9LA5 ICE e'%lator is
one in a flash &eca%se M9LA5 IDE has the sa'e %ser interface for all tools#
Choose M9LA5 C13* the hi)hly opti'i e co'piler for the 9IC13 series
'icrocontrollers* or try the ne(est MicrochipFs lan)%a)e tools co'piler* M9LA5
C26* tar)ete at the hi)h perfor'ance 9IC 7 an s9IC i)ital si)nal controllers# Or*
%se one of the 'any pro %cts fro' thir party lan)%a)e tools ?en ors# They inte)rate
into M9LA5 IDE to f%nction transparently fro' the M9LA5 project 'ana)er* e itor
an co'piler#
;
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 80/111
10." I) +/%#: $/) / E(<&%%&% C
IBTEC Soft(are 'a,es in %strialBstren)th soft(are e?elop'ent tools
an C co'pilers that help soft(are e?elopers (rite co'pact* efficient e'&e e
processor co e#
4or o?er t(o eca es IBTEC Soft(are has eli?ere the in %stryFs 'ost
relia&le e'&e e soft(are e?elop'ent tools an co'pilers for (ritin) efficient
an co'pact co e to r%n on the 'ost pop%lar e'&e e processors# Use &y tens of
tho%san s of c%sto'ers incl% in) General Motors* hirlpool* b%alco''* Qohn
Deere an 'any others* IBTEC Fs relia&le e?elop'ent tools an C co'pilers*
co'&ine (ith (orl Bclass s%pport ha?e helpe serio%s e'&e e soft(are
pro)ra''ers to create h%n re s of &rea,thro%)h ne( sol%tions#
IBTEC 9ICC is a hi)hBperfor'ance C co'piler for the Microchip 9IC
'icro 16.1 .17.1:.1; series of 'icrocontrollers# IBTEC 9ICC is an in %strialB
stren)th ANSI C co'piler B not a s%&set i'ple'entation li,e so'e other 9IC
co'pilers# The 9ICC co'piler i'ple'ents f%ll ISO.ANSI C* (ith the e0ception of
rec%rsion# All ata types are s%pporte incl% in) 7 an 2 &it IEEE stan ar
floatin) point# IBTEC 9ICC 'a,es f%ll %se of specific 9IC feat%res an %sin) an
intelli)ent opti'i er* can )enerate hi)hB-%ality co e easily ri?alin) han B(ritten
asse'&ler# A%to'atic han lin) of pa)e an &an, selection frees the pro)ra''er
fro' the tri?ial etails of asse'&ler co e#
10. E(<&%%&% C C/(*$ &+
• ANSI C B f%ll feat%re an porta&le
• Relia&le B 'at%re* fiel Bpro?en technolo)y
• M%ltiple C opti'i ation le?els
• An opti'i in) asse'&ler
• 4%ll lin,er* (ith o?erlayin) of local ?aria&les to 'ini'i e RAM %sa)e
• Co'prehensi?e C li&rary (ith all so%rce co e pro?i e
36
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 81/111
• Incl% es s%pport for 7B&it an 2 B&it IEEE floatin) point an 2 B&it lon)
ata types
• Mi0e C an asse'&ler pro)ra''in)
• Unli'ite n%'&er of so%rce files
• Listin)s sho(in) )enerate asse'&ler
• Co'pati&le B inte)rates into the M9LA5 IDE* M9LA5 ICD an 'ost 2r B
party e?elop'ent tools
• R%ns on '%ltiple platfor's/ in o(s* Lin%0* UNI=* Mac OS =* Solaris
10.5 E(<&%%&% D& & /*(&) E) $+/)(&)
This en?iron'ent allo(s yo% to 'ana)e all of yo%r 9IC projects# o% can
co'pile* asse'&le an lin, yo%r e'&e e application (ith a sin)le step#
Optionally* the co'piler 'ay &e r%n irectly fro' the co''an line*
allo(in) yo% to co'pile* asse'&le an lin, %sin) one co''an # This ena&les the
co'piler to &e inte)rate into thir party e?elop'ent en?iron'ents* s%ch as
MicrochipFs M9LA5 IDE#
10.6 E(<&%%&% 4 4 &( T// 4
10.6.1 A44&(< &+B
An asse'&ler is a co'p%ter pro)ra' for translatin) asse'&ly lan)%a)e
essentially* a 'ne'onic representation of 'achine lan)%a)e into o&ject co e # A
cross asse'&ler >see cross co'piler @ pro %ces co e for one type of processor* &%t
r%ns on another# The co'p%tational step (here an asse'&ler is r%n is ,no(n as
asse'&ly ti'e# Translatin) asse'&ly instr%ction 'ne'onics into opco es *
asse'&lers pro?i e the a&ility to %se sy'&olic na'es for 'e'ory locations an
'acro facilities for perfor'in) te0t%al s%&stit%tion typically %se to enco e
co''on short se-%ences of instr%ctions to r%n inline instea of in a s%&ro%tine#
Asse'&lers are far si'pler to (rite than co'pilers for hi)hBle?el lan)%a)es #
31
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 82/111
10.7 P '4&4 / :/(*$ &+
The co'piler has a n%'&er of phases pl%s sy'&ol ta&le 'ana)er an an error
han ler#
Inp%t So%rce
9ro)ra'
Le0ical
Analy er
Synta0
Analy er
Sy'&ol
Ta&le
Mana)er
Se'antic
Analy er
Error
an ler
Inter'e iate
Co e
Generator
Co e
Opti'i er
Co e
Generator
O%t Tar)et
9ro)ra'
10. F'<+$:' $/) %& '$ 4
The fa&rication of one e'onstration %nit is carrie o%t in the follo(in) se-%ence#
3
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 83/111
• 4inali in) the total circ%it ia)ra'* listin) o%t the co'ponents an so%rces of
proc%re'ent#
• 9roc%rin) the co'ponents* testin) the co'ponents an screenin) the
co'ponents#• Ma,in) layo%t* repairin) the interconnection ia)ra' as per the circ%it ia)ra'#
• Asse'&lin) the co'ponents as per the co'ponent layo%t an circ%it ia)ra' an
sol erin) co'ponents#
• Inte)ratin) the total %nit* inter (irin) the %nit an final testin) the %nit#
10. D&4$3) / &(<&%%&% 4 4 &(
Li,e e?ery other syste' e?elop'ent esi)n cycle e'&e e syste' tooha?e a esi)n cycle# The flo( of the syste' (ill &e li,e as )i?en &elo(# 4or any
esi)n cycle these (ill &e the i'ple'entation steps# 4ro' the initial state of the
project to the final fa&rication the esi)n consi erations (ill &e ta,en li,e the
soft(are consi eration an the har (are co'ponents* sensor* inp%t an o%tp%t# The
electronics %s%ally %ses either a 'icroprocessor or a 'icrocontroller# So'e lar)e or
ol syste's %se )eneralBp%rpose 'ainfra'e co'p%ters or 'inico'p%ters#
10.10 U4&+ $) &+ ':&4
User interfaces for e'&e e syste's ?ary (i ely* an th%s eser?e so'e
special co''ent# User interface is the %lti'ate ai' for an e'&e e 'o %le as to
the %ser to chec, the o%tp%t (ith co'plete con?enience# One stan ar interface*
(i ely %se in e'&e e syste's* %ses t(o &%ttons >the a&sol%te 'ini'%'@ to
control a 'en% syste' >j%st to &e clear* one &%tton sho%l &e ne0t 'en% entry the
other &%tton sho%l &e select this 'en% entry @#
Another &asic tric, is to 'ini'i e an si'plify the type of o%tp%t# Desi)ns
so'eti'es %se a stat%s li)ht for each interface pl%)* or fail%re con ition* to tell (hat
faile # A cheap ?ariation is to ha?e t(o li)ht &ars (ith a printe 'atri0 of errors that
they selectB the %ser can )l%e on the la&els for the lan)%a)e that he spea,s# 4or
e0a'ple* 'ost s'all co'p%ter printers %se li)hts la&ele (ith stic,Bon la&els that
32
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 84/111
can &e printe in any lan)%a)e# In so'e 'ar,ets* these are eli?ere (ith se?eral
sets of la&els* so c%sto'ers can pic, the 'ost co'forta&le lan)%a)e#
In 'any or)ani ations* one person appro?es the %ser interface# Often this is
a c%sto'er* the 'ajor istri&%tor or so'eone irectly responsi&le for sellin) thesyste'#
10.11 P ' /+(
There are 'any ifferent C9U architect%res %se in e'&e e esi)ns s%ch
as ARM * MI9S* Col fire .:3, * 9o(er9C * =3: * 9IC * 3681* At'el AHR * 3 * S *
H386 *4RBH*M2 R etc#
This in contrast to the es,top co'p%ter 'ar,et* (hich as of this (ritin) > 662@ is li'ite to j%st a fe( co'petin) architect%res* 'ainly the Intel .AMD 03: *
an the Apple .Motorola .I5M 9o(er9C * %se in the Apple Macintosh # ith the
)ro(in) acceptance of Qa?a in this fiel * there is a ten ency to e?en f%rther eli'inate
the epen ency on specific C9U.har (are >an OS@ re-%ire'ents#
Stan ar 9C.167 is a typical &ase for s'all* lo(B?ol%'e e'&e e an
r%))e i e syste' esi)n# These often %se DOS * Lin%0 or an e'&e e realBti'e
operatin) syste' s%ch as bN= or Inferno #
A co''on confi)%ration for ?eryBhi)hB?ol%'e e'&e e syste's is the
syste' on a chip * an applicationBspecific inte)rate circ%it * for (hich the C9U (as
p%rchase as intellect%al property to a to the ICFs esi)n# A relate co''on
sche'e is to %se a fiel Bpro)ra''a&le )ate array * an pro)ra' it (ith all the lo)ic*
incl% in) the C9U# Most 'o ern 49GAs are esi)ne for this p%rpose#
10.1! T// 4
Li,e typical co'p%ter pro)ra''ers* e'&e e syste' esi)ners %se
co'pilers* asse'&lers * an e&%))ers to e?elop e'&e e syste' soft(are#
o(e?er* they also %se a fe( tools that are %nfa'iliar to 'ost pro)ra''ers#
Soft(are tools can co'e fro' se?eral so%rces/
• Soft(are co'panies that speciali e in the e'&e e 'ar,et#
37
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 85/111
• 9orte fro' the GNU soft(are e?elop'ent tools#
So'eti'es* e?elop'ent tools for a personal co'p%ter can &e %se if the
e'&e e processor is a close relati?e to a co''on 9C processor# E'&e e syste'
esi)ners also %se a fe( soft(are tools rarely %se &y typical co'p%ter
pro)ra''ers#
One co''on tool is an inBcirc%it e'%lator >ICE@ or* in 'ore 'o ern
esi)ns* an e'&e e e&%))er# This e&%))in) tool is the f%n a'ental tric, %se to
e?elop e'&e e co e# It replaces or pl%)s into the 'icroprocessor* an pro?i es
facilities to -%ic,ly loa an e&%) e0peri'ental co e in the syste'# A s'all po
%s%ally pro?i es the special electronics to pl%) into the syste'# Often a personal
co'p%ter (ith special soft(are attaches to the po to pro?i e the e&%))in)
interface#
Another co''on tool is a %tility pro)ra' >often ho'eB)ro(n@ to a a
chec,s%' or CRC to a pro)ra'* so it can chec, its pro)ra' ata &efore e0ec%tin) it#
An e'&e e pro)ra''er that e?elops soft(are for i)ital si)nal
processin) often has a 'ath (or,&ench s%ch as MathCa or Mathe'atica l to
si'%late the 'athe'atics#Less co''on are %tility pro)ra's to t%rn ata files into co e* so one can
incl% e any ,in of ata in a pro)ra'# A fe( projects %se Synchrono%s pro)ra''in)
lan)%a)es for e0tra relia&ility or i)ital si)nal processin) #
10.1" D&<#33$)3
De&%))in) is %s%ally perfor'e (ith an inBcirc%it e'%lator * or so'e type of
e&%))er that can interr%pt the 'icrocontrollerFs internal 'icroco e# The 'icroco e
interr%pt lets the e&%))er operate in har (are in (hich only the C9U (or,s# The
C9UB&ase e&%))er can &e %se to test an e&%) the electronics of the co'p%ter
fro' the ?ie(point of the C9U# This feat%re (as pioneere on the 9D9B11#
As the co'ple0ity of e'&e e syste's )ro(s* hi)her le?el tools an
operatin) syste's are 'i)ratin) into 'achinery (here it 'a,es sense# 4or e0a'ple*
cell phones * personal i)ital assistants an other cons%'er co'p%ters often nee
38
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 86/111
si)nificant soft(are that is p%rchase or pro?i e &y a person other than the
'an%fact%rer of the electronics# In these syste's* an open pro)ra''in) en?iron'ent
s%ch as Lin%0* OSGi or E'&e e Qa?a is re-%ire so that the thir Bparty soft(are
pro?i er can sell to a lar)e 'ar,et#
10.1 S '+ #*
All e'&e e syste's ha?e startB%p co e# Us%ally it isa&les interr%pts* sets
%p the electronics* tests the co'p%ter >RAM* C9U an soft(are@* an then starts the
application co e# Many e'&e e syste's reco?er fro' shortBter' po(er fail%res
&y restartin) >(itho%t recent selfBtests@# Restart ti'es %n er a tenth of a secon are
co''on#
Many esi)ners ha?e fo%n a fe( LEDs %sef%l to in icate errors >they help
tro%&leshootin) @# A co''on sche'e is to ha?e the electronics t%rn on all of the
LED>s@ at reset >there&y pro?in) that po(er is applie an the LEDs the'sel?es
(or,@* (here%pon the soft(are chan)es the LED pattern as the 9o(erBOn Self Test
e0ec%tes# After that* the soft(are 'ay &lin, the LED>s@ or set %p li)ht patterns
%rin) nor'al operation to in icate pro)ra' e0ec%tion pro)ress or errors# This
ser?es to reass%re 'ost technicians.en)ineers an so'e %sers# An interestin)
e0ception is that on electric po(er 'eters an other ite's on the street* &lin,in)
li)hts are ,no(n to attract attention an ?an alis'#
10.15 C/%$)3
10.15.1 T+')4($ &+ C/%$)3B
$): #%& ?*$:. @
$): #%& :% !;16.:9 F#): $/) D& $)$ $/) 9
/$% $)$ Q
ADC H&'+ =&' T&(*&+' #+& Q
/$% %& ' Q
3:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 87/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 88/111
/$% ('$) /$%
$)$ Q
2 $ & 1
ADC H&'+ =&' T&(*&+' #+& Q
:% (/ & 0,0 Q
:% *# 4 H M Q
:% (/ & 0, Q
:% *# 4 =*B Q
:% *# ) *+&4 Q
:% (/ & 1,0 Q
:% *# 4 T&(*B Q
:% *# ) &(* Q
:% *# 4 H= B Q
:% *# ) ' 3 < Q
:% *# 4 Q
$ '31
'31 0Q
$ &(*? 5 >> ' 3 <@ 65 >> ' 3 <? 0 >> *+&4? 1 0
33
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 89/111
:% (/ & 1,0 Q
:% *# 4 H&' $4 N/+(' Q
RC 0QT REG 0;!=Q
2 $ & XTRMT Q
T REG TTENS 0;"0 Q
2 $ & XTRMT Q
T REG TONES 0;"0 Q
2 $ & XTRMT Q
T REG HTENS 0;"0 Q
2 $ & XTRMT Q
T REG HONES 0;"0 Q
2 $ & XTRMT Q
T REG PHUDS 0;"0 Q
2 $ & XTRMT Q
T REG PTENS 0;"0 Q
2 $ & XTRMT Q
T REG PONES 0;"0 Q
2 $ & XTRMT Q
T REG ! 0;"0 Q
2 $ & XTRMT Q
D& ' M4 !50 Q
:% : &'+ Q
$ &(*@ 5 ' 3 <@ 7 *+&4@ 1 0
:% (/ & 1,0 Q
:% *# 4 H&' $4 A<N+( Q
T REG 0;!=Q
3
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 90/111
2 $ & XTRMT Q
T REG TTENS 0;"0 Q
2 $ & XTRMT Q
T REG TONES 0;"0 Q2 $ & XTRMT Q
T REG HTENS 0;"0 Q
2 $ & XTRMT Q
T REG HONES 0;"0 Q
2 $ & XTRMT Q
T REG PHUDS 0;"0 Q
2 $ & XTRMT Q
T REG PTENS 0;"0 Q
2 $ & XTRMT Q
T REG PONES 0;"0 Q
2 $ & XTRMT
T REG " 0;"0 Q
2 $ & XTRMT Q
D& ' M4 !50 Q
:% : &'+ Q
9 I)$ $' $ ' $/) 9
/$% $)$
6
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 91/111
TRISC 0; 0Q
ADCON1 0 !Q
SP=RG !5Q=RGH 1Q
RCSTA 0 0Q
T STA 0 ! Q
TMR1L 0 17Q
TMR1H 0 FCQ
T1CON 0 01Q
GIE PEIE TMR1IE 1Q99RCIE 1Q
:% $)$ Q
D& ' M4 1 Q
9 F#): $/) 9
ADC H&'+ =&' T&(*&+' #+&
9 T&(*&+' #+& 9
ADCON0 0; 1Q 99ADC C 0
D& ' M4 1 Q
ADGO 1Q
2 $ & ADGO Q 994 ' #4 : &:8
(* ADRESH !56 ADRESLQ
&(* (* (*9!Q
THUDS (*9100Q
(* (*Z100Q
TTENS (*910Q
(* (*Z10Q
1
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 92/111
TONES (*Q
D& ' M4 5 Q
9 H&'+ =&' 9
ADCON0 0; Q 99ADC C 1
D& ' M4 1 Q
ADGO 1Q
2 $ & ADGO Q 994 ' #4 : &:8
(* ADRESH !56 ADRESLQ
<&' (*Q
:/#) <&' Q
:/#) Q
$ :/#) @10
:/#) 0Q
' 3 < 0 1 ! " 5 6 7 910Q
$ ' 3 <?"5
' 3 < 0Q
$ ' 3 <@ 100 >> ' 3 <?1!0
' 3 < 0Q
$ ' 3 <@ 100 >> ' 3 <@1"0
' 3 < Q
$ ' 3 <@"5 >> ' 3 <?5
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 93/111
' 3 < 60Q
$ ' 3 <@ 5 >> ' 3 <?61
' 3 < 65Q
99 /; * 70Q
$ ' 3 <@6! >> ' 3 <?7
' 3 < 6 Q
99 /; * 75Q
$ ' 3 <@65 >> ' 3 <? 0
' Q
$ ' 1 ' 3 < 6 Q
$ ' ! ' 3 < 7 Q 99/; * 7 Q
$ ' " ' 3 < 7"Q 99/; * 7!Q
$ ' ' 3 < 6 Q ' 0Q 99/; * 6 Q
(* ' 3 <Q
HHUDS (*9100Q
(* (*Z100Q
HTENS (*910Q
(* (*Z10Q
HONES (*Q
ADCON0 0 1Q
D& ' M4 1 Q
2
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 94/111
ADGO 1Q
2 $ & ADGO Q 994 ' #4 : &:8
*+&4 ADRESH !56 ADRESL 9 Q
D& ' M4 5 Q*+&4 (* *+&4-! Q
PHUDS (*9100Q
(* (*Z100Q
PTENS (*910Q
(* (*Z10Q
PONES (*Q
/$% %& '
/+ 0Q ? 000Q Q
10.15.! R&:&$ &+ C/%$)3B
. <i)5ee ealth Monitorin) .
incl% e ]pic#h^
incl% e lc _1:07#c
__CON4IG>=T DTDIS 9 RTDIS 5ORDIS LH9DIS RTEN
DE5UGDIS DUN9ROT UN9ROTECT@
. 4%nc Definition .
?oi init>@
7
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 95/111
?oi for'at>@
?oi sen topc_?ar1>@
?oi sen topc1>const char ss-1@
?oi elay>@
efine E')_alert_alar' R5;
efine E')_alert_LED R5
efine ON 1
efine O44 6
. Haria&le Declaration .
%nsi)ne char set*
'cnt[6*R=[6*pres*Rec_ctl`16 *h&eat*te'p*fla)1*chec,*&% 1*&% cnt*co%nt*'ill_co%n
t*sec
%nsi)ne int ,
. Interr%pt 4%nction .
%nsi)ne interr%pt isr>?oi @
if>SS9I4@
SS9I4 [ 6
g
if>RCI4@
RCI4[6
R=[RCREG
8
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 96/111
if>R=[[60 5@
set[1
gif>set[[1@
Rec_ctl`'cnt [R=B6026
'cntPP
if>'cnt[[ @
set['cnt[6
fla)1[1
g
g
g
if>TMR1I4@
TMR1I4[6
'ill_co%ntPP
if>'ill_co%nt^ 8@
'ill_co%nt[6
secPP
if>sec^1@
sec[6
if>&% cnt [[ 1@
co%ntPP
if>co%nt^16@
:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 97/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 98/111
if>fla)1[[1@
fla)1[6
'cnt[6for'at>@
if>chec,[[ @
lc _'o?e>1*6@
lc _p%ts> ealth is Nor'al @
..E')_alert_alar'[O44
..
E')_alert_LED[O44
DelayMs> 86@
g
if>chec,[[2@
lc _'o?e>1*6@
lc _p%ts> ealth is A&Nr'l @
&% 1[1
DelayMs> 86@
g
if>&% 1[[1@
E')_alert_alar'[ON
&% cnt[1
sen topc1> AT @
T=REG[12
(hile>kTRMT@
3
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 99/111
elay>@
for>,[6 ,][76666 ,PP@
sen topc1> ATPCMG4[1 @
T=REG[12(hile>kTRMT@
elay>@
for>,[6 ,][76666 ,PP@
sen topc1> AT @
T=REG[12
(hile>kTRMT@
elay>@
for>,[6 ,][76666 ,PP@
sen topc1> ATPCMGS[ @
T=REG[F F
(hile>kTRMT@
sen topc1> 7 7777 @ .. 8 :: 32
sen topc1> ;7; @
T=REG[F F
(hile>kTRMT@
elay>@
T=REG[12 ..4OR LINE 4EED
(hile>kTRMT@
for>,[6 ,][76666 ,PP@
sen topc_?ar1>@
T=REG[12 ..4OR LINE 4EED
(hile>kTRMT@
for>,[6 ,][76666 ,PP@
T=REG[ : ..4OR CTRLP<
(hile>kTRMT@
for>,[6 ,][76666 ,PP@
for>,[6 ,][76666 ,PP@
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 100/111
g
else
&% cnt[6 E')_alert_alar'[O44 g
lc _clear>@g
g
g
. Initiali ation .
?oi init>@
TRIS5 [ 6066
TRISC [ 6036
R5;[6
S95RG[ 8
5RG [1
RCSTA[6= 6
T=STA[6= 7
TMR1L[6=1;
TMR1 [6=4C
T1CON[6=61
GIE[9EIE[SS9IE[RCIE[TMR1IE[1
lc _init>@
DelayMs>1@
g
?oi for'at>@
%nsi)ne char cte'p*cte'p1*cte'p
'cntPP
166
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 101/111
cte'p [ Rec_ctl`'cnt
'cntPP
cte'p1 [ Rec_ctl`'cnt
te'p [>cte'p 16@P cte'p1'cntPP
cte'p [ Rec_ctl`'cnt
'cntPP
cte'p1 [ Rec_ctl`'cnt
h&eat [>cte'p 16@P cte'p1
'cntPP
cte'p [ Rec_ctl`'cnt
'cntPP
cte'p1 [ Rec_ctl`'cnt
'cntPP
cte'p [ Rec_ctl`'cnt
pres [>cte'p 166@P >cte'p1 16@Pcte'p
'cntPP
chec, [ Rec_ctl`'cnt
'cnt[6
g
?oi sen topc_?ar1>@
sen topc1> ealth A&nor'al @
T=REG[12
(hile>kTRMT@
for>,[6 ,][766 ,PP@
sen topc1> Te'p/ @
T=REG[>Rec_ctl`1 P6026@
(hile>kTRMT@
161
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 102/111
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 103/111
(hile> ss-1k[F 6F@
g
?oi elay>@
%nsi)ne int j
for>j[6 j][7666 jPP@
g
10.15 C/): #4$/)
The tool %se is M9LA5 ?;#7 an the co in) is (ritten in E'&e e C an
%'pe into the 9IC 'icrocontroller#
162
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 104/111
CONCLUSION
ith the fast e?elop'ent of the in %striali ation an %r&ani ation process in
the (orl an hence (ith the increase of &%syness of people it has &eco'e iffic%lt
to 'onitor the health con itions of a patient contin%o%sly# Also (ith the increase in
the n%'&er senior citi ens an chronic iseases* the n%'&er of el erly patients (ho
nee constant assistance has increase # One ,ey point of all critical care for el erly
patient is the contin%o%s 'onitorin) of their ?ital si)ns
# To a?oi %ne0pecte health pro&le's an o&tain hi)her acc%racy in ia)nosis
of the health con itions of a patient* efficient an co'prehensi?e ata collectin)*
'onitorin) an control play an i'portant role to i'pro?e the health care syste'
'ore relia&le an effecti?e# A no?el (ireless ata collection for health 'onitorin)
syste' of electric 'achine &ase on (ireless sensor net(or, ><i)5ee.IEEE36 #18#7
Stan ar @ is propose an e?elope in this project# The %ni-%e characteristics of
<i)5ee net(or,s s%ch as lo( po(er* lo( cost* an hi)h fle0i&ility 'a,e the' i eal
for this application# As the foc%s of this* the har (are esi)n an i'ple'entation of
a <i)&ee &ase (ireless sensor net(or, are isc%sse in o%r project#
167
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 105/111
=I=ILOGRAPHY
•
C%sto'i in) an pro)ra''in) %r pic 'icrocontrollerB My,e 9re c,o• Micro controllers an applications BAjay H Deh'%,h
• Electronics 'eas%re'ent an instr%'entation B +alsi
• C pro)ra''in) for e'&e e syste'sB +ir, <%rell
• Teach yo%rself electronics an electricityB Stan Gi&lisco
• E'&e e 9IC 'icrocontrollerB Qohn 9eat'an
• ireless co''%nications Theo ore S# Rappaport
• E'&e e C Michael Q#9ont
• De?elopin) E'&e e Soft(are in C Qanathan# #Hal?ano
• 9IC Microcontroller 9roject 5oo, Qohn Lo?ine
• <i)&ee Net(or,in) B ar?ey Stel'an
168
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 106/111
APPENDI A
$3<&& H&' C'+& F&' #+&4
A3$)3 I)%&*&)%&) B
Ena&les relia&le re'ote patient 'onitorin)Maintains free o' of 'o&ility
Offers safety an acti?ity 'onitorin) sensors for ho'e an professional %se
9ro?i es realBti'e location capa&ilities
C +/)$: D$4&'4& M')'3&(&) BOffers pro'pt fee &ac, for &etter self 'ana)e'ent
Ena&les colla&oration &et(een e?ices for 'ana)in) '%ltiple chronic
iseases
Connects a 'yria of e?ices that 'ay &e re-%ire in professional settin)s
H&' ')% W& )&44BOffers &o yB(orn sensors for sports an fitness
4eat%res precision ti'e sta'ps for synchroni ation an hi)h acc%racy
'onitorin)
Opti'i e application ata rates for all types of fitness e-%ip'ent
Ena&les strea'in)* storeBan Bfor(ar &%rst co''%nication 'o es
C#4 /($ &% S&:#+$ BOffers o%tBofB&o0 sec%rity for easy %se
Confor's (ith re)ional re)%latory en?iron'ents
S%pports access control for cons%'er* ser?ice pro?i er* care pro?i er* or
share net(or,s
4eat%res scala&le s%pport for ata sec%rity an pri?acy
Efficient ,ey )eneration* istri&%tion an 'ana)e'ent for ho'e an
professional settin)s
16:
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 107/111
APPENDI =
MPLA= FEATURES
M9LA5 Inte)rate De?elop'ent En?iron'ent >IDE@ is a free* inte)ratetoolset for the e?elop'ent of e'&e e applications e'ployin) MicrochipFs 9ICm
an s 9ICm 'icrocontrollers#
M9LA5 Inte)rate De?elop'ent En?iron'ent >IDE@ is a free* inte)rate
toolset for the e?elop'ent of e'&e e applications e'ployin) MicrochipFs 9ICm
an s 9ICm 'icrocontrollers#
M9LA5 IDE r%ns as a 2 B&it application on MS in o(sm* is easy to %se
an incl% es a host of free soft(are co'ponents for fast application e?elop'ent
an s%perBchar)e e&%))in)#
M9LA5 IDE also ser?es as a sin)le* %nifie )raphical %ser interface for
a itional Microchip an thir party soft(are an har (are e?elop'ent tools#
Mo?in) &et(een tools is a snap* an %p)ra in) fro' the free soft(are si'%lator to
har (are e&%) an pro)ra''in) tools is one in a flash &eca%se M9LA5 IDE has
the sa'e %ser interface for all tools#
M9LA5 IDE s SIM* hi)h spee soft(are si'%lator for 9IC an s9IC
>Di)ital Si)nal 9rocessin) 9IC Microcontroller@ e?ices (ith peripheral si'%lation*
co'ple0 sti'%l%s injection an re)ister lo))in)
16;
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 108/111
APPENDI C
AT C/((')%4
AT co''an s are instr%ctions %se to control a 'o e'# AT is the a&&re?iation of
ATtention# E?ery co''an line starts (ith AT or at # ThatFs (hy 'o e'
co''an s are calle AT co''an s# Many of the co''an s that are %se to
control (ire ialB%p 'o e's* s%ch as ATD >Dial@* ATA >Ans(er@* AT > oo,
control@ an ATO >Ret%rn to online ata state@* are also s%pporte &y GSM.G9RS
'o e's an 'o&ile phones# 5esi es this co''on AT co''an set* GSM.G9RS
'o e's an 'o&ile phones s%pport an AT co''an set that is specific to the
GSM technolo)y* (hich incl% es SMSBrelate co''an s li,e ATPCMGS >Sen
SMS 'essa)e@* ATPCMSS >Sen SMS 'essa)e fro' stora)e@* ATPCMGL >List
SMS 'essa)es@ an ATPCMGR >Rea SMS 'essa)es@#
Note that the startin) AT is the prefi0 that infor's the 'o e' a&o%t the start of a
co''an line# It is not part of the AT co''an na'e# 4or e0a'ple* D is the
act%al AT co''an na'e in ATD an PCMGS is the act%al AT co''an na'e
in ATPCMGS# o(e?er* so'e &oo,s an (e& sites %se the' interchan)ea&ly as
the na'e of an AT co''an #
ere are so'e of the tas,s that can &e one %sin) AT co''an s (ith a
GSM.G9RS 'o e' or 'o&ile phone/
• Get &asic infor'ation a&o%t the 'o&ile phone or GSM.G9RS 'o e'# 4or
e0a'ple* na'e of 'an%fact%rer >ATPCGMI@* 'o el n%'&er >ATPCGMM@*
IMEI n%'&er >International Mo&ile E-%ip'ent I entity@ >ATPCGSN@ an
soft(are ?ersion >ATPCGMR@#
• Get &asic infor'ation a&o%t the s%&scri&er# 4or e0a'ple* MSISDN
>ATPCNUM@ an IMSI n%'&er >International Mo&ile S%&scri&er I entity@
>ATPCIMI@#
• Get the c%rrent stat%s of the 'o&ile phone or GSM.G9RS 'o e'# 4or
e0a'ple* 'o&ile phone acti?ity stat%s >ATPC9AS@* 'o&ile net(or,
163
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 109/111
re)istration stat%s >ATPCREG@* ra io si)nal stren)th >ATPCSb@* &attery
char)e le?el an &attery char)in) stat%s >ATPC5C@#
• Esta&lish a ata connection or ?oice connection to a re'ote 'o e' >ATD*
ATA* etc@#
• Sen an recei?e fa0 >ATD* ATA* ATP4 @#
• Sen >ATPCMGS* ATPCMSS@* rea >ATPCMGR* ATPCMGL@* (rite
>ATPCMG @ or elete >ATPCMGD@ SMS 'essa)es an o&tain
notifications of ne(ly recei?e SMS 'essa)es >ATPCNMI@#
• Rea >ATPC95R@* (rite >ATPC95 @ or search >ATPC954@ phone&oo,
entries#
• 9erfor' sec%rityBrelate tas,s* s%ch as openin) or closin) facility loc,s
>ATPCLC+@*checking whether a facility is locked (AT !"!#$ and
changing %asswords (AT !&' $.
>4acility loc, e0a'ples/ SIM loc, `a pass(or '%st &e )i?en to the SIM car
e?ery ti'e the 'o&ile phone is s(itche on an 9 BSIM loc, `a certain SIM
car is associate (ith the 'o&ile phone# To %se other SIM car s (ith the
'o&ile phone* a pass(or '%st &e entere # @
• Control the presentation of res%lt co es . error 'essa)es of AT co''an s#
4or e0a'ple* yo% can control (hether to ena&le certain error 'essa)es
>ATPCMEE@ an (hether error 'essa)es sho%l &e isplaye in n%'eric
for'at or ?er&ose for'at >ATPCMEE[1 or ATPCMEE[ @#
• Get or chan)e the confi)%rations of the 'o&ile phone or GSM.G9RS 'o e'#
4or e0a'ple* chan)e the GSM net(or, >ATPCO9S@* &earer ser?ice type>ATPC5ST@* ra io lin, protocol para'eters >ATPCRL9@* SMS center
a ress >ATPCSCA@ an stora)e of SMS 'essa)es >ATPC9MS@#
• Sa?e an restore confi)%rations of the 'o&ile phone or GSM.G9RS 'o e'#
4or e0a'ple* sa?e >ATPCSAS@ an restore >ATPCRES@ settin)s relate to
SMS 'essa)in) s%ch as the SMS center a ress#
16
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 110/111
#
APPENDI D
D$ &+&):&4 <& 2&&) P+/3+'(($)3 C ')% E(<&%%&% C
C is for es,top co'p%ters* e'&e e C %s%ally is for 'icrocontroller &ase
applications# hat 'a,es e'&e e c so ifferent fro' the re)%lar c is/
A&sence of console
Restriction on co e si e
The co'piler
Re)%lar co'pilers create OS epen ent e0ec%ta&le file (here as e'&e e c
co'pilers create a file (hich are o(nloa e to controllers to reali e
the re-%ire tas,#
Re)%lar co'pilers onFt )i?e a&straction for all the reso%rces of the syste'
(here as in e'&e e c co'piler )i?es access to all the reso%rces irectly so
co e efficient#
Co e (ritten in e'&e e c is tho%)h not cross co'pati&le &%t they are
series co'pati&le#
116
8/13/2019 Wireless Health Care Monitoring System
http://slidepdf.com/reader/full/wireless-health-care-monitoring-system 111/111
APPENDI E
T & 8& : '+': &+$4 $:4 / $3<&&, W$-F$ ')% = #& //
$3=&& W$-F$ = #& //R')3& 16B166 'eters 86B166 'eters 16 166 'etersN& 2/+8$)3T/*/ /3
A Bhoc* peer to peer*star* or 'esh
9oint to h%& A Bhoc* ?ery s'allnet(or,s
O*&+' $)3F+& #&):
3:3 M >E%rope@66B 3 M >NA@*#7 G>(orl (i e@
#7 an 8 G #7 G
C/(* &;$ D& $:&')% '** $:' $/)$(*':
Lo( i)h i)h
P/2&+C/)4#(* $/)=' &+ /* $/) ')%$ &
Hery lo( >lo( po(er is a esi)n)oal@
i)h Me i%'
S&:#+$ 1 3 AES pl%sapplication layersec%rity
:7 an 1 3 &itencryption
T *$:'A** $:' $/)4
In %strial controlan 'onitorin)*
ireless LANconnecti?ity*
irelessconnecti?ity &et(een