OpenFAST Simulink
OpenFAST Simulink
mexw64”
Kumara Raja E
This document is prepared keeping OpenFAST-2.2.0, may be valid for other versions of
OpenFAST also. Unlike in the FASTV8, the OpenFAST -2.2.0 does not have precompiled FAST
library and MEX files need to run OpenFAST through MATLAB (Simulink).
Generating “FAST_SFunc.mex64” requires the OpenFAST library files built prior to it. The
procedure for the same is given below.
Notice that “E: \OpenFAST\openfast-2.2.0 \build\bin” is empty. Because, files are added here
automatically after successful compilation.
Step01)
Note that “FAST.sln” is a Visual Studio solution file, so you need Visual studio installed on your
machine. I have used Visual Studio 2019 with Intel Parallel Studio_XE2019.
Step03)
Configuration Properties LinkerInput Additional Dependencies Choose the right path for
the libmex.lib file based on your matlab installation
Step05)
As already mentioned in the step01 new files are created in “E: \OpenFAST\openfast-
2.2.0_Test\build\bin”
2) To create “FAST_SFunc.mexw64”
NOTE: OpenFAST should be compiled before this step using the procedure illustrated above.
Make sure the variables “libDir” and “includeDir” are set correct. The “libDir” is the path where
“FASTlib_x64_Matlab.lib” and “MAP_x64.lib” are present.
libDir = 'E:\OpenFAST\openfast-2.2.0\build\bin';
includeDir = 'E:\OpenFAST\openfast-2.2.0\modules\openfast-library\src';