Header file error in simulink

An error occurs when I try to build and deploy my simulink code to a lego mindstorm robot
My error says:
Error(s) encountered while building "filename"
Caused by:
  • The compiler error indicates that a type is redefined. Tjis error can occur if your costum code includes the header file tmwtypes.h instead of rtwtypes.h. For information about using the directive #include "tmwtypes.h" in costume code, refer to the documentation. Alternatively, specify backwards compatibility for your model by running set_param('filename', 'InterredTypesCompatibility', 'on'.
Component: Simulink | Category: Block diagram error
It seemes that something goes wrong when saving the file, but I'm not sure. I also tried to update MATLAB, because I thought the missing update might help if it's a bug, but I got an error message threre aswell (which referd me to the ask community site).
I'd appreciate any help:)

1 Comment

did you run ?
set_param('filename', 'InterredTypesCompatibility', 'on')
In above case filename is not variable what is your filename?

Sign in to comment.

Answers (0)

Categories

Products

Release

R2021a

Asked:

on 12 Oct 2021

Commented:

on 12 Oct 2021

Community Treasure Hunt

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

Start Hunting!