Vous êtes sur la page 1sur 17

UNIT1 FUNDAMENTALSOFEMBEDDED SYSTEMS

Structure
1.0Introduction 1.1Objectives 1.2EmbeddedSystem:AnIntroduction
1.2.1 ComponentsofanEmbeddedSystem 1.2.2 BlockDiagramandCharacteristicsofanEmbeddedSystem 1.2.3 ClassificationofanEmbeddedSystem

Fundamentalsof EmbeddedSystems

PageNos.
5 5 6

1.3 1.4 1.5 1.6 1.7 1.8 1.9

1.3.2 CharacteristicsofanEmbeddedOperatingSystem

EmbeddedOperatingSystem 1.3.1 ClassificationofanEmbeddedOperatingSystem

8 10 12 14 19 19 19

RequirementsandSpecificationinEmbeddedSystem ProgrammingLanguagesforEmbeddedSystemandClassification
1.5.1 HardwareLanguages 1.5.2 VHDLV/sVerilog

SelectedEmbeddedSystemapplications
1.6.1 WashingMachine 1.62. DigitalSoundRecorder

Summary Answers/Solutions FurtherReadingsandReferences

1.0

INTRODUCTION

Embeddedsystemsarebasicelectronicdevicesusedtocontrol,monitororassistthe operationofequipment,machineryoraplant.Thechoiceofwordembedded reflectsthefactthattheseareintegralpartofthesystem.Usesofembeddedsystemin ourreallifeareincreasingdaybyday.Childrenneedsuchsystemstoplayvideo gamesandtooperatechocolatevendingmachine,Housewivesneedembedded systemsformicrowave,TV,musicsystem,andothersystemappliances. Inthisunityouwilllearnaboutbasicsofembeddedsystem:itsuses,itscomponents, itsbasicrequirementsintermsofHardwareandSoftwareandsupportof ProgrammingLanguages.Wewillalsohighlightsomeapplicationofembedded systeminourreallifescenarioattheendofthisunit.

1.1

OBJECTIVES

Aftergoingthroughthisunit,youwillbeableto:

defineembeddedoperatingsystem; identifyBasicRequirementsanditsSpecification; explainDesignmethodology; describetheuseofprogramminglanguagesinembeddedsystem;and 5

StateoftheArtPracticesin InformationTechnology

listtheuseofapplicationsofEmbeddedSystem.

1.2

EMBEDDEDSYSTEM:ANINTRODUCTION

Anembeddeddevicecanrangefromarelativelysimpleproductforex.atoasterto complexmissioncriticalapplicationssuchasthoseusedinavionics.Atypical embeddeddevicewillhavebothhardwareandsoftwarecomponents.Thehardware couldbemicrocomponentssuchasembeddedmicroprocessorormicrocontroller. Microcontrollerisrelativelysmall,hasaonchipmemory,anI/Ocontrollerandother supportedmodulestodoprocessingandcontrollingtasks.Thesoftwareconsistsof applicationsthatperformdedicatedtasksandmayrunonRealtimeoperatingsystem whichwillbeexplainedlaterinthisunit. EmbeddedSystemmaybeeitheranindependentsystemorapartofalargesystem.It isspecializedcomputersystembutnotageneralpurposeworkstationlikeadesktopor acomputer.Suchkindofsystemsishousedonasinglemicroprocessorboardwith programswhicharestoredinROM(ReadOnlyMemory).Embeddedsystemis usuallyacompact,portableandmassproducedelectronicdevices.Intheearlydays, embeddedsystemsweredesignedusingmicroprocessorslike8085.Butnowadays,we areusingawiderangeofprocessorsfromothermanufacturers. Beforewewanttothebasicofanembeddedsystem,weshouldseeawiderangeofits applications.Infact,almostallmodernelectronicdevicesusesomesortofembedded systemtechnologyinsidethemandwealwayscomeacrosssuchdevices:DVD players,airconditioners,printers,attendancemachines,handphone,digitalcamera, ATMmachines,wewillseesomeexamplesofembeddedsysteminsection1.Nowit istimetogiveaproperdefinition. Definitions:EmbeddedSystemsaredeviceswhichareusedtocontrol,monitoror assisttheoperationofanequipment,machineryorplant.Thetermcontrol definesthemainfunctionofEmbeddedSystembecausetheirpurposeistocontrolan aspectofaphysicalsystemsuchaspressure,temperatureandsoon.Alsotheterm monitordefinestheprogressofactivities. WheredoweuseEmbeddedSystems?Fromseveralexampleslistedearlierthese systemsareextremelycommoninthehome,vehicleandtheworkplace.

AtHome:WashingMachines,dishwashers,ovens,centralheatingsystem, burglarsalarms,etc. InMotorVehicle:Enginemanagement,security(lockingorantitheft devices),airconditioning,brakes,radioetc. InIndustry&Commerce:Machinecontrol,factoryautomation,robotics, electroniccommerceofficeequipments.

1.2.1

ComponentsofanEmbeddedSystem

Anembeddedsystemhasthreemaincomponents:Hardware,Softwareandtime operatingsystem i) 6 Hardware

PowerSupply Processor Memory Timers Serialcommunicationports Output/Outputcircuits Systemapplicationspecificcircuits ii) Software:Theapplicationsoftwareisrequiredtoperformtheseriesoftasks. Anembeddedsystemhassoftwaredesignedtokeepinviewofthreeconstraints: AvailabilityofSystemMemory Availabilityofprocessorspeed Theneedtolimitpowerdissipationwhenrunningthesystemcontinuouslyin cyclesofwaitforevents,run,stopandwakeup.

Fundamentalsof EmbeddedSystems

iii)RealTimeOperatingSystem:(RTOS)Itsupervisestheapplicationsoftware andprovidesamechanismtolettheprocessorrunaprocessasperschedulingand dotheswitchingfromoneprocess(task)toanotherprocess.

1.2.2

BlockDiagramandCharacteristicsofanEmbeddedSystem

Embeddedsystemsareexecutedbyamicrocontroller,whichcommunicateswiththe sensorsandactuators.Itmeansthatauserofanembeddedsystemisnotableto changethefunctionalityofthesystemthroughmodifyingorreplacingthesoftware becauseitiskeptinROM.


EmbeddedSystem

Microcontroller

Sensors Input

Actuator s Output

Figure1:EmbeddedSystem

Figure1showsbasiccomponentsusedinEmbeddedSystemareasfollows:

Microcontroller:Itmonitorsandcontrolstheenvironment.

Sensors:Itcollectsdatafromenvironmentthroughinputdevices. Actuators:Itdisplaysthesystem'sstatusthroughoutputdevices. Timer:Itprovidesresponsewithinacertaintimeframe. CharacteristicsofEmbeddedSystem 7

StateoftheArtPracticesin InformationTechnology

SomeofimportantCharacteristicsofembeddedsystemare: 1) EmbeddedSystemsaredesignedtodosomespecifictaski.e.,itisnotageneral purposekindofasystem. 2) SoftwareforEmbeddedSystemsarestoredinROMorflashmemory. 3) Knowledgeaboutbehavioratdesigntimecanbeusedtominimizeresourcesand tomaximizerobustness. 4) EmbeddedSystemsprovidelowpowerconsumptioninmanysituations.

1.2.3ClassificationofanEmbeddedSystem
Embeddedsystemcanbeclassifiedas:

StandaloneEmbeddedSystem:Itisbuiltusingaspecializedcommunication processor,memoryanumberofnetworkaccessinterfaces(knownasnetwork ports),andspecialsoftwarethatimplementslogicforsendinginformationfrom onedevicetoanotherdevice.

RealTimeEmbeddedSystem:Arealtimeembeddedsystemusuallymonitors theenvironmentwheretheembeddedsystemisinstalled.Thiskindofsystemis requiredtorespondintimetoarequest.Examplesofrealtimeembeddedsystems areaircraftenginecontrolsystems,nuclearmonitoringsystemsandmedical monitoringequipment.

NetworkAppliances:Networkappliancesareanewclassofembedded systemsthatinadditiontotraditionalrealtimeprocessingmustsupportabroad andchangingarrayofnetworkprotocols.

MobileEmbeddedSystem:MobileEmbeddedSystemsusuallyaresimple, batterypoweredsystemswithresourcelimitations.Insomesituations,their batterieslifetimebecomesaprimissue.

1.3

EMBEDDEDOPERATINGSYSTEM

Anembeddedoperatingsystem(EOS)isasystemsoftwarethatmanagesalltheother programsanddevicesinanembeddedsystem.Itnormallyguaranteesacertain capabilitywithinaspecifiedstoragesizeandtimeconstraintaswellaswith applicationprograms.Itsstructureisverysimilartoastructureofanormaloperating systemhowevermainlydifferentiatedbysomefactorssuchastypeofpreinstalled device,functionallimits,takingdesignedjobonly.Italsonormallyhasbootloader, OSkernel,requireddevicedrivers,filesystemsfortheuserdataandsoforth. Attheircore,embeddedoperatingsystemscontainsomeofthesamesoftware componentsusedonlargeroperatingsystems,suchaswindowsandLinuxetc.larger operatingsystems(OS),embeddedoperatingsystemsdealswithtaskswitching, schedulingoftasks,memoryallocation,etc. ButtherearesomedistinctionsbetweendesktopcomputerOSandembeddedsystem OS.DesktopComputerisageneralpurposecomputingsystemwhereasembedded systempurposeisforaspecifictask.Embeddedoperatingsystemshaveseveral commoncharacteristicsthatdistinguishsuchsystemsfromothercomputingsystems: 8

Fundamentalsof EmbeddedSystems

SingleFunctioned:Usuallyexecutesaspecificprogramrepeatedlye.g.pager.

TightlyConstrained:Allcomputingsystemshaveconstraintsondesign metrics,butthoseonembeddedsystemscanbeespeciallytight.Adesignmetric isameasureofanimplementationsfeatures,suchascost,size,performanceand power.

ReactiveandRealTime:Manyembeddedsystemsmustcontinuallyreactto changesinthesystemsenvironmentandmustcomputecertainresultsinrealtime withoutdelay.Incontrast,adesktopsystemtypicallyfocusesoncomputation withrelativelyinfrequentreactionstoinputdevices.

SecondaryMemory:Generallyembeddedsystemdoesntneedsecondary memory. Unlikeadesktopcomputersystemwhichmayhavenewsoftwareloadedonto itfrequently,embeddedsystemsretainthesamecodeforalongtime,sometimes indefinitely.Embeddedoperatingsystemsdonotusuallyincludesupportfor externalstorageorgraphicalinterfaces,orprotectionfrommaliciousorunstable code.Thelimitedmemoryinembeddedsystemsrequirestheoperatingsystem andprocesstoworkverycloselytomanagethefreeresources.

1.3.1

ClassificationofanEmbeddedOperatingSystem(EOS)

WecanclassifyOperatingSystems(forembeddedsystems)intotwopartscalledas RealTimeOperatingSystemsandNonRealTimeOSasshowninFigure2.

EmbeddedOS

RealTimeOperatingSystem(RTOS) E.g.VxWorks,OS9,RTLinux

NonRealTimeOperatingSystem E.g.Windows,PalmOS

Figure2:Classificationofembeddedoperatingsystem

RealTimeOperatingSystemsareoperatingsystemswhichguarantee responsestoeacheventwithinadefinedamountoftime.Thistypeofoperating systemismainlyusedbytimecriticalapplicationssuchasmeasurementand controlsystems.SomecommonlyusedRTOSforembeddedsystemsare: VxWorks,OS9,Symbian,andRTLinuxetc.

NonRealTimeOperatingSystemsdonotguaranteedefined responsetimes.Thosesystemsaremostlyusedifmultipleapplicationsare needed.WindowsandPalmOSareexamplesforsuchembeddedoperating systems. SomeotherfeatureswhicharequitecommontoEOSirrespectiveofany classificationarepresentedbelow.

1)

SingleSystemControlLoop:Suchsystemsrunasingletask. 9

StateoftheArtPracticesin InformationTechnology

2) MultitaskingOperatingSystem:Inamultitaskingoperatingsystem,several
tasksorprocessesappeartoexecuteconcurrently

3) PreemptiveOperatingSystem:Apreemptiveoperatingsystemisa

multitaskingoperatingsystemthatdefinespreemptiveprioritiesfortasks.A higherprioritytaskalwaysinterruptsandisalwaysrunbeforealowerpriority task.

4) RateMonotonicOperatingSystem:Suchoperatingsystemguaranteesthat
tasksinthesystemcanrunatacertainintervaloftimeforacertainperiodof time.Whenthisguaranteeisnotmet,thesystemsoftwarecanbenotifiedof failureandtakeappropriateaction.

5) ConstantTimeOperations:Constanttimeoperationsarethecornerstoneof
realtimeresponsivenessandpredictablecapacityloading.

6) InterruptResponseTimes:EmbeddedOperatingSystemsnormallyprovide

forfastinterruptresponsetimesbyseparatinginterrupthandlersintwophases.In thefirstphase,theinterrupthandlerprogramreactstoaninterruptandsatisfies theinterruptconditionfromahardwareperspective.Inthesecondphase,the interrupthandlerprocessestheinterruptcondition.Whileexecutinginthesecond phase,otherinterruptsinthesystemareenabledandmaybehandledtoallow higherpriorityinterruptstotakeprecedenceoverlowerpriorityinterrupts.

7) PriorityInversion:Priorityinversionisaconditioninpreemptiveoperating
systemswherealowerprioritytaskclaimsaresourcethatissubsequently requiredbyahigherprioritytask.

8) MonolithicOperatingSystems:Amonolithicoperatingsystemincludesall

operatingsystemcodesuchasdevicedriversandfilesystemhandlersaspartofa singlesystemimage.

9) MicroKernels:Amicrokerneloperatingsystemincludesonlythebare

necessitiessuchastaskswitching,schedulinganddevicehandlinginterfacesin theoperatingsystemcode.

1.3.2

CharacteristicsofanEmbeddedOperatingSystem

ForanEmbeddedOStoberegardedasgood,itshouldhavethefollowingfeatures: Modularity:Modularityisaconceptthathasanapplicationinthe contextsofcomputerscience,particularlyprogramminglanguage.Amodulecan bedefinedvariously,butgenerallymustbeacomponentofalargersystem,and operatewithinthatsystemindependentlyfromtheoperationsofthecomponents ofthesystem.

Scalability:Thepropertyofamultiprocessingcomputerthatdefinesthe extenttowhichadditionofmoreprocessorsincreasesaggregatecomputing capability.WindowsNTserver4.0isgenerallyconsideredtobescalabletoeight Intelprocessors.


CPU. 10

ACPUsupport:ThereisnomeaningofanOSwithoutacompatible

FlexibilityandConfigurability:Byflexibilitywemeantosaythatthe EmbeddedOSmustbeadjustabletochange/modification.Aconfigurationisan arrangementoffunctionalunitsaccordingtotheirnature,number,andchief characteristics.Often,configurationpertainstothechoiceofhardware,software, firmware,anddocumentation.Theconfigurationaffectsthesystemfunction. Haveasmallfootprint:Incomputerscience,thefootprintofapieceof softwareistheportionofcomputingresources,typicallyRAM,CPUtime peripheraldevices. HavealargeDeviceDriverDatabase:ThelargertheDeviceDriver DatabaseofanEmbeddedOS,thegreateristhenumberofdevicesthatcanbe controlledthroughthatparticularOS.

Fundamentalsof EmbeddedSystems

1.4

REQUIREMENTSANDSPECIFICATIONOF ANEMBEDDEDSYSTEM

Arequirementisaconditionneededbyausertosolveaproblemorachievean objective.Specificationisadocumentthatspecifies,inacomplete,precise,verifiable manner,therequirements,design,behavior,orothercharacteristicsofasystem,and often,theproceduresfordeterminingwhethertheseprovisionshavebeensatisfied. Forexample,arequirementforacarcouldbethatthemaximumspeedtobeatleast 120mph.Thespecificationforthisrequirementwouldincludetechnicalinformation aboutspecificdesignaspects. Requirementsandspecificationsareveryimportantcomponentsinthedevelopment ofanyembeddedsystem.Requirementsanalysisisthefirststepinthesystemdesign process,whereauser'srequirementsshouldbeclarifiedanddocumentedtogenerate thecorrespondingspecifications.Forexample,errorsdevelopedduringthe requirementsandspecificationsstagemayleadtoerrorsinthedesignstage.When thiserrorisdiscovered,theengineersmustrevisittherequirementsandspecifications tofixtheproblem.Thisleadsnotonlytomoretimewastedbutalsothepossibilityof otherrequirementsandspecificationserrors.Manyaccidentsaretracedto requirementsflaws,incompleteimplementationofspecifications,orwrong assumptionsabouttherequirements. Establishinggoodrequirementsrequirespeoplewithbothtechnicaland communicationskills.Technicalskillsarerequiredastheembeddedsystemwillbe highlycomplexandmayrequireknowledgefromdifferentengineeringdisciplines suchaselectricalengineeringandmechanicalengineering.Communicationskillsare necessaryasthereisalotofexchangeofinformationbetweenthecustomerandthe designer.Withouteitherofthesetwoskills,therequirementswillbeunclearor inaccurate. ExampleofaSystemRequirementofanEmbeddedSystem: EmbeddedSystemrequiresminimalhardwarerequirementsasfollows: MinimumRequirements Operating System MicrosoftWindowsNTWorkstationoperatingsystemversion4.0 withServicePack5(SP5)orlater 11

StateoftheArtPracticesin InformationTechnology

Browser Processor Memory Drive

MicrosoftInternetExplorer4.0ServicePack1(SP1)orlater ComputerwithPentiumclassprocessor;Pentium300megahertz (MHz)orhigherprocessorrecommended 64MBofRAM 100MBforgeneratedimagestorage 20MBforinstallationoftheWindowsNTEmbedded4.0 developmentsystem170MBiftheBinaryRepositoryiscopiedtothe localdevelopmentsystemharddrive(optional) MicrosoftVisualStudio6.0developmentsystemtocreateTarget Designerextensions

Optional

SpecificationandDesign Aspecificationenableseveryoneinvolvedintheprocesstocomprehendtheentire designandhis/herpieceofit.Thespecificationmustincludethefollowing:


Anexternalblockdiagramshowinghowthedevicefitsintothesystem. Aninternalblockdiagramshowingeachmajorfunctionalsection. AdescriptionoftheI/Opins. Physicalspecificationpackagetype,physicalsize,connectorrequirements, andsoon.

Powerconsumptiontarget Pricetarget Testprocedures ThedesignstepofDesignMethodologydependsonthekindofdevicetargeted. Digitalhardwarediffersfromanaloghardware. DesignMethodologydoesn'tlimitordictatedesignpractices,butit'simportantthat youusereliable,accepteddesignpracticesduringthisstep. However,systemintegrationandsystemtestingisnecessarytoensurethatallpartsof thesystemworkcorrectlytogether.Atthesystemintegrationandteststepofthe design,youhavetheresponsibilitytodeterminethattheentiresystem,includingthe deviceyou'vedesigned,workscorrectly.Youshouldperformaburnintesttoassure thatanymanufacturingdefectsarediscoveredbeforetheproductisdelivered.If you'vefollowedtheprocedureuptothispoint,chancesaregoodthatyoursystemwill performcorrectly.Minorhardwareproblemscanoftenbeworkedaroundbyslight modificationstothesystemorchangestothesystemsoftware.

1.5

PROGRAMMINGLANGUAGESFOR EMBEDDEDSYSTEMANDCLASSIFICATION

Embeddedsystemsareapplicationspecificcomputersthatinteractwiththephysical world.Eachhasadiversesetoftaskstoperform,andalthoughaveryflexible 12

languagemightbeabletohandleallofthem,insteadavarietyofproblemdomain specificlanguageshaveevolvedthatareeasiertowrite,analyze,andcompile.The choiceofprogramminglanguageisveryimportantforrealtimeembeddedsoftware. Thefollowingfactorsinfluencethechoiceoflanguages: AlanguagecompilershouldbeavailableforthechosenRTOS (RealTimeOperatingSystem)andhardwarearchitectureoftheembedded system. CompilersshouldbeavailableonmultipleOSsand microprocessors.ThisisparticularlyimportantiftheprocessorortheRTOS needstobechangedinfuture. Thelanguageshouldallowdirecthardwarecontrolwithout sacrificingtheadvantagesofahighlevellanguage. Thelanguageshouldprovidememorymanagementcontrolsuchas dynamicandstaticmemoryallocation. So,wecancategorizeembeddedprogramminglanguagesintotwopartssuchas hardwarelanguageandsoftwarelanguage.

Fundamentalsof EmbeddedSystems

1.5.1

HardwareLanguages

Ahardwaredescriptionlanguagecanbeusedtodescribethelogicgates,the sequentialmachines,andthefunctionalmodules,alongwiththeirinterconnectionand theircontrol,inaembeddedsystem.Therearevariouslanguagesusedforthispurpose asfollows: VHDL VHDListheVeryHighSpeedIntegratedCircuitHardwareDescriptionLanguage.It candescribethebehaviourandstructureofelectronicsystems,butisparticularly suitedasalanguagetodescribethestructureandbehaviourofdigitalelectronic hardwaredesigns,VHDLisaninternationalstandard,regulatedbytheinternational languages.VHDLissuitableforusetodayinthedigitalhardwaredesignprocess, fromspecificationthroughhighlevelfunctionalsimulation,manualdesignandlogic synthesisdowntogatelevelsimulation. VERILOG VerilogHDLisoneofthetwomostcommonHardwareDescriptionLanguages (HDL)usedbyintegratedcircuit(IC)designers.TheotheroneisVHDL.HDL allowsthedesigntobesimulatedearlierinthedesigncycleinordertocorrecterrors orexperimentwithdifferentarchitectures.DesignsdescribedinHDLaretechnology independent,easytodesignanddebug,andareusuallymorereadablethan schematics,particularlyforlargecircuits. Verilogcanbeusedtodescribedesignsatfourlevelsofabstraction: i) Algorithmiclevel(muchlike,Clanguagecodewithif,caseandloopstatements). ii) Registertransferlevel(RTLusesregistersconnectedbyBooleanequations). 13

StateoftheArtPracticesin InformationTechnology

iii) Gatelevel(interconnectedAND,NORetc.). iv) Switchlevel(theswitchesareMOStransistorsinsidegates). Thelanguagealsodefinesconstructsthatcanbeusedtocontroltheinputandoutput ofsimulation.

1.5.2 VHDLVS.VERILOG
Letuscomparebetweenthetwolanguagesonthefollowingparameters: 1)Capability Hardwarestructurecanbemodeledequallyeffectivelyinboth VHDLandVerilog.Whenmodelingabstracthardware,thecapabilityof VHDLcanbeachievedinVerilog. 2) Compilation

VHDL:Multipledesignunits(entity/architecturepairs),that resideinthesamesystemfile,maybeseparatelycompiledifsodesired. However,itisgooddesignpracticetokeepeachdesignunitinit'sown systemfileinwhichcaseseparatecompilationshouldnotbeanissue.

Verilog:TheVeriloglanguageisstillrootedinit'snative interpretativemode.Compilationisameansofspeedingupsimulation,but hasnotchangedtheoriginalnatureofthelanguage.Asaresultcaremustbe takenwithboththecompilationorderofcodewritteninasinglefileandthe compilationorderofmultiplefiles.Simulationresultscanchangebysimply changingtheorderofcompilation. 3) Datatypes

VHDL:Amultitudeoflanguageoruserdefineddatatypescan beused.Thismaymeandedicatedconversionfunctionsareneededtoconvert objectsfromonetypetoanother.

Verilog.ComparedtoVHDL,Verilogdatatypesarevery simple,easytouseandverymuchgearedtowardsmodelinghardware structure 4) Designreusability

VHDL.Proceduresandfunctionsmaybeplacedinapackageso thattheyareavailabletoanydesignunitthatwishestousethem.

Verilog.ThereisnoconceptofpackagesinVerilog. 5) EasiesttoLearn
Verilogisprobablytheeasiesttograspandunderstandas comparedtoVHDL. 14

6) Operators

Fundamentalsof EmbeddedSystems

VeriloghasaveryusefulunaryoperatorsthatarenotinVHDL. VHDLhasthemodoperatorthatisnotfoundinVerilog.

JavaandC++areanotherprogramminglanguageswhichareusedextensivelyfor embeddedsystemdesign.

1.6

SELECTEDEMBEDDEDSYSTEM APPLICATIONS

WecancategorizeapplicationsofEmbeddedSystemintovariouscategoriesas mentionedinTable: Area Aerospace Automotive Communications ComputerPeripherals Home Industrial Instrumentation Medical OfficeAutomation Applications NavigationSystems,Automaticlandingsystems,Flight altitudecontrols,enginecontrols,spaceexploration FuelInjectionControl,Passengerenvironmental controls,antilockbrakingsystems,airbagcontrols, GPSmapping Switches,Hubs Printers,scanners,keyboards,displays,modems,Hard DiskDrives,CDROMdrives Ovens,WashingMachine,DigtalWatch,Security Alarm,SoundRecorder ElevatorControls,Robots,EngineControl DataCollection,powersupplies ImagingSystems,Patientmonitors,Heartpacers FAXmachines,Telephones,CashRegisters

Now,wewilldiscussheretwowellknownapplicationsusedforhomeappliancesin detailasfollows:

1.6.1

WashingMachine

Washingmachinesupportsthreefunctionalmodes: i)FullyAutomaticMode:Infullyautomaticmode,oncethesystemisstartedit performindependentlywithoutuserinterferenceandafterthecompletionofworkit shouldnotifytheuseraboutthecompletionofwork.Thismodeinstantaneouslysense clothqualityandrequirementofwater,watertemperature,detergent,load,washcycle timeandperformoperationaccordingly. ii)SemiAutomaticMode:Inthissemiautomaticmodeinwhichwashingconditions arepredefined.Oncethepredefinedmodeisstartedthesystemperformitsjoband aftercompletionitinformtheuseraboutthecompletionofwork. iii)ManualMode:Inthismode,userhastospecifywhichoperationhewantstodo andhastoproviderelatedinformationtothecontrolsystem.Forexample,ifuser wantstowashclothesonly,hehastochoosewashoptionmanually.Thenthesystem asktheusertoenterthewashtime,amountofwaterandtheload.Afterthesedataare 15

StateoftheArtPracticesin InformationTechnology

entered,theusershouldstartthemachine.Whenthespecifiedoperationiscompleted systemshouldinformtheuser. RememberthatModesshouldbeaselectablebyakeypad. AwashingmachinemayhaveaSystemController(BrainoftheSystem)which providesthepowercontrolforvariousmonitorsandpumpsandevencontrolsthe displaythattellsushowthewashcyclesareproceeding.Awashingmachine compriseseveralcomponentsasshowninFigure3.

Displaypanel System Controller

Sensor DrivingMotor WaterPump

InverterUnit

Figure3:BlockDiagramofWashingMachine

Theworkingofthesecomponentsisasfollows: i) DisplayPanel:Itisatouchpanelscreentocontrolalltheoperationsofamachine

ii) Sensor:Itmeasuresthewaterlevelandappropriateamountofsoap.Inputdevices forautomaticwashingmachinearesensorsforwaterflow,waterleveland temperature;doorswitch;selectorknoborbuttonsforsettingssuchasspinspeed, temperature,loadsizeandtypesofwashcyclerequired. WaterLevelSensor:Itindicatesbeepsoundwhenwaterlevelislowinwashingtub. DoorSensor:Itindicatesbeepsoundwhenallclothesarewashedthatmeansnow youcanopenthemachingdoorandalsoyoucanmovetoyournextphase.Nextphase willbedryPhase.Thisphasealsofollowssameconceptfordryingtheclothes. iii) DrivingMotor:Motorcanrotateintwodirectionseitherreverseorforward. Theforwarddirectiondrivesthecurrentinforwarddirectionandmotorrotates forward.Thereversedirectiondriverdoestheoppositeofit.Awashingmachine canmaintainsinglemotorinfullyautomaticordoublemotorinsemiautomatic washingmachine. Sequenceofwashingtheclotheswiththiscanbeexplainedinfewstepsasfollows: 1)Putonyourdirtyclothesontothewashtubforwashing 2)PutthedetergentSoap(ofyourchoicelikeSurfnExceletc.) 16

3)PutONthetap,waterrushesinsidethetub. 4)Ifitselectroniccontrol,thenbythepressofthekeys,youcouldprogram,ifits mechanicalitshallsomethinglikeanmechanicalswitcheswhereinyouare allowedtooperateforsettingthewashtime. 5)Nowthewashmotorrotatesandwashestheclothesandgivesyouabeepsound 6) Nowyourclothesarewashedremoveitfromthewashtubandputitonthe spintubandprogramitaccordinglyafterspinningclothesaredriedandyou areallowedtohangitforproperdryinginsunlight. Thefullyautomaticalsocomesintwocategoryfrontloadingaswellastoploading. i)Frontloadingistheonewhereinyouaregivenanopeningtoputclothesinonthe frontside. ii)Toploadingisonthetop. iv)SystemController:SuchComponentisusedtocontrolthemotorspeed.Motor canmoveinforwarddirectionaswellasreversedirection. SystemControllerreadsthespeedofmotorandcontrolsthespeedofmotorin differentphasessuchasinWashing,CleaningDryingetc.AllkindsofSensors suchasDoorSensor,PressureSensorandKeypad,Speedsensorarealso maintainedbythis. v) WaterPump:Thewaterpumpisusedtorecirculatewateranddrainoutthe dirtywater.Thispumpactuallycontainstwoseparatepumpsinsideone:The bottomhalfofthepumpishookeduptothedrainline,whilethetophalf recirculatesthewashwater.Themotorthatdrivesthepumpcanreversedirection. Itspinsonewaywhenthewasherisrunningawashcycleandrecirculatesthe water;anditspinstheotherwaywhenthewasherisdoingaspincycleand drainingthewater

Fundamentalsof EmbeddedSystems

1.6.2

DigitalSoundRecorder

Adigitalsoundrecorderisaconsumerelectronicappliancedesignedtorecordand playbackspeech.Themessagesarerecordedusingabuiltinmicrophoneandtheyare storedinadigitalmemory.Theusercanquicklyplaybackanymessageatany momentthroughaspeakerplacedinthefrontofthedevice.

Figure4showswhatoursoundrecordercouldlooklike.Itisahandheldunitwithflat displayandfairlylargebuttons. 17

StateoftheArtPracticesin InformationTechnology

Screen

Yes

No

Figure4:BlockDiagramofDigitalSoundRecorder

Themainfeaturesofthedigitalsoundrecorderare: Easytousewithonscreenmenus. Directaccesstoanymessage.

Alarmclockwithyear2000readycalendar.Theusercansetadailyalarm. Thealarmbeepsuntiltheuserpressesakey,orafter60seconds. FullFunctionLCDDisplay.Thecurrentdateandtimeisalwaysshowninthe display.Thedisplayalsoshowscleardirectionsabouthowtouseitandwhatitis doing. Batterylevelindicator.Thesystembeepswhenthebatteryislow. Standbymode.Iteconomizesthebatterypower.Thesystemswitchesoffthe peripheralswhentheyarenotinuse.Thenormaloperationisresumedwhen theuserpressesakey. Suchasystemprovidesgoodsoundquality.Andalsosoundisprocessedat6KHz usingeightbitspersample. InDigitalSoundRecordersystemtherearesixdifferentFunctions:

FunctionsofDigitalSoundRecorderSystem

Delete Recording

SetAlarm

SetClock

WatchTime

Playback

18

1)Recordamessage Whenwewanttorecordamessagethenwewillusefollowingsteps: Step1:Selectsamessageslotfromthemessagedirectory Step2:pressetherecordbutton. Ifthemessageslotalreadystoresamessage,itisdeleted. Thesystemstartsrecordingthesoundfromthemicrophoneuntiltheuserpressesthe stopbutton,orthememoryisfull. 2)Playbackamessage WhenwewanttoplaybackamessageThenwewillusefollowingsteps: Step1:Selectsarecordedmessageslot Step2:andthenpressestheplaybutton. Ifthemessageslotcontainsarecordedmessagethenitisplayedthroughthespeaker untilitsendoruntiltheuserpressesthestopbutton. 3)Deleteamessage WhenwewanttodeleteamessageThenwewillusefollowingsteps: Step1:Theuserselectsausedmessageslot Step2:andthenpressesthedeletebutton. Themessageispermanentlydeletedfromthememoryanditsmemoryspaceisfreed up. 4)Setthealarmtime WhenwewanttoSetthealarmstate,Thentheusercanswitchonandoffthealarm andsetthetimewhenthealarmwillsound. Thisisdonebyselectingthedifferentoptionsofthealarmmenu. 5)Settheclocktime WhenwewanttosettheclocktimemessageThenusercansettheclocktimeand adjustittothecurrenttimezone. 6)Watchthetime Thesystemconstantlyshowsthecurrenttimeanddateonthedisplay.Theuserjust looksatit.

Fundamentalsof EmbeddedSystems

FCheckYourProgress1
1) DistinguishbetweenEmbeddedSystemsandNonEmbeddedSystems. 2) Explainthecharacteristicsofrealtimeoperatingsystemforembeddedsystem applications.

19

StateoftheArtPracticesin InformationTechnology

3) WhatareadvantagesofVerilogHDL?

1.7

SUMMARY

Embeddedsystemisakindofcomputersystemorcomputingdevicethatperformsa dedicatedfunctionand/orisintendedforusewithaspecificembeddedsoftware application.Ithasbeenfoundthatsuchsystemsarenotusableasacommercially viablesubstituteforgeneralpurposecomputers.Inthesameway,wecandefine embeddedoperatingsystemasthesoftwareprogramthatmanagesalltheother programsinanembeddeddeviceafterinitialloadofprograms. ImportantconceptslikerequirementandspecificationsplayavitalroleinEmbedded Systemdesignimplementation.SuchSystemsuseprogramminglanguagesinwhich hardwarelanguagessuchasVerilogandVHDLareusedfortheirhardwaresupport andalsowellknownsoftwarelanguageslikeC,C++andJavaetc.Wehavealso discussedvariousapplicationsofEmbeddedSysteminsection.

1.8

ANSWERS/SOLUTIONS

1) Anembeddedsystemisasinglepurposecomputerbuiltintoalargersystemfor thepurposesofcontrollingandmonitoringthesystem.Thesearealsoknownas specialpurposecomputersystem.Example:DigitalwatchesandMP4Players, DigitalSoundRecorder. NonEmbeddedSystemsarealsoknownasgeneralComputergeneralpurpose computer(e.g.apersonalcomputer)isdefinednottobeanembeddedsystem. Suchsystemcandomanytasksdependingonprogramming.Example:Handheld devices.sharesomeelementswithembeddedsystemssuchastheoperating systemsandmicroprocessorswhichpowerthembutarenottrulyembedded systems,becausetheyallowdifferentapplicationstobeloadedandperipheralsto beconnected. 2)RTOSCharacteristicsforEmbeddedSystemsApplications:

Theyhavelimitedmemorythatismodularkernels.Modularkernelsmeans onlyincludetheneededservices. Theexecutedprocessesareusuallyknownatsystemdesign.RTOSoften linkedwiththeexecutedapplication(s)totheinstructionmemory.

3) TheadvantagesusingVerilogHDLare: I)Easytowrite II)EasytounderstandasitsimilartoCprogram III)EasiertolearncomparedwithVHDL.

1.9
20

FURTHERREADINGS

1)

2)

RajKamal,EmbeddedSystems,TataMcgrawHill. SteveHealth,EmbeddedSystemsDesign,EDN2ndEd. ReferenceWebsites:

Fundamentalsof EmbeddedSystems

i) http://en.wikipedia.org/wiki/Embedded_system ii) http://en.wikipedia.org/wiki/Embedded_operating_system iii) http://wapedia.mobi/en/Embedded_system iv) http://www.learnc.com

21

Vous aimerez peut-être aussi