SREC file generation from command line

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

SREC file generation from command line

ソリューションへジャンプ
3,290件の閲覧回数
vsantos01
Contributor II

Hi

I'm using a custom build chain, using proprietary toolchain, that I launch from the command line (from my continuous integration system). I use tools from this toolchain to create an srec file from the linked elf.

I need to validate the output of the SREC generation and I've thought on using a different tool to generate again the srec and compare the two srec files obtained (build chain vs alternate tool). I have downloaded the S32K1 Design Studio (v3.5) hoping to get from there the tool needed, but all documentation I'm finding points on how to do it thorugh the IDE.

Which tool can be used to generate the srec file, out from an elf file, from the command line?

thanks

0 件の賞賛
返信
1 解決策
3,265件の閲覧回数
jiri_kral
NXP Employee
NXP Employee

Hi,

you can use gnu objcopy - 

arm-none-eabi-objcopy -O srec my.elf my.srec

 

With default install path is objcopy located in c:\NXP\S32DS.3.5\S32DS\build_tools\gcc_v9.2\gcc-9.2-arm32-eabi\bin\  folder. 

 

元の投稿で解決策を見る

4 返答(返信)
3,266件の閲覧回数
jiri_kral
NXP Employee
NXP Employee

Hi,

you can use gnu objcopy - 

arm-none-eabi-objcopy -O srec my.elf my.srec

 

With default install path is objcopy located in c:\NXP\S32DS.3.5\S32DS\build_tools\gcc_v9.2\gcc-9.2-arm32-eabi\bin\  folder. 

 

3,248件の閲覧回数
vsantos01
Contributor II

Ok, I can generate an srec file already which seems to match my needs. Now I just need to tweak around the options to get the same file I'm generating with the other tool. Thanks!

0 件の賞賛
返信
3,240件の閲覧回数
jiri_kral
NXP Employee
NXP Employee

Hi, 

if you need different format - you can use srec_cat tool: 
https://srecord.sourceforge.net/

 

0 件の賞賛
返信
3,261件の閲覧回数
vsantos01
Contributor II

Thanks for the feedback. I will give it a try, though I read on the web that it generates intel hex file and I'm not sure it will work for the project. Be back with results.

0 件の賞賛
返信