when I add some code for timer function and the adding code is the following picture ,anther part is new a isr function ftmTimerISR。
the DS32 compiler report the following errors
Executing target #19 flash_partitioning_s32k116.elf
Invoking: Standard S32DS C Linker
arm-none-eabi-gcc -o "flash_partitioning_s32k116.elf" "@flash_partitioning_s32k116.args"
c:/nxp/s32ds_arm_v2018.r1/cross_tools/gcc-arm-none-eabi-4_9/bin/../lib/gcc/arm-none-eabi/4.9.3/../../../../arm-none-eabi/bin/ld.exe: flash_partitioning_s32k116.elf section `.text' will not fit in region `m_text'
c:/nxp/s32ds_arm_v2018.r1/cross_tools/gcc-arm-none-eabi-4_9/bin/../lib/gcc/arm-none-eabi/4.9.3/../../../../arm-none-eabi/bin/ld.exe: section .data loaded at [200020c0,200025f3] overlaps section .text loaded at [200000c0,20002717]
c:/nxp/s32ds_arm_v2018.r1/cross_tools/gcc-arm-none-eabi-4_9/bin/../lib/gcc/arm-none-eabi/4.9.3/../../../../arm-none-eabi/bin/ld.exe: region `m_text' overflowed by 1716 bytes
collect2.exe: error: ld returned 1 exit status
make: *** [makefile:82: flash_partitioning_s32k116.elf] Error 1
Hi,
If you didn't modify m_text section size in linker file, your program is simple too big to fit in flash memory. You can try to turn on optimization for size or write your code more efficiently.
Jiri
Hi @jiri_kral ,
I tried the solution you suggested, but it seems not to be working. Do you have any other suggestion? The error that I am getting is the one shown below:
Thanks in advance!
Hi,
Looks, that linker can't find ammclib. Please make sure that you added correct path to ammclib into project properties:
Jiri
Hi @jiri_kral , I truly appreciate your fast response.
I had that Library space empty, so, I copied this path:
Into the space you pointed out. So, now it looks like this:
Then pressed "Built", but I am still getting the same error.
Note: What's written in the upper space (below Libraries (-l)) was there already.
Thanks again!
Hi,
it is possible share your project? I'll look at it.
Jiri
Hi @jiri_kral ,
I went and looked for the .a file directly into the simulink files and copied the path and worked (not the one that was in linked resources). I had some issues after that but I was capable of fixing the issue.
Thanks for your help!