Error during FFT analyzer is Simulink

3 ビュー (過去 30 日間)
Åsmund
Åsmund 2024 年 10 月 2 日
編集済み: Pramil 2024 年 10 月 7 日
On this picture you can see my simulink circuit and the error I get when i try to run the FFT analyzer through the powergui. I have already unticked the "Single simulation output" in the "Configuration parameters", and saved the data in workspace.
What does this error message mean? I am running on Matlab R2024a.
  1 件のコメント
Gayathri
Gayathri 2024 年 10 月 3 日
編集済み: Gayathri 2024 年 10 月 3 日
@Åsmund Can you please provide your Simulink file so that I get a deeper understanding of the model.

サインインしてコメントする。

回答 (1 件)

Pramil
Pramil 2024 年 10 月 7 日
編集済み: Pramil 2024 年 10 月 7 日
Hi Asmund,
I have faced a similar issue while using MATLAB R2024a. The issue seems to stem from the output variable being of type "Dataset".
What worked for me was to run the model and then convert the output variables into type "struct".
You can use the following code to do the same:
function newlogsout = Dataset2Struct(logsout)
newlogsout.time = logsout.getElement(1).Values.Time;
newlogsout.blockName = logsout.getElement(1).BlockPath.getBlock(1);
for i=1:logsout.numElements
newlogsout.signals(i).values = logsout.getElement(i).Values.Data;
newlogsout.signals(i).label = logsout.getElement(i).Values.Name;
newlogsout.signals(i).dimensions = 1;
end
end
After this, you can select the struct variables within "FFT Analyzer" and it should work just fine.
Hope it helps.

カテゴリ

Help Center および File ExchangeElectrical Sensors についてさらに検索

製品


リリース

R2024a

Community Treasure Hunt

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

Start Hunting!

Translated by