Dear Nikhar/Boni,
I have successfully coupled the Discon.dll with MATLAB using functions loadlibrary and calllib. The procedure to implement this involved writing a header file in FORTRAN, which provides the definition and class of each variable being passed in and out of the DLL. Using this implementation, I have developed an in house aeroelastic code (OxDyn) that closely matches OpenFAST for the NREL 5MW turbine as shown below:
I have now tried to model the NREL 15MW turbine however when I simulate this turbine the Discon.dll controller only outputs zero generator torque and blade pitch even when the wind speed and generator speed that I pass to the controller are within operating conditions. Just to be clear, I have changed the Discon input files to the relevant files for the NREL 15MW.
The controller does output a generator torque when I set the gearbox ratio is set to 97 with the NREL 15MW but this is obviously not the correct setting since the 15MW turbine is direct drive. Therefore my first question is if it is possible to simulate the NREL 15MW turbine with the discon.dll rather than the libdiscon.dll? if so can you provide guidance on how to do this?
I have tried to change the dll from the discon.dll to the libdiscon.dll but in this case MATLAB crashes without giving any warning therefore making it difficult to debug. I think the source of this crash is because the variables that are being passed to the libdiscon.dll are different from the discon.dll but I am hoping you can also clarify this?
Any help with this issue would be greatly appreciated.
Kind regards,
Gerard Ryan