P2041 Booting with custom binary file

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

P2041 Booting with custom binary file

1,907 次查看
veerendranathj
Contributor III

Hi,

I want to boot P2041RDB board with my custom generated binary file. For that I want to create a binary file from Embedded  C/Assembly language and wants place it in booting location. But I am beginner in this  area I didn't get tutorial online. Please help me here.

Thanks,

Veerendranatn

标签 (1)
标记 (2)
8 回复数

1,314 次查看
monalihaware
Contributor III

Could you do the required thing. Even I wanted to do the same .could you help?

0 项奖励

1,314 次查看
alexander_yakov
NXP Employee
NXP Employee

We recommend using our CodeWarrior development tools for that purpose:

CodeWarrior Dev Tools for Power Architecture|Freescale

After downloading and installation, please refer to documentation in \PA\Help folder in CodeWarrior installation.

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 项奖励

1,314 次查看
veerendranathj
Contributor III

thanks for the reply,

I have installed and explored through the tool. using the tool I could generate only elf file but to run on a bare board we need binary file right?. How to generate binary file in Code Warrior?.  what I tried till now is I generated binary file(using GCC tool chain not codewarrior) for the board and replaced uboot on NOR flash with the generated binary. But It wasn't successful( though I could run my binary file from RAM, I am facing issue when tried to flash on NOR flash and boot using my binary file).

Regards,

Veerendranath

0 项奖励

1,314 次查看
addiyi
NXP Employee
NXP Employee

There is not an option in Project settings, but you can manually run powerpc-eabi-objcopy.exe available under \Cross_Tools\gcc-4.9.2-Ee500mc-eabi\bin\.

This will convert elf file generated after project compilation into a binary file.

Adrian

1,314 次查看
veerendranathj
Contributor III

thanks for the information... I am able to generate binary file using GCC toolchain. But I want to load it into NOR/NAND Flash and want to boot from there... so I replaced u-boot binary with my binary (without changing default RCW which is pointing to u-boot location). Board was booted and executed fine. Now I want put my binary in some custom location(Instead of u-boot location) but I couldn't find where to mention/put my binary location in RCW while creating it. I have gone through QCVS(QorIQ Configuration and Validation Suite) Guide regarding PBL.bin(contains RCW and PBI) creation but I couldn't find any information regarding this... Please help me here..

Thanks,

Veerendranath

0 项奖励

1,314 次查看
addiyi
NXP Employee
NXP Employee

You can't put your binary in a custom location. You have to respect the boot procedure for cpu. Your code must fall over the latest 4Kb in NOR. So, you have 2 possibilities. One is to replace uboot with your app (you already done this) and the second is to put a jump in the latest 4Kb in NOR. that goes to your custom location.

Adrian

0 项奖励

1,314 次查看
veerendranathj
Contributor III

I am talking at level of Pre-Boot Loader... not at booting level... generally we have to mention where is the boot loader( whether it is u-boot or my binary) in PBL.bin( Pre Boot Loader.bin)... I know that We have to create PBL.bin using QCVS(QorIQ Configuration and Validation Suite) but I could't find where to mention boot loader location while creating PBL.bin...

Thanks,

Veerendra

0 项奖励

1,314 次查看
addiyi
NXP Employee
NXP Employee

All additional PBL commands should be placed in PBI Data (PBI Data input). You have to know the register to mention where is the boot loader, the space of this register (CCSR or ACS) and of course the value.

Adrian

0 项奖励