How can compile in C/C++ the lpc funciton ?

4 ビュー (過去 30 日間)
Florian
Florian 2014 年 4 月 29 日
編集済み: Mike Hosea 2018 年 9 月 12 日
I am trying to compile the lpc function (Linear Predicitve Coding) in C/C++ to later include it in a CSS project in order to implement it into a Texas instrument DSP board. The LPC function can't be compile because I am getting this error: "The function 'lpc' is not supported for standalone code generation.".
I did a bit of research and I understood why I am getting that. But is there a work around ? (coder.extrinsic() is not an option as I need to implement it on a DSP board later.)
By looking inside the lpc function (type lpc) we can understand what is going on inside it. So why can't we compile it in C/C++ ?
Thanks for your time in advance
  1 件のコメント
De Meng
De Meng 2018 年 9 月 11 日
I am running into the same problem. Can this be solved by coder.extrinsic('lpc')? It does not seem work for me.

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

採用された回答

Mike Hosea
Mike Hosea 2018 年 9 月 12 日
編集済み: Mike Hosea 2018 年 9 月 12 日
Extrinsic calls can work only when the target is mex or one is simulating in Simulink. This is because extrinsic calls are calls into the MATLAB computation engine. No code is generated for them except what is needed to marshal the data back and forth.
You will need to write your own LPC function and your own LEVINSON function. No reason why you can't learn how by looking at our code, but I see that LEVINSON isn't implemented as a MATLAB file, so that will take a little more work. Still, that doesn't look hard if you only need the first output from LPC.

その他の回答 (0 件)

Community Treasure Hunt

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

Start Hunting!

Translated by