Processor Expert generate too much code as expected

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Processor Expert generate too much code as expected

Jump to solution
599 Views
gschelotto
Contributor V

Hello,

I'm using KDS v3.2 with KDSK 1.3 and PE. After creating a new project for FRDM-KL03Z I've initialized some PE components as spiCom1, gpio1... as shown in the next screenshot. Then I've just added a while(1) in main.c and the compilation result ends up in almost 14KB for the .text section that means a half of the total flash memory (32KB of the MKL03Z32VFK4).

166047_166047.pngUntitled.png

Can anybody help me to reduce the generated/compiled code? I find it too much for a few components initialization.

Here I attach the whole project for better understanding.

regards,

gaston

Original Attachment has been moved to: testing.zip

Labels (1)
0 Kudos
Reply
1 Solution
441 Views
therealfreegeek
Contributor IV

The problem is less to do with PE and more to do with the KSDK components which are large, this is compounded by  KSDK's usage of ‘assert()’ in the driver code which uses the PRINTF function call which is huge.

Have a look at this https://mcuoneclipse.com/2016/03/09/dealing-with-code-size-in-kinetis-sdk-v2-x-projects/ it refers to KSDK 2 but I guess it is also relevant for 1.3.

View solution in original post

0 Kudos
Reply
1 Reply
442 Views
therealfreegeek
Contributor IV

The problem is less to do with PE and more to do with the KSDK components which are large, this is compounded by  KSDK's usage of ‘assert()’ in the driver code which uses the PRINTF function call which is huge.

Have a look at this https://mcuoneclipse.com/2016/03/09/dealing-with-code-size-in-kinetis-sdk-v2-x-projects/ it refers to KSDK 2 but I guess it is also relevant for 1.3.

0 Kudos
Reply