Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

New to MATLAB?

Prevent Matlab Coder from making temp arrays into global arrays

Asked by Jim Clay

Jim Clay (view profile)

on 19 Nov 2012

I am using Embedded Coder to turn Simulink models into C. It appears, though, that Embedded Coder uses Matlab Coder on the Matlab Function blocks. This would be fine, except Matlab Coder makes temporary arrays (e.g. arrays inside of sub-functions) into globals. Is there any way to prevent this?

1 Comment

Arnab De

Arnab De (view profile)

on 21 Nov 2012

Can you please post some MATLAB code where you see this behaviour?

Jim Clay

Jim Clay (view profile)

0 Answers

Contact us