2.12 Automatically Update the I/O Header File

When an application project is newly created, an I/O header file corresponding to the selected device is automatically generated.

If the I/O header file needs to be automatically updated in response to the update of the device file, use the following update method.

 

The I/O header file is automatically generated as "iodefine.h" when an application project is newly created and it is registered in the project tree.

Figure 2.74

I/O Header File (iodefine.h)

 

Remark

The I/O header file is generated in the same folder containing the project file. If a file with the same name already exists, the existing file is renamed as "iodefine.bak" as a backup.

 

The timing to update the I/O header file and the update method are shown below.

-

At opening of the project

CS+ checks the version of the device file when a project is opened.

If the device file has been updated and there is a possibility that the I/O header file needs to be updated, a message is displayed on the Output panel. Update the I/O header file with the method below as required.

-

On the Project Tree panel, select the Build tool node, and then select [Generate I/O Header File] from the context menu

Figure 2.75

[Generate I/O Header File] Item

-

At build

The I/O header file can be updated automatically when the build process is performed and immediately before build.

Set the [Update I/O header file on build] property of the [I/O Header File Generation Options] tab in the Property panel. The update conditions can also be changed in the property of the same category.

Figure 2.76

[Update I/O header file on build] Property