This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
MathWorks Embedded Coder with the MathWorks TI C2000 Hardware Support Package allows automatic build and execution on C2000 hardware from models developed using MATLAB and Simulink.
Texas Instruments C2000™ MCUs support 16-bit and 32-bit data types, but do not support native 8-bit data types. Simulink® models and Embedded Coder® software support many data types, including 8-bit data types.
If you select int8 or uint8 in your model, your simulation runs with 8-bit data, but in the generated code this data is represented as 16-bit. This may cause instances where data overflow and wraparound occur in the simulation, but not in the generated code.
In C2000 devices, in the generated code, the double data type is represented as single precision floating point values (32-bit). This representation results in a difference in data values in the simulation and the generated code.
Fixed-point data type is also supported and using C28x IQmath Library blocks, one can perform processor-optimized fixed-point mathematical operations.
Details on C28x IQmath Library blocks are available here.
One can enable the CRL as shown below when using fixed point math to generate optimized code using IQ math routines.
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.