update popup list by script

This commit is contained in:
Matthew GONG
2020-03-20 20:13:20 +08:00
parent d37936b981
commit 47ca553381
2 changed files with 13 additions and 0 deletions
BIN
View File
Binary file not shown.
+13
View File
@@ -0,0 +1,13 @@
function hal_sen_popup_update
lst = {'RPM1','RPM2','hello'};
load_system('hal_api_sens');
set_param('hal_api_sens','Lock','off');
b = Simulink.Mask.get('hal_api_sens/hal_sen_read');
p = b.Parameters(1);
p.set('TypeOptions',lst);
set_param('hal_api_sens','Lock','on');
close_system('hal_api_sens',1);
end