Making a Client Request on a Port – Block Diagram
Note |
|---|
This topic applies only to SWCs specified as block diagrams. |
If your software component uses a ClientServer interface as Rport, you must define at least one runnable entity that acts as the client. You have to ensure that the client is triggered by an RTE event.
- Open the SWC you want to edit.
- Place the ClientServer interface prototype (Rport) in the drawing area.
- In the Basic Blocks palette or toolbar, click the
RTE Invoke button to add an RTE Invoke operator. Place the operator in the drawing area.
The operator can be used with or without status information. By default, usage without status information is selected.
- Connect the return value of the desired operation in the Rport to the RTE Invoke operator.
Edit the operator sequence call manually or automatically.
To select explicit access with status information, right-click the RTE Invoke operator and select Status from the context menu.
A status pin is added to the operator.
Specify the status inquiry as follows:
- In the Basic Blocks palette or toolbar, click the
RTE Status button to add an RTE Status element. - Create a literal and set its value to one of the error codes.
- Create a comparison operator.
- Connect the RTE Status element and the literal to the inputs of the comparison operator.
- Connect the output of the comparison operator to a logic variable.
- Right-click the sequence call of the variable and select Connector from the context menu.
- Connect the status pin to the connector.
- In the Basic Blocks palette or toolbar, click the
See also
Editing a Sequence Call in the Sequence Editor
Automatically Assigning Individual Sequence Calls
Specifying a ClientServer Interface Prototype
Enabling Concurrent Invocation of a Server Runnable