5. Using Reactis for C with Jenkins#
Reactis for C can also be used with Jenkins. The steps required are similar to the ones for using Reactis (for Simulink), with the main difference being that the use of MATLAB is optional. If MATLAB is not used, then a C/C++ program will need be written which calls the Reactis for C API. This program should be compiled into a binary executable, which can then be called from a Jenkins Execute Windows batch command or Execute shell build action. The primary advantage of using C/C++ instead of MATLAB is that a MATLAB license is not required, while the disadvantage is that the process of developing the program which performs the testing will likely be more difficult.
If MATLAB is used, the required steps will be very similar to the those used to test Simulink/Stateflow models with Reactis under Jenkins. The primary difference will be that the MATLAB script will call the Reactis for C API.
If MATLAB is not used, you will need a C compiler, such as gcc or Microsoft
Visual Studio. The full details of developing a C program which uses the
Reactis for C API are beyond the scope of this paper, but you will need to
write a C program which uses the API functions listed in reactis4c.h
and is
linked with the API library (libreactis4c.lib
or libreactis4c.dll
). Reactis
for C API documentation can be found on the Reactis Support page.