Answered

Efficient decimation with Embedded Coder

If you could make all occurrences of dcsDec the same size then you would only get one variable. If that is not possible, ...

Efficient decimation with Embedded Coder

If you could make all occurrences of dcsDec the same size then you would only get one variable. If that is not possible, ...

nästan 12 år ago | 1

| accepted

Answered

Embedded coder: How to specify array function input parameter as constant (read only) ?

This is an oversight in the design. I've created a bug report. In the mean time, you can work around the problem by using a ...

Embedded coder: How to specify array function input parameter as constant (read only) ?

This is an oversight in the design. I've created a bug report. In the mean time, you can work around the problem by using a ...

ungefär 12 år ago | 0

| accepted

Answered

Simulink SFunction Interface Error: due to insufficient storage

Have you tried turning off debugging in the MATLAB Function block? That usually has a dramatic effect and allows many more exam...

Simulink SFunction Interface Error: due to insufficient storage

Have you tried turning off debugging in the MATLAB Function block? That usually has a dramatic effect and allows many more exam...

ungefär 12 år ago | 1

Answered

why embedded matlab function failed to determine the size of expression

In more recent versions your code should just work. However, in older versions the size of this pattern was not understood: ...

why embedded matlab function failed to determine the size of expression

In more recent versions your code should just work. However, in older versions the size of this pattern was not understood: ...

ungefär 12 år ago | 0

Answered

Coder deleting variable definitions

Hi Adam, Sorry to hear about your frustration. If you have 200 variables you might want to consider a different approach. ...

Coder deleting variable definitions

Hi Adam, Sorry to hear about your frustration. If you have 200 variables you might want to consider a different approach. ...

ungefär 12 år ago | 1

| accepted

Answered

coder.ceval for printf from stdio.h

This example worked for me: function simple_printf s1=['%s%-*.*f%s%d' 10 0]; s2=['Time level ' 0]; s3=['[s], Ite...

coder.ceval for printf from stdio.h

This example worked for me: function simple_printf s1=['%s%-*.*f%s%d' 10 0]; s2=['Time level ' 0]; s3=['[s], Ite...

mer än 12 år ago | 2

| accepted

Answered

Replacing the '@' symbol for MATLAB Coder

Hi Adam, What is the first error message you receive? The error message you mention above just means that there is someth...

Replacing the '@' symbol for MATLAB Coder

Hi Adam, What is the first error message you receive? The error message you mention above just means that there is someth...

mer än 12 år ago | 1

| accepted

Answered

the problem to generate a matrix in C + + code by Matlab coder

There is no way to get MATLAB Coder to generate multi-dimensional arrays in C. This usually is not a practical problem. For ...

the problem to generate a matrix in C + + code by Matlab coder

There is no way to get MATLAB Coder to generate multi-dimensional arrays in C. This usually is not a practical problem. For ...

mer än 12 år ago | 0

| accepted

Answered

Codegen saying variable is constrained to being non-complex when it's defined as complex

MATLAB Coder automatically renames variables. These two lines are actually constraining two separate variables. yvec1 = ...

Codegen saying variable is constrained to being non-complex when it's defined as complex

MATLAB Coder automatically renames variables. These two lines are actually constraining two separate variables. yvec1 = ...

mer än 12 år ago | 2

| accepted

Answered

MATLAB Coder licensing limitations

Please refer to the license agreement. I found this post that covers a lot of these issues: <http://www.mathworks.com/ma...

MATLAB Coder licensing limitations

Please refer to the license agreement. I found this post that covers a lot of these issues: <http://www.mathworks.com/ma...

mer än 12 år ago | 0

Answered

failed to determine the appropriate size in find

Try this: function [ y ] = a_test() x = zeros(5, 1); k1 = find(x > 1, 1); if (isempty(k1)) k1 = 0; end...

failed to determine the appropriate size in find

Try this: function [ y ] = a_test() x = zeros(5, 1); k1 = find(x > 1, 1); if (isempty(k1)) k1 = 0; end...

mer än 12 år ago | 0

Answered

codegen: Problems using a structure as an input parmeter

Hi AJ, Have you looked at coder.cstructname? That command can be used to specify the C name to use for a structure type. ...

codegen: Problems using a structure as an input parmeter

Hi AJ, Have you looked at coder.cstructname? That command can be used to specify the C name to use for a structure type. ...

mer än 12 år ago | 0

| accepted

Answered

code produced wrong fixed sized arrays causing exceptions

Hi Rami, I suspect this is happening because your target has 16-bit integers. The size vector is wrapping as one million can...

code produced wrong fixed sized arrays causing exceptions

Hi Rami, I suspect this is happening because your target has 16-bit integers. The size vector is wrapping as one million can...

mer än 12 år ago | 1

| accepted

Answered

codegen: Problems using a structure as an input parmeter

Have you tried compiling both of these files with a single call to the codegen command? You can pass multiple entry points, and...

codegen: Problems using a structure as an input parmeter

Have you tried compiling both of these files with a single call to the codegen command? You can pass multiple entry points, and...

mer än 12 år ago | 0

Answered

emlc generates two different c-files for the same supporting function when building two functions, how do you merge them?

Hi Todd, Just use this idiom emlc -c -T rtw:lib -report -d foo1 fcn1 fcn2 That will product a library with an entry p...

emlc generates two different c-files for the same supporting function when building two functions, how do you merge them?

Hi Todd, Just use this idiom emlc -c -T rtw:lib -report -d foo1 fcn1 fcn2 That will product a library with an entry p...

ungefär 13 år ago | 0

| accepted

Answered

Specifying function names in generated code using emlc

Hi Todd, You can specify multiple top-level functions to EMLC. Each top-level entry point will have the name you gave it in ...

Specifying function names in generated code using emlc

Hi Todd, You can specify multiple top-level functions to EMLC. Each top-level entry point will have the name you gave it in ...

ungefär 13 år ago | 0

Answered

emlc issue

Hi Jeremiah, Add the line task = 0; before the line task = input ..... This tells EMLC that you are expecting a ...

emlc issue

Hi Jeremiah, Add the line task = 0; before the line task = input ..... This tells EMLC that you are expecting a ...

ungefär 13 år ago | 2

| accepted

Answered

Using emlc to generate C code - function within a function problem

Try using eml.unroll on the for-loop. That will cause the loop to be unrolled in the generated code. This may or may not b...

Using emlc to generate C code - function within a function problem

Try using eml.unroll on the for-loop. That will cause the loop to be unrolled in the generated code. This may or may not b...

ungefär 13 år ago | 0

Answered

Running Previously User-Built MATLAB code from Simulink

Hi Andrew, Could you please provide a bit more detail? I am puzzled by how coder.extrinsic became involved in this? Wha...

Running Previously User-Built MATLAB code from Simulink

Hi Andrew, Could you please provide a bit more detail? I am puzzled by how coder.extrinsic became involved in this? Wha...

ungefär 13 år ago | 0

Running Previously User-Built MATLAB code from Simulink

Hi Andrew, Could you please provide a bit more detail? I am puzzled by how coder.extrinsic became involved in this? Wha...

ungefär 13 år ago | 0

Answered

what she does the eml_assert?

Hi Aydi, These are undocumented MathWorks functions. Can you provide some context? What problem are you trying to solve? ...

what she does the eml_assert?

Hi Aydi, These are undocumented MathWorks functions. Can you provide some context? What problem are you trying to solve? ...

mer än 13 år ago | 0