From the series: Developing Buck-Boost Converter Control with Simulink
Vivek Raju, MathWorks
Learn how to implement a digital controller for a buck-boost converter on an embedded processor. The buck-boost converter is part of a DC/DC LED kit from Texas Instruments™. The microcontroller is a Texas Instruments TMS320F28035 processor. Once the controller has been designed and verified in Simulink®, Embedded Coder® is used to automatically generate code for implementation on the embedded processor.
To generate code optimized for Texas Instruments TMS320F28035 processor, the example shows how to install Embedded Coder Support Package for Texas Instruments C2000 Processors. The blocks from this support package are used to update the controller. Additionally, the support package also includes driver blocks for the TMS320F28035 processor which are also used in the model.
After the model is updated, Embedded Coder is used to generate C code. The code generation report provides bi-directional traceability between the Simulink model and generated code to help understand the generated code better.
The example shows how to generate algorithmic and driver code for the controller and how to deploy this code to the embedded processor. External mode in Simulink is used to change the LED brightness command from the Simulink model and to verify how the generated code running on the embedded microprocessor is performing.