Link Signal Builder Blocks to Requirements and Simulink Model Objects
This example shows how to create links from a signal group in a Signal Builder block to a requirements document and to a model object.
Note
When you create links as described in this example, requirements link to individual signal groups, not with the entire Signal Builder block.
In this example, switch to a different active group in the drop-down list to link a requirement to another signal group.
Link Signal Editor Blocks to Requirements Documents
This example shows how to create links from a signal group in a Signal Editor block to a requirements document.
Open the sf_car
model.
open_system("sf_car")
Set the Document File Reference Settings
In the Apps tab, open Requirements Manager.
In the Requirements tab, ensure Layout > Requirements Browser is selected.
In the Requirements Browser, in the View drop-down menu, select
Links
.In the Requirements tab, select Link Settings > Default Link Storage.
Next to Document file reference, select the option from the list that suits your needs for your external requirements document. For more information, see Document Path Storage.
Create Links from the Signal Editor Block
In the sf_car
model window, double-click the User Inputs
block.The Signal Editor dialog box opens, displaying four groups of signals. The Passing Maneuver signal group is the current active group. The requirements link to the current active signal group.
At the far-right end of the toolbar, click the Show verification settings button . Ensure that the Requirements display button
is selected. The Requirements pane opens on the right-hand side of the Signal Editor dialog box.
Create the link to this signal group by using the Outgoing Links dialog.
In the Signal Editor window, in the Requirements pane, right-click and select Open Outgoing Links dialog.The Outgoing Links dialog opens.
Click New. In the Description field, enter
User input requirements
.Click Browse and select your external requirements document, then click Open.
In the Location drop-down list, select Search text to link to specified text in the document.
Next to the Location drop-down list, enter
User Input Requirements
to create a link to that specified text in the requirements document.Click Apply to create the link.
To verify that the link was created, in the
sf_car
model, select the User Inputs block, right-click, and select Requirements.The link to the new requirement is the option at the top of the submenu.
Clear the open requirement sets and link sets and close the model.
slreq.clear;
bdclose all;
Link Signal Builder Blocks to Model Objects
This example shows how to create links from a signal group in a Signal Builder block to a model object:
Open the
sf_car
model.openExample("slrequirements/LinkSignalBuilderBlocksExample") open_system("sf_car")
Open the
sf_car/shift_logic
chart.Right-click
upshifting
and select Requirements > Select for Linking with Simulink.In the
sf_car
model window, double-click the User Inputs block.The Signal Builder dialog box opens, displaying four groups of signals. The Passing Maneuver signal group is the current active group. The RMI associates any requirements links that you add to the current active signal group.
In the Signal Builder window, in the Active Group list, select
Gradual Acceleration
.At the far-right end of the toolbar, click the Show verification settings button
. Ensure that the Requirements display button
is selected.
A Requirements pane opens on the right-hand side of the Signal Builder dialog box.
Place your cursor in the window, right-click, and select Open Outgoing Links dialog. The Outgoing Links dialog opens.
Click New. In the Description field, enter
Upshifting
.In the Document type field, select
Simulink Diagram
. Click Use current. The software fills in the field with the Location: (Type/Identifier) information forupshifting
.Click Apply to create the link.
In the model window, select the User Inputs block, right-click, and select Requirements.
The link to the new requirement is the option at the top of the submenu.
To verify that the links were created, in the
sf_car
model window, in the Apps tab, click Requirements Manager. In the Requirements tab, click Highlight Links to highlight the model objects with requirements.Note
Links that you create in this way associate requirements information with individual signal groups, not with the entire Signal Builder block.
Close the
sf_car
model.