Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
User21316
Level 3
Level 3
5 questions asked 5 replies posted First like received

Hi everybody,

I came through a disturbing trick from Memtool.

I noticed that when I was flashing a binary file (generated with ADS and Tasking compiler) to my TC322, Memtool was adding a few bytes (~12) at the starting address defined in my lsl file.

The original binary file has its first data at starting address + 0x20. A memory dump after reflashing shows that there are those additional bytes coming from no where.

I noticed that while developping a bootloader. If I don't add those bytes to my Application bin file, the bootloader won't jump properly to the application.

Does anybody know what those bytes are exactly and if there is something to do (in the lsl file?) to have them properly included at bluid time?

 

Regards,

Benoit

0 Likes
1 Solution
User21316
Level 3
Level 3
5 questions asked 5 replies posted First like received

Good morning,

I solved my problem, and it was completely due to my mistake.

The hex file generated by the linker had some data in the 0x80000000 address range. When you import the file in Memtool, those data are automatically translated to the 0xA0000000 range.

When I noticed those "missing bytes", I looked for them in the hex file in the 0x80000000 range. I failed to notice a small quantity of data at the end of the file that where in the 0xA0000000 range.

So now my bootloader copies both ranges, and it works just fine.

Thanks for the help.

Regards,

Benoit

View solution in original post

0 Likes
7 Replies
Di_W
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 100 likes received

Hi benoit,

Could you please share the .lsl file? Thanks.

 

dw

0 Likes
lock attach
Attachments are accessible only for community members.
User21316
Level 3
Level 3
5 questions asked 5 replies posted First like received

Good morning,

Here is the lsl file as requested. Hope it can help. Needed to put it in a zip file to be able to upload it.

Regards,

Benoit

0 Likes
lock attach
Attachments are accessible only for community members.
Di_W
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 100 likes received

dw_0-1652776187898.png

 

Hi,

I have checked SMU_Reset_Alarm_1_KIT_TC397_TFT.elf and showed above, could you please check if your .elf file is same? Could you find 0x0c byte in .elf file?

dw

 

0 Likes
User21316
Level 3
Level 3
5 questions asked 5 replies posted First like received

Good morning,

I solved my problem, and it was completely due to my mistake.

The hex file generated by the linker had some data in the 0x80000000 address range. When you import the file in Memtool, those data are automatically translated to the 0xA0000000 range.

When I noticed those "missing bytes", I looked for them in the hex file in the 0x80000000 range. I failed to notice a small quantity of data at the end of the file that where in the 0xA0000000 range.

So now my bootloader copies both ranges, and it works just fine.

Thanks for the help.

Regards,

Benoit

0 Likes

Hi

What version of the memtool are you using? I rememeber I had some issue at the beginning of my aurix experience (:-D) because memtool was returning a blocking error if my map was referred to the 0x80000000 address

0 Likes

I'm using Memtool 5 v2021.05

Di_W
Moderator
Moderator
Moderator
1000 replies posted 250 solutions authored 100 likes received

Great. You are welcome.

0 Likes