Filter löschen
Filter löschen

Embedded coder: How to specify enumeration type name.

2 Ansichten (letzte 30 Tage)
Hank
Hank am 23 Jun. 2014
Bearbeitet: Hank am 23 Jun. 2014
I specified an enumeration like this:
classdef (Enumeration) blabla < int32
enumeration
blabla0(0)
blabla1(1)
blabla2(2)
end
end
I put this in a subdirectory "veryLongDirectoryName", and use it MatLab code as follows:
veryLongDirectoryName.blabla.blabla0
When I use this type in MatLab code for C code generation, the type of the enumeration includes the directory name. I don't want that. I expected the enumeration type in C to be "blabla", not "veryLongDirectoryName_blabla". The result was that the identifier became too long and the coder truncates it to something not very readable.
(I know about removing the type name from the enumeration members, but that is not what I mean.)
How can I specify the type name of the enumeration in C code ? Just like coder.cstructname(), but then for enumerations.

Antworten (0)

Kategorien

Mehr zu Deployment, Integration, and Supported Hardware finden Sie in Help Center und File Exchange

Produkte

Community Treasure Hunt

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

Start Hunting!

Translated by