Filter löschen
Filter löschen

GRT Code from R2007b for 3-D Lookup does not compile

3 Ansichten (letzte 30 Tage)
Umut Durak
Umut Durak am 11 Mär. 2015
Bearbeitet: TecBen am 28 Okt. 2015
When I generate code using GRT in R2007b for 3-D Lookup blocks, I come with a source code;
/* Lookup 3-D
Search method: 'binary'
Use previous index: 'off'
Interpolation method: 'Linear'
Extrapolation method: 'Linear'
Use last breakpoint for index at or above upper limit: 'off'
*/
bpLocalVar0 = bpDataSet[0U];
bpLocalVar1 = bpDataSet[1U];
bpLocalVar2 = bpDataSet[2U];
maxIndex0 = maxIndex[0U];
maxIndex1 = maxIndex[1U];
maxIndex2 = maxIndex[2U];
maxIndex0 = plook_binx(u0, bpLocalVar0, maxIndex0, &frac);
fractions[0U] = frac;
bpIndices[0U] = maxIndex0;
...
...
But Visual Studio 2010 C++ compiler complains about the lines starting with bpLocal and says "Error C2440: cannot convert from 'void* const' to 'real_T*'. As I manualy make a type casting like
bpLocalVar0 = (realt_T*) bpDataSet[0U];
it works. Anything that I miss in code generation / optimization settings? or is there a bug in GRT tlc files for 3-D Lookup? This breaks my code generation pipeline quite severely. How can I fix it? Any ideas?
  1 Kommentar
TecBen
TecBen am 28 Okt. 2015
Bearbeitet: TecBen am 28 Okt. 2015
The same problem happens with n-D-Loop-Up table blocks also. It was fixed in new MATLAB releases greater than R2010a.

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Kategorien

Mehr zu Simulink Coder finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

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

Start Hunting!

Translated by