Can I remove FPROT section in a re-directed user application?

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

Can I remove FPROT section in a re-directed user application?

跳至解决方案
565 次查看
kai_liu
Senior Contributor I

During my development of bootloader for KL25Z, I found user application starts from any other flash address including 0x4000/0x8000/0xC000 still reserve its original flash protection bytes. Is that necessary?

If we remove these re-directed flash protection bytes, we can save some memory for user application, which is meanful in small micros like KL05Z/KL02Z.

Considering re-direct address is 0x8000, the flash memory ranges from 0x8400 to 0x840F can be freed for user code. Some icf link file even start user application from 0x410 and abandons the room before 0x0400,  like FRDM_KL25ZDemo project does. If we remove this, then we can save more bytes, like 0xC0~0x420, about 864 B.

标签 (1)
标记 (3)
0 项奖励
1 解答
379 次查看
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Liu Kai,

The FPROT section will be loaded to FTFA_FPROTn register during the chip reset. During the chip reset, the 0x400 ~0x40F value will be loaded.

After the chip reset, the FPROT related section without any function during the application code run phase.

If the customer application code re-directed at 0x8000, the 0x8400~0x840F contents can be erased without any problem.

Wish it helps.

B.R.

Ma Hui

在原帖中查看解决方案

0 项奖励
1 回复
380 次查看
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi Liu Kai,

The FPROT section will be loaded to FTFA_FPROTn register during the chip reset. During the chip reset, the 0x400 ~0x40F value will be loaded.

After the chip reset, the FPROT related section without any function during the application code run phase.

If the customer application code re-directed at 0x8000, the 0x8400~0x840F contents can be erased without any problem.

Wish it helps.

B.R.

Ma Hui

0 项奖励