Timer interrupt S-function for Arduino due
1 回表示 (過去 30 日間)
古いコメントを表示
Hi!
I am trying to implement a S-function which uses one of the built-in timers of the Arduino Due to produce an ISR which outputs a function-call to a connected block.
I have tried making both non-inlined and inlined s-functions both I can't figure out how to define the interrupt handler function.
If I put it directly in my s-function .c-file I want to use the "ssCallSystemWithTid(S,0,tid)" command although since the handler function needs to be a void-void function I can't supply the "S" and "tid" input parameters and therefore I am unable to run the command.
If I try to put the handler function in the .TLC file instead I found the "LibBlockExecuteFcnCall(block, 0)" but that doesn't seem to work either, I actually succeded in building the model but nothing happens at the Arduino...
Anyone that can point me in the right direction here? I feel kind of lost...
Don't know how to include the code in the best way so I attached it as .txt files...
Regards, Max
0 件のコメント
回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Arduino Hardware についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!