Filter löschen
Filter löschen

Is it possible to call macro functions in Simulink?

2 Ansichten (letzte 30 Tage)
Szabolcs Fodor
Szabolcs Fodor am 25 Feb. 2020
Dear all,
Is it possible to call macro functions defined in C header files in Simulink?
For instanceand for the sake of argument, you have the following header file (errPro.h) :
#ifndef ERRPRO_H_
#define ERRPRO_H_
#define MAXi(a, b) (((a)>(b))?(a):(b))
#define xyz(a, b) ((a)<(b))
#endif
After including this particular header file to the right place (Simulation Target -> Header File), is it possible to call these macro functions in Simulink? I know that it is possible to call functions with c caller in Simulink, but I was not able to figure it out with macro functions.
Any help is highly appriciated, so thanks in advance.
Best regards,
Szabi

Antworten (0)

Kategorien

Mehr zu Simulink Environment Customization finden Sie in Help Center und File Exchange

Produkte


Version

R2019b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by