CodeWarrior - Processor expert - IntFlash Bean-  Compiler Error

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

CodeWarrior - Processor expert - IntFlash Bean-  Compiler Error

跳至解决方案
3,291 次查看
ARBM66
Contributor I

Hello Everybody

 

I’m working with a licensed CodeWarrior ver. 5.9 and Processor expert and my MCU is MC9S12E128QFP80

 

I have a problem with the IntFlash bean in processor expert

I added the bean to my program and when I try to compile it I'm getting each time this error from compiler.

 

{{{

+IFsh1

  +ERROR: Compiler option -CpPPAGE=0x30 (address of PPAGE register) or -CpPPAGE=RUNTIME must be set to compile the generated code correctly

(current target settings, Compiler for HC12, Options, Code Generation tab, PPAGE register is used for paging). After compiler option change,

run Code design to apply the change in Processor Expert. For details, see Help of the bean.

}}}

I m trying just use this bean in a simple programming such as

 

IFsh1_SetByteFlash(0x7000,28);

   

IFsh1_GetByteFlash(0x7000,&data) ;

 

 I was wondering if anybody can help me

Thank you

标签 (1)
0 项奖励
回复
1 解答
959 次查看
ProcessorExpert
Senior Contributor III
Hello,
 
regarding to the problem of write and read a data to/from Flash. The problem is caused by incorrect address format in SetByteFlash and GetByteFlash methods.You can find more detailed information in the help of IntFlash Bean from bean´s pop up menu.
 
Please find an example project that shows how to write a data into Flash correctly.
 
best regards
Vojtech Filip
Processor Expert Support Team
E_128_write_flash.zip
Message Edited by t.dowe on 2009-09-11 11:30 AM

在原帖中查看解决方案

0 项奖励
回复
5 回复数
959 次查看
CrasyCat
Specialist III

Hello

 

Did you try to add the option -CpPPAGE=RUNTIME to your compiler command line as instructed by the message?

 

What happens then?

 

CrasyCat

0 项奖励
回复
959 次查看
ARBM66
Contributor I

Thank you CrasyCat for your kind reply,

Could you please explain me how and where I should do this job?

Actually I'm a begineer with CodeWarrior and Processor Expert.

Thanks

0 项奖励
回复
959 次查看
CrasyCat
Specialist III

Hello

 

In order to add option -CpPPAGE=RUNTIME to your project:

  - Open Target Settings dialog

  - Switch to Panel "Compiler for HC12"

  - in the command line field add -CpPPAGE=RUNTIME.

  - Close OK to close the dialog and re-build your application.

 

"

CrasyCat

0 项奖励
回复
960 次查看
ProcessorExpert
Senior Contributor III
Hello,
 
regarding to the problem of write and read a data to/from Flash. The problem is caused by incorrect address format in SetByteFlash and GetByteFlash methods.You can find more detailed information in the help of IntFlash Bean from bean´s pop up menu.
 
Please find an example project that shows how to write a data into Flash correctly.
 
best regards
Vojtech Filip
Processor Expert Support Team
E_128_write_flash.zip
Message Edited by t.dowe on 2009-09-11 11:30 AM
0 项奖励
回复
959 次查看
ARBM66
Contributor I

Finally I have succeeded to solve the problem but I have still had another problem:

I use the following routine for writing data in my program with IntFlash bean:

 

Fsh1_SetByteFlash(0x7000,28);

IFsh1_GetByteFlash(0x7000,&data) ;

 

Problem is when I check the "data" there is nothing inside it.

So I believe there is a protection for flash memory.

Please let me know how I can solve this?

Thanks

0 项奖励
回复