필터 지우기
필터 지우기

Simulink turn off data logging

조회 수: 125 (최근 30일)
Peter Kerekes
Peter Kerekes 2018년 5월 28일
댓글: Jinggang 2024년 7월 9일
Hello ! I do have the following problem: I have a very big simuling model, with a lot of subsystems. In this model a lot of signal have already logged. I'm making a test environment to run this model, and I have to test the result of the simulation. I have to log only a few data, but in the model there are approximately 150 logged signal (and it's made the simulation much slower). So for that, in my test environment I'd like to unlog all of the signal, and turn on only witch are necessary for me.

채택된 답변

TAB
TAB 2018년 5월 28일
편집: TAB 2018년 5월 28일
Disable all logging at once
% Find all ports with data logging enabled
pH = find_system('YourModelName', 'FindAll', 'on', 'Type', 'Port', 'DataLogging', 'on');
% Disable all logging
for x=1:length(pH)
set_param(pH(x), 'DataLogging', 'off');
end
  댓글 수: 2
Peter Kerekes
Peter Kerekes 2018년 5월 28일
편집: Peter Kerekes 2018년 5월 28일
Thank you, it's working, but somehow it can't find the all logged signal. It found 26 of 148.
Sina Sharifi
Sina Sharifi 2020년 7월 2일
편집: Sina Sharifi 2020년 7월 2일
Hi
I had a similar problem.
These lines solved it. Thank you.
Sina

댓글을 달려면 로그인하십시오.

추가 답변 (2개)

Paul Smith
Paul Smith 2019년 1월 31일
I had a similar issue, I ended up modifying to this though:-
pH = find_system('Your Model name','LookUnderMasks','all','FindAll', 'on', 'DataLogging', 'on');
'Type', 'Port'
Having type and port in the search misses other potentially logable terms.

Zhu
Zhu 2019년 7월 26일
Turn this model into .mdl format
Open model in text
Find all "datalogging on", set it to off
Done!
  댓글 수: 3
Herman Wong
Herman Wong 2024년 3월 7일
편집: Herman Wong 2024년 3월 7일
set_param(bdroot, 'InstrumentedSignals', []) --- awesome! Thanks Jun Yang!
Jinggang
Jinggang 2024년 7월 9일
Thank u Jun Tang, it works!

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Prepare Model Inputs and Outputs에 대해 자세히 알아보기

제품


릴리스

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by