AnsweredAssumed Answered

Generate a WRONG S19 file after files are excluded and included again without changing any code

Question asked by Tsang Kim Fung on Jan 15, 2010
Latest reply on Jan 18, 2010 by Tsang Kim Fung

We found a big problem with the CodeWarrior IDE for HCS08. When a group of files are excluded and included again (without changing any source code and file inclusion) in a target, the complier would generate a WRONG S19 file for the target and some of the functions during the operation will be fail (e.g. jump to a dummy interrupt) and cause the MCU hang. Following is an example to show this big problem.


We use the Demo project provided by Freecale, which is the example for 802.15.4. Following are the testing steps:

1.      Create a new target (Test01) by “Clone existing target” and select “My Wireless App Ex08b”.

2.      Change the Application Filename path to “My_Wireless_App_Data\Test01\Test01.elf” in the target setting.

3.      Remove all the object code of all targets.

4.      Select the target “My Wireless App Ex08b” and “Make” the S19 file for the target.

5.      Select the new target “Test01” and “Make” the S19 file for the target.

6.      By using the “Compare Files” function of the CodeWarrior, it is found that the two generated S19 files are the same. (Only one line recording the date and time of the S19 file is different)

7.      Rename the file “Test01.s19” to “Test01_orig.s19”.

8.      Select the target “Test01”

9.      Use the mouse to include all the files in “MyApps” to the target as shown in Figure 1.

Figure 1

10. Use the mouse to click the same point again to exclude all the files in “MyApps” from the target as shown in Figure 2.

Figure 2

11. Include the file “MyApp_Ex08b.c” and “ToolBox.h” to the target again to make it change back to the original file inclusion.

Figure 3

12. Clear the object code of the “Test01” target and “Make” the S19 file.

13. By using the “Compare Files” function of the CodeWarrior, it is found that most of the contents of the new generated S19 file “Test01.s19” are different with the original one “Test01_orig.s19”.


This is a big problem of the CodeWarrior, since our developer may clone the target and include different files for different targets base on a core target. The problem cause the new generated application targets fail and hang during the operation. It is expected that NO any change of the S19 file should made by the complier when the file is exclude form and include into the target again.


Please advise any solution to solve this problem.


Attached please find our test project.

Our CodeWarrior IDE version is 5.7.0 Build 1932.