MCUXpresso IDE
Rearrange source files
For RT1170, import
dev_msc_disk_bm_cm7
anddev_hid_mouse_bm_cm4
example. For RT1180, importdev_msc_disk_bm_cm33
anddev_hid_mouse_bm_cm4
example.Open the directory of the two examples in the file explorer.
For RT1170, compare the whole project directory and add the folders that are in the
cm7
project but notcm4
to thecm4
project. For RT1180, compare the whole project directory and add the folders that are in thecm33
project but notcm7
to thecm7
project.Compare the two folders. For RT1170, delete the files that are in the
cm4
project but notcm7
and add the files that are in thecm7
project but notcm4
to thecm4
project. For RT1180, delete the files that are in thecm7
project but notcm33
and add the files that are in thecm33
project but notcm7
to thecm7
project. In the RT1170 case,
For the
board
,source
, andusb
folders, replace them in thecm4
project with the ones in thecm7
directory.|
|
- For the `component` folder, delete the `timer` folder in the `cm4` directory.
|
|
- For the `drivers` folder, delete `fsl_pit` source files in the `cm4` project and add `fsl_usdhc` source files to the `cm4` directory.
|
|
- For the `sdmmc` folder, copy it to the `cm4` project.
|
|
Rearrange project files
After the source files are updated, the project files are loaded to the
cm4
project of RT1170 or thecm7
project of RT1180 automatically. No manual updates to the project files are required.Due to the deletion in the first step, for the board, source and usb folders, an option must be deleted in the properties. Right click board -> properties -> C/C++build and uncheck Exclude resource from build. Perform the same operation in the source and usb folders. Take RT1170 as an example:
|
|
Adjust project settings
Note: The following steps are described for RT1170. However, these steps are also applicable for RT1180.
Compare the macro in the project settings, by clicking Properties -> C/C++ Build -> Setting -> MCU C Compiler -> Preprocessor. Add the macro that is in the
cm7
project but not incm4
to thecm4
project.In this case, the macro is
SD_ENABLED
.|
|
2. Change the include paths in the project settings, by clicking **Properties** -\> **C/C++ Build** -\> **Setting** -\> **MCU C Compiler** -\> **Includes**, according to the changes of project files.
In this case, delete the paths framed in the red box and add the paths in the green box.
|
|
Change project name
Right-click project name > rename, change the filename
dev_hid_mouse_bm_cm4
todev_msc_disk_bm_cm4
, and then click OK.|
|
With all above steps done, the RT1170 M7 project successfully changes to an M4 project and the M4 example USB project is available for downloading and debugging. The RT1180 M33 project successfully changes to an M7 project and the M7 example USB project is downloading and debugging.