How to make coder use #define macro for constant values
이전 댓글 표시
I have a list of physical constants which are defined as constant properties in a classdef. For instance:
classdef uniConst
properties (Constant)
gravity=9.81;
pressure=1021;
end
end
When I use coder on a matlab script, coder inserts all of these constants as hard-coded values (such as 9.81 instead of gravity). Is there anyway to make coder use #define statements for such constant values so that the resultant code can be more human-readable?
답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Quantization에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!