Function 'tic' is not supported for code generation

9 ビュー (過去 30 日間)
chfakht chfakht
chfakht chfakht 2015 年 3 月 13 日
回答済み: Ander Erroicenea 2019 年 3 月 21 日
Hi all,
please i need to know how to calculate the elapsed time between 2 part of my matlab script because tic and toc are not supported for code generation
thanks

回答 (2 件)

Sebastian Castro
Sebastian Castro 2015 年 3 月 13 日
You can use coder.ceval to call an external function. To implement your own timing, you could include time.h and use the functionality there.
- Sebastian
  2 件のコメント
chfakht chfakht
chfakht chfakht 2015 年 3 月 13 日
Thanks :) have you an example of that ??
Sebastian Castro
Sebastian Castro 2015 年 3 月 13 日
I found something similar on Answers, in which the answer calls printf commands from stdio.h:

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


Ander Erroicenea
Ander Erroicenea 2019 年 3 月 21 日
The same error appears to me, how did you resolve it?
- Ander.

カテゴリ

Help Center および File ExchangeSimulink Coder についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by