Module 10- State Machine Part 2 Flashcards

1
Q

difference between events and behaviors
- an event occurs at a discrete moment in time ** has no duration**
- a behavior has duration

relationship between them
- when an event occurs it may trigger the event of a behavior then that executes over a period of time
and while a behavior executes it may ______________

A

generate new event occurrences that might kick off more behaviors

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Four kinds of events

  1. signal event
  2. call event
  3. change event … keyword “when”
  4. time _____
A

time event

and how they can be used as triggers in transitions ??
at - absolute time event
after - discrete time event after 2mins

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

review from activity diagram .. accept event action . This waits for an event to occur in the event pool. Then it consumes the event and moves on to the next step.

an accept event action could have any event as a trigger

signal , call , _________or time event

A

change

signal event- reception - signal
call change event- operation - parameter list

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

big idea .. the signal event … call event .. change event … or time events can be used as a _____ on transitions in a state machine

A

trigger

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

a signal event trigger corresponds to a ____

A

reception

the reception is owned by the block that owns that state machine behavior

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

signal event trigger matches the reception owned by the block that _________

A

owns that state machine behavior

problem is the STM doesn’t show the owning block you would have to dig into the model . Solution - go into the block that owns that state machine behavior.. double check if that block owns that reception .. which receptions owns signals

thats the only way to know which block owns that signal event

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

what would you wait for to know that a signal event has been triggered ?

an arrival of the ____________

A

signal .

signal event triggers must correspond to the signal owned by the block

note a signal can own properties / attributes. the matching reception would have parameters.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

what does a classifier behavior mean = owned behavior of that element
the classifier behavior is assigned by the user to begin ___________

A

automatically

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

remember that only receptions can own signals

A

there must be «signal»

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

change event triggers begin with when and boolean expression in

A

parenthesis

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

a call event trigger corresponds to an OPERATION owned by the blocked that owns the ________ behavior
signal event trigger corresponds to a RECEPTION owned by the blocked that owns the ________ behavior

A

state machine

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Operation and receptions are _________features that that block can perform when called to do so

A

behavioral

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

This example shows a call event on a trigger which can only represent a

A

operation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

two kinds of time event
1. relative time event - begins with After 2 mins
2. absolute time event - begins with

A

at 12:00pm PST

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

how do relative and absolute time events work in a state machine ?

when would this transition fire ?
1. if the state machine is in the state Hav Comm link
the log system status

A

if the state machine is at rest and is in another state the time event runs at the specific time but that event gets consumed and nothing gets triggered .

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

how can you tell if the trigger is a change event trigger ? it begins with the keyword

A

WHEN

and

17
Q

when does a change event occur and enter the owning blocks event pool ?

A
18
Q

when does a change event occur and enter the owning blocks event pool ?

A

a change event occurs and enters the event pool at the moment when the boolean expression toggles from false to true

19
Q

evaluate the run to completion step once the temp is at 90 degrees

A
20
Q

the transition would not fire when the state machine starts and temp >90

A

the change event occurs and enters the event pool at the moment when the boolean expression toggles from false to true

so this scenario the change event will not fire at the online state

21
Q

Most common kinds of Pseudo states are
1. initial
2.

what do they have in common ?
1. they define control logic.
2. state machine can never be at rest in a pseudo state . it can only be at rest in a state.

A

junction / compound

22
Q

state machine behavior must have exactly one initial pseudo state per _______ with an outgoing transition that points to the starting state in that ______

A

region.

23
Q

the transition out of a pseudo state cannot have a
- trigger
- guard
but it can have a transition effect ____

A

behavior

24
Q

only a transition out of a _____ can have a trigger event specified
but all of the transitions in/out a junction psuedo state can have
1. guard expression
2. transition effect behavior specified.

A

state

25
Q

for a junction psuedo state all of the guards in the compound transition get evaluated up front at the moment when the trigger event is ______and removed from the event pool

guards are not evaluated in sequence ( common misconception)

A

consumed

26
Q

1 each region must have an initial pseudo state pointing to a starting state

state machine rules

#2 when a state machine is executing , it has EXACTLY one active state at all times .. there cant be two states running at the same time. never in zero or multiple states
#3 each region in a state machine executes concurrently and ______ of each other
#4

A

independently

27
Q

when this STM is executing how many active total states are there ?

A

2