How to support multiple targets in CodeWarrior(Classic, Eclipse)/KDS

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to support multiple targets in CodeWarrior(Classic, Eclipse)/KDS

How to support multiple targets in CodeWarrior(Classic, Eclipse)/KDS

In some application, we hope one project can support multiple targets. Some typical examples: user needs different firmware to run on different PCB with different crystal on it; Or sometimes user needs one project support both debug and release mode; another widely used example is, user needs one project support multiple part numbers.etc.

To implement the multiple targets project, we will consider at least three aspects:

  • Depend on the different targets, some files/codes may be included or not. 
  • Depend on the different targets, compiler/linker settings may be different.
  • If bootloader involved, different target may link with different bootloader firmware.

 

In this article I will discuss this topic with Classic CodeWarrior and Eclipse CodeWarrior10.x/KDS separately.

Original Attachment has been moved to: Multi-Targets-Project_Classic-CW-HCS12-v5_1.zip

Original Attachment has been moved to: Multi-Targets-Project_KDS-v3_2.zip

Attachments
Comments

Sometimes macro is enabled, but the editor still shows it grayed out. See solution here:

Fixing the Eclipse Index | MCU on Eclipse 

%3CLINGO-SUB%20id%3D%22lingo-sub-1103260%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3EHow%20to%20support%20multiple%20targets%20in%20CodeWarrior(Classic%2C%20Eclipse)%2FKDS%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1103260%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3E%3CSPAN%20style%3D%22font-size%3A%2014.0pt%3B%22%3EIn%20some%20application%2C%20we%20hope%20one%20project%20can%20support%20multiple%20targets.%20Some%20typical%20examples%3A%20user%20needs%20different%20firmware%20to%20run%20on%20different%20PCB%20with%20different%20crystal%20on%20it%3B%20Or%20sometimes%20user%20needs%20one%20project%20support%20both%20debug%20and%20release%20mode%3B%20another%20widely%20used%20example%20is%2C%20user%20needs%20one%20project%20support%20multiple%20part%20numbers.etc.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%20style%3D%22font-size%3A%2014.0pt%3B%22%3ETo%20implement%20the%20multiple%20targets%20project%2C%20we%20will%20consider%20at%20least%20three%20aspects%3A%3C%2FSPAN%3E%3C%2FP%3E%0A%3CUL%20style%3D%22list-style-type%3A%20disc%3B%22%3E%0A%3CLI%3E%3CSPAN%20style%3D%22font-size%3A%2014.0pt%3B%22%3EDepend%20on%20the%20different%20targets%2C%20some%20files%2Fcodes%20may%20be%20included%20or%20not.%26nbsp%3B%20%3C%2FSPAN%3E%3C%2FLI%3E%0A%3CLI%3E%3CSPAN%20style%3D%22font-size%3A%2014.0pt%3B%22%3EDepend%20on%20the%20different%20targets%2C%20compiler%2Flinker%20settings%20may%20be%20different.%3C%2FSPAN%3E%3C%2FLI%3E%0A%3CLI%3E%3CSPAN%20style%3D%22font-size%3A%2014.0pt%3B%22%3EIf%20bootloader%20involved%2C%20different%20target%20may%20link%20with%20different%20bootloader%20firmware.%3C%2FSPAN%3E%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%20style%3D%22min-%20padding%3A%200px%3B%22%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CSPAN%20style%3D%22font-size%3A%2014.0pt%3B%22%3EIn%20this%20article%20I%20will%20discuss%20this%20topic%20with%20Classic%20CodeWarrior%20and%20Eclipse%20CodeWarrior10.x%2FKDS%20separately.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3EOriginal%20Attachment%20has%20been%20moved%20to%3A%20%3CA%20href%3D%22https%3A%2F%2Fcommunity.nxp.com%2Fdocs%2FDOC-339766%22%20target%3D%22_blank%22%3EMulti-Targets-Project_Classic-CW-HCS12-v5_1.zip%3C%2FA%3E%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3EOriginal%20Attachment%20has%20been%20moved%20to%3A%20%3CA%20href%3D%22https%3A%2F%2Fcommunity.nxp.com%2Fdocs%2FDOC-339766%22%20target%3D%22_blank%22%3EMulti-Targets-Project_KDS-v3_2.zip%3C%2FA%3E%3C%2FSTRONG%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1103261%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20How%20to%20support%20multiple%20targets%20in%20CodeWarrior(Classic%2C%20Eclipse)%2FKDS%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1103261%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3ESometimes%20macro%20%3CSTRONG%3Eis%3C%2FSTRONG%3E%20enabled%2C%20but%20the%20editor%20still%20shows%20it%20grayed%20out.%20See%20solution%20here%3A%3C%2FP%3E%3CP%3E%3CA%20class%3D%22link-titled%22%20href%3D%22https%3A%2F%2Fmcuoneclipse.com%2F2012%2F03%2F20%2Ffixing-the-eclipse-index%2F%22%20title%3D%22https%3A%2F%2Fmcuoneclipse.com%2F2012%2F03%2F20%2Ffixing-the-eclipse-index%2F%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%20target%3D%22_blank%22%3EFixing%20the%20Eclipse%20Index%20%7C%20MCU%20on%20Eclipse%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
No ratings
Version history
Last update:
‎12-14-2021 01:18 AM
Updated by: