2024-05-24 06:46 AM
Hi,
I'm using TMS570 with SPC5STUDIO environment.
My toolchain generates out.elf and out.hex but I would like to have
a byte hex stream (without address and other information) directly do use as download by
another microcontroller that lead TMS570.
I have to write a source code to analyze and parse the .hex or
it already exsist that format?
Thanks
Fabio
Solved! Go to Solution.
2024-05-24 07:55 AM - edited 2024-05-24 07:57 AM
The format is relatively trivial as object files go, well documented and 40 years or so old.
Tools like SRECORDs can output, modify, etc.
OBJCOPY, OBJDUMP and FROMELF among others can also be used in various forms.
https://github.com/sierrafoxtrot/srecord
https://srecord.sourceforge.net/
2024-05-24 06:59 AM
TMS570 is from Texas Instruments, you might mean SPC570?
Irrespective of this, a hex file in Intel format without address information is quite pointless, as it can consist of sections that are loaded at different addresses. For this reason, I am not aware of any ready-to-use tools. However, if you absolutely want the pure data, you could use external tools to remove the header with colon, record length and address, also the checksum byte at the end.
Hope that helps?
Regards
/Peter
2024-05-24 07:02 AM
Hi,
yes sorry SPC570 :(
TMS570 is the other microcontroller that has to be donwload the code into SPC570 and for
that reason I need a pure data because the other software still know where it must donwload the code.
Which external tool can I use for that?
Thanks
Fabio
2024-05-24 07:07 AM
A simple text editor with a macro function, such as Notepad++, can do this without any problems.
Regards
/Peter
2024-05-24 07:10 AM
ok thanks
it should be better an external tool called directly by the toolchain or
integrated into to have the nude data file coming form the toolchain automatically
Fabio
2024-05-24 07:55 AM - edited 2024-05-24 07:57 AM
The format is relatively trivial as object files go, well documented and 40 years or so old.
Tools like SRECORDs can output, modify, etc.
OBJCOPY, OBJDUMP and FROMELF among others can also be used in various forms.
https://github.com/sierrafoxtrot/srecord
https://srecord.sourceforge.net/
2024-05-27 12:12 AM
Hi Tesla,
many thanks .... I will try
Fabio