2016Cambridge University Press eBooksRequires access

State Machines for Real-Time Embedded Systems

Hassan Gomaa

Open publisher page 1 citations

Abstract

State machines (also referred to as finite state machines ) are used for modeling control and sequencing in a system. This is particularly important for real-time embedded systems, which are usually highly state dependent. In particular, the actions of a state dependent system depend not only on the inputs to the system but also on what happened previously in the system, which is captured as a state. A state machine can be used to depict the states of a system, subsystem, component, or object. Notations used to define state machines are the state transition diagram, state machine diagram, statechart, and state transition table. In highly state dependent systems, these notations help substantially to understand the complexity of these systems. A state machine specification is typically more precise and understandable than a textual or use case description. State machines can enhance or even replace use case descriptions of requirements by providing more precise specifications. In particular, state machines are essential for specifying systems with significant state dependent behavior. In the UML notation, a state transition diagram is referred to as a state machine diagram . The UML state machine diagram notation is based on Harel's statechart notation (Harel and Gery 1996; Harel and Politi 1998). In this book the terms state machine and state machine diagram are used interchangeably. This chapter refers to a traditional state transition diagram, which is not hierarchical, as a flat state machine and uses the term hierarchical state machine to refer to the concept of hierarchical state decomposition, a concept introduced by Harel. A brief overview of the state machine notation is given in Chapter 2 (Section 2.6). This chapter starts by considering the characteristics of flat state machines and then describes hierarchical state machines. To show the benefits of hierarchical state machines, this chapter starts with the simplest form of flat state machine and gradually shows how it can be improved upon to achieve the full modeling power of hierarchical state machines. The process of developing state machines from use cases is then described. Several examples are given throughout the chapter from two case studies, the Microwave Oven and Train Control state machines. Section 7.1 describes events and states in state machines. Section 7.2 introduces the Microwave Oven Control state machine example.

About this research paper

What this paper is about

State machines (also referred to as finite state machines ) are used for modeling control and sequencing in a system. This is particularly important for real-time embedded systems, which are usually highly state dependent. In particular, the actions of a state dependent system depend not only on the inputs to the system but also on what happened previously in the system, which is captured as a state. A state machine can be used to depict the states of a system, subsystem, component, or object. Notations used to define state machines are the state transition diagram, state machine diagram, statechart, and state transition table. In highly state dependent systems, these notations help substantially to understand the complexity of these systems. A state machine specification is typically more precise and understandable than a textual or use case description. State machines can enhance or even replace use case descriptions of requirements by providing more precise specifications. In particular, state machines are essential for specifying systems with significant state dependent behavior. In the UML notation, a state transition diagram is referred to as a state machine diagram . The UML state machine diagram notation is based on Harel's statechart notation (Harel and Gery 1996; Harel and Politi 1998). In this book the terms state machine and state machine diagram are used interchangeably. This chapter refers to a traditional state transition diagram, which is not hierarchical, as a flat state machine and uses the term hierarchical state machine to refer to the concept of hierarchical state decomposition, a concept introduced by Harel. A brief overview of the state machine notation is given in Chapter 2 (Section 2.6). This chapter starts by considering the characteristics of flat state machines and then describes hierarchical state machines. To show the benefits of hierarchical state machines, this chapter starts with the simplest form of flat state machine and gradually shows how it can be improved upon to achieve the full modeling power of hierarchical state machines. The process of developing state machines from use cases is then described. Several examples are given throughout the chapter from two case studies, the Microwave Oven and Train Control state machines. Section 7.1 describes events and states in state machines. Section 7.2 introduces the Microwave Oven Control state machine example.

Why it matters

OpenAlex reports 1 citations for this work. Citation counts describe recorded attention and do not establish research quality.

Key contribution

A contribution statement is not available in the OpenAlex record.

Method / approach

Method details are not available in the OpenAlex metadata.

Main findings

Findings are not separately available in the OpenAlex metadata.

Limitations

Limitations are not available in the OpenAlex metadata.

Applications

Application details are not available in the OpenAlex metadata.

Available abstract

State machines (also referred to as finite state machines ) are used for modeling control and sequencing in a system. This is particularly important for real-time embedded systems, which are usually highly state dependent. In particular, the actions of a state dependent system depend not only on the inputs to the system but also on what happened previously in the system, which is captured as a state. A state machine can be used to depict the states of a system, subsystem, component, or object. Notations used to define state machines are the state transition diagram, state machine diagram, statechart, and state transition table. In highly state dependent systems, these notations help substantially to understand the complexity of these systems. A state machine specification is typically more precise and understandable than a textual or use case description. State machines can enhance or even replace use case descriptions of requirements by providing more precise specifications. In particular, state machines are essential for specifying systems with significant state dependent behavior. In the UML notation, a state transition diagram is referred to as a state machine diagram . The UML state machine diagram notation is based on Harel's statechart notation (Harel and Gery 1996; Harel and Politi 1998). In this book the terms state machine and state machine diagram are used interchangeably. This chapter refers to a traditional state transition diagram, which is not hierarchical, as a flat state machine and uses the term hierarchical state machine to refer to the concept of hierarchical state decomposition, a concept introduced by Harel. A brief overview of the state machine notation is given in Chapter 2 (Section 2.6). This chapter starts by considering the characteristics of flat state machines and then describes hierarchical state machines. To show the benefits of hierarchical state machines, this chapter starts with the simplest form of flat state machine and gradually shows how it can be improved upon to achieve the full modeling power of hierarchical state machines. The process of developing state machines from use cases is then described. Several examples are given throughout the chapter from two case studies, the Microwave Oven and Train Control state machines. Section 7.1 describes events and states in state machines. Section 7.2 introduces the Microwave Oven Control state machine example.

Key concepts: State diagram, State (computer science), Finite-state machine, Extended finite-state machine, Computer science, Notation, Component (thermodynamics), Abstract state machines

Related papers

Back to paper searchBrowse research topicsOriginal source
State Machines for Real-Time Embedded Systems — Research Paper | ScholarLens