Add simscape blocks programmatically
6 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Hello,
I tried to add a simscape block programmatically, using 'add_block()' function.
add_block('Simscape/Foundation Library/Electrical/Electrical Sources/Controlled Current Source',[gcb,'/Current Load'])
The following error occured:
There is no block named 'Simscape/Foundation Library/Electrical/Electrical Sources/Controlled Current Source'
I check if there is no mistake in path definition, also the simulink and simscape has been loaded using 'load_system()' function. Using simple command to built-in library works fine:
add_block('built-in/Gain',[gcb,'/Current Load'])
Thanks for help.
0 Kommentare
Antworten (1)
Siehe auch
Kategorien
Mehr zu Electromagnetic Models finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!