Matlab Function Block with error generated by Stateflow
Show older comments
I have been trying to use "Matlab Function" block for hours using very simple example from this link http://www.mathworks.co.uk/help/simulink/ug/creating-an-example-model-that-uses-a-matlab-function-block.html (see attached file), however I keep getting this errors reported by "Stateflow" (The weird thing is I do not use Stateflow): Error using construct_error (line 108) The current directory is d:\program files\matlabr\bin, which is reserved for MATLAB files.
Please change your current directory to a writable directory preferably outside of MATLAB installation area.
What I have done:
1. Change to other directory outside of Matlab installation area
2. mex set up to select the correct compiler in my system (Microsoft Visual 2010)
3. Generate Code for the MATLAB Function Block by selecting Build Model > Build to compile and build the model.
I have no idea what went wrong, I am pretty sure this should be a very common issue, I keep searching high and low in the internet for the solution but to no avail...
Could you please suggest the possible cause of the problem?
Many thanks in advance.
Accepted Answer
More Answers (1)
want2know
on 16 Jul 2013
0 votes
Categories
Find more on Simulink Coder in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!