Code shared between Processor Expert configurations

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

Code shared between Processor Expert configurations

跳至解决方案
1,103 次查看
allgood38
Contributor I

I am currently developing code for the KL15Z128, but often only have access to the KL25Z128 for testing. Right now I have two completely separate projects in KDS for each chip, and need to carefully merge changes between them as I add code.

I was thinking it would be cool to create two projects dedicated to generating the Processor Expert configurations, which create the same components with exactly the same names, whose source files are included by a third project which contains the actual code.

Is this the right way for going about this? Does KDS (or maybe Codewarrior) have a method for doing this?

Thanks,

标记 (2)
0 项奖励
回复
1 解答
978 次查看
BlackNight
NXP Employee
NXP Employee

You can consider this approach: one project with two configurations. You can have two CPU's in the project and switch between them.

See http://mcuoneclipse.com/2012/03/07/configurations-with-processor-expert/

I'm doing this for several of my projects.

The only disadvantage is that you can not have both project 'active' the same time (e.g. to debug in parallel for the KL15 and the KL25). In that case I'm doing the approach you mentioned: two projects (with different CPU's, but same components), but not sharing the generated code, but the application code/sources in a 'common' folder/library.

I hope this helps,

Erich

在原帖中查看解决方案

0 项奖励
回复
2 回复数
979 次查看
BlackNight
NXP Employee
NXP Employee

You can consider this approach: one project with two configurations. You can have two CPU's in the project and switch between them.

See http://mcuoneclipse.com/2012/03/07/configurations-with-processor-expert/

I'm doing this for several of my projects.

The only disadvantage is that you can not have both project 'active' the same time (e.g. to debug in parallel for the KL15 and the KL25). In that case I'm doing the approach you mentioned: two projects (with different CPU's, but same components), but not sharing the generated code, but the application code/sources in a 'common' folder/library.

I hope this helps,

Erich

0 项奖励
回复
978 次查看
allgood38
Contributor I

Great, thanks!

I hadn't realized that the additional CPU component would automatically create a new configuration, and that enabling/disabling a component would stick to the active configuration.

0 项奖励
回复