- https://www.mathworks.com/help//releases/R2021a/slrequirements/ref/rmi.html#d123e14739
- https://www.mathworks.com/help//releases/R2021a/slrequirements/ref/rmi.html#d123e14834
- https://www.mathworks.com/help//releases/R2021a/slrequirements/ref/rmi.html#d123e14753
How do I add a DOORs requirement link to a block in the simulink using code.
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
I found to set the DOORs template but not to append a new DOORs requirement
The following commands allows me to set and update all the requirements traced to a model.
->rmi('setDoorsLabelTemplate', '%h %200'); and rmi('updateDoorsLabels', example_model);
I need commands to append a new DOORs requirement to the existing tracing in the model:
Similar to these commands:
new_req = rmi('createempty');
new_req.doc = 'fuelsys_requirements2.htm';
new_req.description = 'A new requirement';
rmi('cat', blk_with_req, new_req);
0 commentaires
Réponses (1)
Snehal
le 20 Juin 2025
I see that you want to append a new requirement to an existing set of requirements traced to a block or model element in Simulink.
The code snippet that you have provided in the question is a correct approach to achieve this goal, and here is how you can use the ‘rmi’ functions effectively:
% 1. Specify the block to which you want to append a requirement
blk_with_req = 'your_model/your_block_name';
% 2. Create a new empty requirement structure
new_req = rmi('createempty');
% 3. Populate the new requirement with DOORS-specific fields
new_req.id = 'absolute_DOORS_object_URL';
new_req.type = 'DOORS';
new_req.doc = 'your_DOORS_module_name';
new_req.description = 'Brief description of the new requirement';
% 4. Append the new requirement to the existing ones for the block (here, ‘cat’ refers to concatenation)
rmi('cat', blk_with_req, new_req);
You can verify if the new requirement is added successfully or not executing the following command:
reqs = rmi('get', blk_with_req);
Refer to the following documentation links regarding different valid syntax for ‘rmi’ function:
Hope this helps!
0 commentaires
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!