Download presentation
Presentation is loading. Please wait.
1
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Assignment 1 Reactive Systems
2
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Reactive Systems Traffic Lights Scoreboard Home Management System
3
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Traffic Light Controller (TLC): Brief Description This is a system that handles traffic. It makes sure that cars only enter the intersection in an orderly manner. This is a safety precaustion which is designed to avoid accidents, and direct traffic.
4
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 TLC: Subject Domain Physical Entities Vehicles Lights Timer Conceptual Entities Traffic rules e.g. color rules Lexical Entities
5
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 TLC: Connection Domain Lights Sensors
6
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 TLC: Cause and Effect Chain (1) Condition Traffic light is red Event Car rolls over sensor Stimuli The system registers the event Response The controller sends a green signal to the light. Action The light changes to green
7
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 TLC: Cause and Effect Chain(2) Event Timer signals light change Stimuli The system registers the signal Response System sends signal to light Action Light change
8
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 TLC: Cause and Effect Chain(3) Event The sensor malfunctions Stimuli The systems registers the error Response The system disregards the sensor Action Only the timer is used for traffic control
9
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 TLC: Requirements The system must accept sensor and timer signals The system must be programmable of authorized personnel The system must only allow green light one way at the time
10
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 TLC: Constraints The system can not detect the speed of approaching vehicles
11
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Scoreboard: Brief Description A scoreboard is a large board for publicly displaying the score in a game or match. In many sports a scoreboard is used for keeping score, measuring time, and displaying statistics.
12
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Scoreboard: Subject Domain Physical Entities People Conceptual Entities Score Time Type of sport Lexical Entities None
13
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Scoreboard: Connection Domain Control box
14
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Scoreboard: Cause and Effect Chain (1) Event Goal scored by Nicklas Bendtner Effects that may happen anyway Bendtner does a silly dance and the crowd goes wild Stimuli A person presses the score increment button on the control box Response The scoreboard controller sends a signal to the board Action The score is updated on the scoreboard
15
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Scoreboard: Cause and Effect Chain (2) Event 2 min suspension of Anja Andersen Effects that may happen anyway The team walks out Stimuli A person registers a 2 min suspension Response The scoreboard controller sends a signal to the scoreboard Action A 2 min countdown is shown on the scoreboard
16
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Scoreboard: Cause and Effect Chain (3) Event 2 min suspension is up Stimuli Timer sends a signal to indicate end of suspension Response Countdown is turned off on the scoreboard Action A player is allowed to enter the court
17
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Scoreboard: Requirements A timer function Handle different time intervals Handle >= 3 digit scores Handle several suspensions …
18
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Scoreboard: Constraints Correct operation from an operator Cannot detect events
19
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 HMS: Brief Description The Home Management System (HMS) is a system to control the electrical appliances of your home via the Internet. E.g. you can turn your appliances on/off and organize your appliances in groups.
20
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 HMS: Subject Domain Physical Entities Electrical appliances Sensors, e.g. thermometer Conceptual Entities Temperature Power consumption Lexical Entities
21
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 HMS: Connection Domain AMR (Automatic Meter Reader) Switch
22
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 HMS: Cause and Effect Chain (1) Condition Temperature falls below 20°C in the living room Stimuli A thermometer sends a signal of the temperature to the system Response The system sends a message to a radiator in the room to turn on Action The radiator starts heating
23
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 HMS: Cause and Effect Chain (2) Event The father of the house wishes to find out last months power consumption Stimuli A request to see last months power consumption is received from a browser Response The system outputs the numbers to the browser Action The father prints the numbers
24
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 HMS: Cause and Effect Chain (3) Event New units a set up in the house Stimuli The new unit sends a message of its arrival to the system Response The system registers the unit in the system and adds it as an unregistered unit Action The father of the house renames the unit and adds it to the livingroom
25
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 HMS: Requirements The system must handle many appliances and sensors The system must support grouping of units The system must be able to receive input via the Internet ...
26
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 HMS: Constraints The system doesn’t know the exact location of the units The system relies on the sensors to work properly The system cannot detect potentially dangerous situations Can only handle units with a zigbee attached
27
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Exercise 2 - 1 We choose the Scoreboard system. The system displays the following characteristics of a reactive system (cf. [Wieringa, Fig. 1.1]): Highly interactive: Yes, it is possible to input information to the scoreboard controller using the control box and see the result on the board. Nonterminating process: Yes, the scoreboard is running all the time when turned on. Interrupt-driven: Yes, e.g. the game time can be stopped at all times State-dependent response: Yes, e.g. the system has different game modes for point management depending on the state
28
Morten Bohøj, Jakob Dam og Brian Jensen Gruppe 2 A A R H U S U N I V E R S I T E T SoITS d. 5 september 2006 Exercise 2 - 2 Environment-oriented response : Yes, e.g. the controller of the scoreboard sounds a buzzer indicating to the environment that the game is over. Parallel processes: Yes, timers do not depend on each other and can be executed in parallel, e.g. game time and timers for suspension Stringent real-time requirements: Yes, e.g. the scoreboard is expected to show immediately when a suspension runs out.
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.