116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

download 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

of 10

Transcript of 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    1/10

    REAL TIME SYSTEMS

    UNIT 1: INTRODUCTION TO REAL-TIME SYSTEMS:Historical background,

    RTS Definition, Classification of Real-time Systems, Time constraints, Classification ofPrograms. 6 Hours

    Historical backrou!"

    Brown and Cambell ! "#$% ! &arliest roosal - Comuter oerating in real time

    'as a art of t(e control system)

    Consists of feedback and feed-forward loos

    *ssumtion was t(at, t(e analog comuters can be used

    Digital comuter elements did not were e+cluded

    irst digital comuter ! deeloed for real time control ! for airborne oeration

    Digitrac digital comuter ! "#$ ! used to roide an automatic flig(t and

    weaons control system

    /ndustrial control ! in digital comuters usage ! late "#$%s

    Comuter and electronic system manufacturers ! for e+tending markets ! been

    out from military uses of ! initiated t(e comuter control industries

    "#$0, Setember ! 1ouisiana Power and 1ig(t Comany - Daystrom comuter

    system2s installation ! for lant monitoring ! in t(eir ower station ! at Sterling,

    1ouisiana

    /t was not t(e control system

    irst industrial comuter installation -

    Te+aco Comany !Ramo-3ooldridge Comany - R3-4%% system2s installation -

    at Port *rt(ur refinery in Te+as

    "#$#, 5arc( "$t(! Refinery were using ! closed loo control system

    '*non, "#$#)

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    2/10

    "#$6-$0 - 5onsanto C(emical Comany ! wit( t(e cooeration of Ramo-

    3ooldridge Comany ! studied t(e control by comuter

    "#$0, 7ctober ! it lanned to (ae comuter control for ammonia lant ! at

    1uling, 1ouisiana

    "#8%, 9uly :%t(! Commissioning of comuter control for ammonia lant at

    1uling, 1ouisiana ! began

    "#8%, *ril t(! Closed loo control was ac(ieed ! after rewriting ! t(e control

    of t(e rogram - ;oise roblems ! were faced ! on t(e measurement of signals

    "#$#-8%, B. . ation calculations ! for determining t(e set-oints ! for standard analog

    controllers ! Here, comuter ! not controlling directly ! moement of t(e ales

    or ot(er lant actuators

    "#$# ! Plan to (ad t(e following installation were begun 'Burkitt,"#8$)

    "#8:, ;oember ! erranti *rgus :%% systems - irst DDC 'Direct Digital

    Control) system ! installed ! at /C/ ammonia-soda lant at leetwood,

    1ancas(ire, ?=

    /t was t(e large system ! ":% control loos '# of were used actually) ! :$8

    measurements ':: of were used actually) ! in leetwood system

    "#8" ! 5onsanto Comany ! Te+as city lant ! and, a (ierarc(ical control

    sc(eme for etroc(emical comanies, at C(ocolate Bayou ! DDC ro@ects !

    began

    R3-4%% comuter ! used t(e rotating drum store ! to (old t(e control rogram

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    3/10

    erranti *rgus :%% ! ?sed t(e ferrite core store ! to (old t(e control rogram -

    PR75 ! rogram was (eld in it

    1oaded by ! (ysically inserting egs into a lug board ! eac( eg reresenting !

    one bit in t(e memory word

    3as laborious to set u initially

    3as ery reliable !since, destruction of t(e memory contents - can be done only

    by (ysical dislodgement of t(e egs

    Security was en(anced ! using secial ower sulies ! and, switc(-oer

    mec(anisms ! to rotect information (eld in t(e main core store

    T(e information ! was as follows !

    ". Set oints ! 1oss most undesirable

    :. Aale demand ! Presence after controlled stoage allows comuter to gain

    control of lant immediately and wit(out disturbing t(e lant 'referred to as

    bumless transfer)

    4. 5emory calculations ! 1oss is tolerable, soon will be udated and only slig(t

    disturbance to lant

    . uture deeloment ! &+tension to allow for otimi>ation may reuire

    information to be maintained for long eriods of time$. 5ore raid memory access ! were in erranti *rgus :%% ! t(at of R3-4%% and

    similar mac(ines

    Began t(e second (ase of alication of comuters ! to real time control

    "#8%s, &arly ! Comuters ware using ! combined magnetic core memories and

    drum stores ! drum eentually giing way to (ard disk dries

    E#$:for early "#8%s comuters !

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    4/10

    erranti *rgus series

    &lliot *utomation #%% series

    Cost of earlier comuter increased ! in attemts to resole some roblems ! and

    only one comuter ! for suerising control and DDC ! can be @ustified only ! it

    was wit( furt(er roblems in deeloment of softwares

    Softwares ! written by secialists rogrammers ! in mac(ine code ! it was

    manageable earlier ! since, tasks were defined clearly and t(e rograms2 lengt(

    were less

    Combining of DDC and suerisory control ! increased !

    ". t(e code lengt(, for a gien alication

    :. t(e comle+ity of t(e rogramming

    DDC and suerisory control ! were wit( ery different time-scales

    DDC control rograms ! (ae to interrut t(e suerisory control rograms2

    increase in code lengt( ! made all t(e code could be stored in core memory and

    also swaing of code between t(e drum memory and core ! to be to done were

    also - Solutions to increased code lengt( roblems aboe ! were by -

    Deeloment of general urose real-time oerating systems and (ig(-leel

    languages

    1ate "#8%s ! RT7S were deeloed ! PR7C&SS 7RTR*; comilers (ad t(eir

    aearance

    Problems and costs of inoling in (aing one comuter only for use ! made t(e

    users to retreat ! t(e smaller systems ! for w(ic( newly deeloing

    microcomuters 'like D&C PDP-0, PDP-"", Data

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    5/10

    5icrocomuters less cost ! made t(em suitable ! to load t(e large number of

    tasks onto one mac(ine, 'by using more t(an one microcomuter, instead a single

    comuter)

    "#6% ! two comuters on t(e systems were using ! in w(ic( one comuter acting

    simly stand-by ! to function in t(e eent of failure of t(e working comuter

    T(roug(out "#6% ! Deeloments in /Cs and construction tec(niues in circuit

    boards ! led to - increment in reliability of t(e systems ! reduction in t(e cost !

    increment in t(e rocessor ower ! increase in t(e fast memory amount ! made

    more correct and deendable softwares to be to write

    "#6 ! microrocessors2 adent ! made it economical to use distributed comuter

    control system

    RTS D%&i!itio!

    RTS "%&i!itio! 'i! as T(% O#&or" "ictio!ar) o& Co*+uti!,:

    *ny system in w(ic( t(e time at w(ic( t(e outut is roduced is significant. T(is

    is usually because t(e inut corresonds to some moement in t(e (ysical world,

    and t(e outut (as to relate to t(at same moement. T(e lag from inut time to outut

    time must be sufficiently small for accetable timelines

    RTS "%&i!itio! 'Cooli! 1..1,:

    Real-time systems are t(ose w(ic( must roduce correct resonses wit(in adefinite time limit. S(ould comuter resonses e+ceed t(ese time bounds t(en

    erformance degradation andor malfunction results

    RTS "%&i!itio! 'alt%r!at% "%&i!itio!,:

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    6/10

    * real-time system reads inuts from t(e lant and sends control signals to t(e

    lant at times determined by lant oerational considerations ! not at times limited by

    t(e caabilities of t(e comuter system

    RTS "%&i!itio!:

    * rogram for w(ic( t(e correctness of oerations deends bot( on t(e logical

    results of t(e comutations and t(e time at w(ic( t(e results are roduced

    E#$:*ircraft engine control system ! sending resonse to ?;/ workstations

    Classi&icatio! o& R%al-ti*% S)st%*s

    Comuter is connected to t(e enironment wit(in w(ic( it is working by a wide

    range of interface deices and receies an sends a ariety of stimuli ! in t(e real time

    systems and embedded comuters

    &+.E Plant inut, lant outut, and communication tasks s(own in ig.

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    7/10

    T(ey (ae one common feature ! t(at t(ey are connected by (ysical deices to

    rocesses w(ic( are e+ternal to t(e comuter. T(ese e+ternal rocesses all oerate in t(eir

    own time scales and t(e comuter is said to oerated / real time if actions carried out in

    t(e comuter relate to t(e time scales of t(e e+ternal rocesses

    Sync(roni>ation between t(e e+ternal rocesses and t(e internal actions 'tasks) !

    carried by t(e comuterE

    ". Clock basedE Sync(roni>ation between t(e aboe two - if in deends on assages of

    time, actual time of day 'clock based RTS)

    :. &ent basedE Sync(roni>ation between t(e aboe two ! if in deends eents

    E#$:Closure of a switc(

    4. /nteractie SystemsE Relation between t(e actions in t(e comuter and t(e system ! is

    muc( more loosely defined

    Reuirement, tyically ! in t(e form t(at ! a set of oerations in t(e comuter s(ould be

    comleted wit(in a redetermined time

    5a@ority of t(e communication tasks ! are of t(is category

    Co!trol tasks: &en t(oug( ! not obiously and directly connected to t(e e+ternal

    enironment ! t(ey need to oerated in real time ! since, time is usually inoled in

    determining t(e arameters of t(e algorit(ms used. /t is useful to diide tasks to be

    carried out by embedded comuters into t(e interactie categories and c(aracteristics of

    eac( class are to be recogni>ed

    T)+%s o& tasks i! r%al ti*% s)st%*s:T(e t(ree tyes of tasks are

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    8/10

    ". Clock-based 'Cyclic, Periodic)

    :. &ent-based '*eriodic)

    4. /nteractie systems

    1$ Clock-bas%" Tasks 'C)clic/ 0%rio"ic,

    Process of t(e lant - oerate in real time

    Plant time constantE it2s t(e measure of t(e time taken by a lant to resond to a c(ange in

    inut or load and is used as a c(aracteristic of t(e lant

    5ay be measured ! in (ours for some c(emical rocesses or

    /n ms for an aircraft system

    eedback controlE /t inoles t(e feedback control

    /t reuires t(e samling rate to be deendent on t(e time constant of t(e rocess to be

    controlled

    Samling rate increases ! as t(e time constant alue decreases

    Sync(roni>ation in real time ! between t(e two is ! reuired

    *ll t(e reuired oerations 'like measurement, control and actuation ! wit(in eac(

    samling interal) ! can be able to carry out

    Comletion of t(e oeration ! wit(in t(e secified timeE Deendent on

    ". ;umber of oerations to be erformed

    :. Seed of t(e comuter

    R%al-ti*% clock:/t2s t(e clock ! added to t(e comuter - to (ae t(e sync(roni>ation. /t2s

    signal ! is used to interrut t(e oerations of t(e comuter ! at some redetermined fi+ed

    time interal

    Comuters carry out ! lant inut, lant outut and control tasks in resonse to t(e clock

    interrut. /f t(e clock interrut is at a faster rate t(an t(e samling rate ! count of eac(

    interrut to be to ! until it2s t(e time to run t(e tasks.

    Different samling ratesE used in larger lants ! w(ere tasks are subdiided into grous !

    for controlling different arts of t(e lant

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    9/10

    Clock interrut ! used freuently ! to kee a clock and a calendar ! and kee t(e

    comuter ! aware of bot( t(e time and t(e date

    Clock based tasks 'cyclic or eriodic tasks) ! (ere, task is run once er time eriod T

    'cycle time, T) !or run at e+actly T unit interals

    2. E%!t-bas%" Tasks 'A+%rio"ic,

    Systems in w(ic( actions are erformed in resonse to some eents and not

    erformed at resonse at articular times or time interals

    E#$:

    ". Turing off a um - Closing a ale w(en t(e leel of a liuid tank reac(es

    redetermined alue ! like t(e one in - leel of fuel in t(e e(icle fuel tank ! reac(ing

    t(e um no>>le

    :. Switc(ing a motor off ! in resonse to t(e closure of a micro-switc(

    indicating - t(at some desired osition (ad reac(ed

    ?sed e+tensiely ! to indicate ! alarm conditions and initiate alarm actions

    &+.E /ndication of too (ig( a temerature or too great a ressure

    /ncludes t(e reuirement! t(at t(e system must resond ! wit(in a gien ma+imum time

    to a articular eent

    ?ses t(e interruts ! to inform t(e comuter system ! t(at action is reuired. Smaller

    systems ! use olling - w(ere t(e comuter eriodically asks 'olls) arious sensors ! to

    see if action is reuired

    *eriodic tasksE &ents usually occur at non-deterministic interals

    *eriodic tasks ! may (ae deadlines ! e+ressed in terms of (aing start times or finis(

    times or een bot(.

    &+.E Task may be reuired to start ! wit(in %.$s of an eent occurring

    Task may (ae to roduce an outut ! wit(in %.$s of an eent

    2$ I!t%racti% s)st%*s

    Probably reresent ! t(e largest class of real time systems

    E#$: ". *utomatic bank tellers

  • 8/11/2019 116314900 Real Time Systems 7th Sem ECE VTU Unit 1 Introduction to Real Time Systems Ramisuniverse

    10/10

    :. Reseration systems for (otels, airlines and car rental comanies

    4. Comuteri>ed tills

    Reuirement of interactie systemsE can be e+ressed in terms suc( as Ft(e aerage

    resonse tome must not e+ceedG2

    &+.E *utomatic bank teller system mig(t ! reuire an aerage resonse time ! not

    e+ceeding :%s

    E%!t-bas%" s)st%*s 3s I!t%racti% s)st%*s

    T(e two are

    1. Sa*%:since, it aarently resonse to a signal from t(e lant 'in t(is case usually

    a erson)

    2. Di&&%r%!t:Since, it resonds a a time determined by t(e internal state of t(e

    comuter and wit(out any reference to t(e enironment

    &+.E *utomatic bank teller - does not know t(at ! you will miss a train, or t(at it2s

    raining (ard and you are getting wet, but it2s resonse ! deends on (ow busy t(e

    communication lines and central comuters are and also your amount

    Clock-bas%" s)st%*s 3s I!t%racti% s)st%*sT(e two are

    1. Sa*%:since, are caable of dislaying t(e date and time, and also t(ey (ae a real

    time clock ! w(ic( enables t(em to kee track of time

    2. Di&&%r%!t:w(en t(e test is done w(et(er or not t(e answer for t(e uestion ! FCan

    t(e system be tig(tly sync(roni>ed to an e+ternal rocess2

    /f answer is Fyes2 ! t(ey are clock-based

    /f answer is Fno2 ! t(ey are eent-based