malicelik
malicelik

Reputation: 55

MATLAB Coder syntax errors and unsupported functions

I'm trying to generate my MATLAB code to C. I have some issues about unsupported functions. Are there any alternative functions for 'mkdir', 'fileattrib' and 'dlmread' functions in MATLAB Coder?

Upvotes: 0

Views: 151

Answers (1)

Fred Smith
Fred Smith

Reputation: 41

MATLAB Coder does not have direct support for these functions.

From within MATLAB, when generating a MEX-function, you can use coder.extrinsic to call out to MATLAB.

For pure C code, you can use coder.ceval to incorporate your own handwritten C code to implement this functionality.

By combining, coder.target, and coder.ceval you can create MATLAB code that works in MATLAB, but uses your handwritten C code in the deployed application.

This is obviously more work, but you get the advantages of MATLAB Coder for the rest of your application.

Upvotes: 2

Related Questions