overflowed
Determine when message queue overflows
Syntax
Description
overflowed(
checks whether a
message is lost because it was sent to a queue that was already full. In each time step, the
value of this operator is set when a chart adds a message to, or removes a message from, a
queue. It is invalid to use the message_name
)overflowed
operator before sending or
retrieving a message in the same time step. To use the overflowed
operator, set the model to an autosar.tlc
target for both simulation and
code generation and verify that the inport or outport message connects to an external queue.
To check the overflow status of an input message queue, first remove a message from the queue.
To check the overflow status of an output message queue, first add a message to the queue.
To check the overflow status of a local message queue, first add a message to the queue or remove a message from the queue.
Examples
Input Arguments
Tips
By default, when a message queue overflows, simulation stops with an error. To prevent a run-time error and allow the
overflowed
operator to dynamically react to dropped messages, set the value of the Queue Overflow Diagnostic property toWarning
orNone
. For more information, see Queue Overflow Diagnostic (Stateflow).
Version History
Introduced in R2018b