4.6 MCC Code Generation

Once the code is configured (as shown in the previous sections), click the Generate button on the Project Resources window. Code generated by the MCC is modular. Therefore main, system, and peripheral code are all in individual files. Also, each peripheral has its own header file.

Editing of main.c is always required to add functionality to your program. Review the generated files to find any functions or macros you may need in your code.

Figure 4-10. Code Generated in Project Tree
Figure 4-11. Code Generated in Progress in Output Window