1

I'm working on automated model building. In some cases I have do convert a bus into another bus (the structure is the same, but there can be variants in the names). It works for a static model where I can change the datatype of the inputs and outputs, but I didn't find any way to do this from the command line or directly in an embedded MATLAB function.

Does anybody know a way to do this?

Clifford
  • 88,407
  • 13
  • 85
  • 165
Basti
  • 11
  • 5
  • 1
    ok got it. Just 3 Lines of code: mfb = find(sfroot, '-isa', 'Stateflow.EMChart', 'Name', 'test'); out = get(mfb, 'Outputs'); out.set('DataType', ['Bus: ' component_source.test]); – Basti May 20 '14 at 09:25

1 Answers1

0
mfb = find(sfroot, '-isa', 'Stateflow.EMChart', 'Name', 'test'); 
out = get(mfb, 'Outputs'); 
out.set('DataType', ['Bus: ' component_source.test]); 
Basti
  • 11
  • 5