How can I avoid doubles from char arithmetic in fixed-point codegen in MATLAB Coder R2025a?
Mostrar comentarios más antiguos
I am generating fixed-point code using Fixed-Point Designer and MATLAB Coder R2025a. My code will be used on a small embedded microcontroller that does not support floating-point operations. One of the lines of code that is being translated as resulting in data of type
"double" rather than "char" is the following:
x(:) = (s(i) - '0');
where "s" is a character array.
What do I need to do to get the generated code to not use doubles in instances like this?
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Create Fixed-Point Objects in MATLAB en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!