Generate code from a simulink model that calls a dll via C S-function

5 views (last 30 days)
Hello,
i have a dll that i need to call in simulink. Afterwards i want to generate Code from simulink for a real time application.
So far i wrote a S-Function in C to call the dll. In simulink i use the S-function block to call my S-function and in normal simulation mode it works just fine. On generating code i get an error due to Matlab cant open source file windows.h.
I checked the internet for a solution and found out that there is the problem that my S-function uses a windows compiler to call the dll but in code generation this compiler cant get used due to the Matlab compiler is generating the code. But there werent any solutions for that problem.
Anyone got a clue how to solve my issue?
Thanks

Answers (0)

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!