1 / 6

State-Transition Diagrams

State-Transition Diagrams. Represent a process specification Have 4 components States Transitions Conditions Actions Must have one initial state May have multiple final states. Answering Machine Example. Idle. Waiting for call. Recording Message. Rewinding. Playing Messages.

Download Presentation

State-Transition Diagrams

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. State-Transition Diagrams • Represent a process specification • Have 4 components • States • Transitions • Conditions • Actions • Must have one initial state • May have multiple final states

  2. Answering Machine Example Idle Waiting for call Recording Message Rewinding Playing Messages Answering Call

  3. Conditions and Actions • A condition is an event in the external environment which triggers a transition to a new state • An action is a response sent back to the external environment or a calculation whose result is stored by the system that occurs when the transition takes place

  4. Example of conditions/actions Idle Condition Condition Press Cancel button Press Answer button Ready to receive light goes on Ready to receive button goes out Waiting for Call Action Action Condition End of Call or tape runs out Incoming call detected Condition Answering Call

  5. Levelling State-Transition Diagrams State 2 Can be partitioned to State 2.3 State 2.1 State 2.2 State 2.4

  6. Guidelines for State-Transition Diagrams • Have all states been defined? • Can you reach all the states? • Can you exit from all the states? • In each state does the system respond to all possible conditions?

More Related