twrmcf51cn128 empty MQX project spend too much flash memory

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

twrmcf51cn128 empty MQX project spend too much flash memory

ソリューションへジャンプ
495件の閲覧回数
javax
Contributor I

Good day everybody.

I´ve already tested many of the features of MQX and the BSP for  twrMCF51CN128 system. I have got onto this for one month with CodeWarrior 6.3. It has been a good experience.

During this time I have noticed each time I started up a project with MQX and twrMCF51CN128  BSP just sending "Hello World" through serial port ...flash  image get   kind off 30Kb weight...too much for nothing I thing, to make matters even wors MCF51CN128´s got just 128Kb...before starting my powerful application with MQX, I´ve already spent 23% of onchip

flash memory.

 

Any suggestion about how to reduce this initial flash budget will be greatly wellcome.

 

Thanks.

0 件の賞賛
1 解決策
396件の閲覧回数
PetrL
NXP Employee
NXP Employee

Hi,

 

the reason for big footprint for Hello Word application is that there are several IO drivers are enabled(installed) in MQX BSP by default.

 

You can simply switch them off in user_config.h (e.g)

 

#define BSPCFG_ENABLE_GPIODEV    1 -> change to 0 
#define BSPCFG_ENABLE_ADC        1   /* NOTE: Shares wires with I2C1, SPI0 */

 

If you need optimize even more , you have to create your own size optimized drivers (or modify current ones). THe MQX drivers are designed as an generic abstraction for the peripherals modules, portable across various processors making available as much features as possible. There is always trade of between code size and features + portability.

 

PetrL

元の投稿で解決策を見る

0 件の賞賛
1 返信
397件の閲覧回数
PetrL
NXP Employee
NXP Employee

Hi,

 

the reason for big footprint for Hello Word application is that there are several IO drivers are enabled(installed) in MQX BSP by default.

 

You can simply switch them off in user_config.h (e.g)

 

#define BSPCFG_ENABLE_GPIODEV    1 -> change to 0 
#define BSPCFG_ENABLE_ADC        1   /* NOTE: Shares wires with I2C1, SPI0 */

 

If you need optimize even more , you have to create your own size optimized drivers (or modify current ones). THe MQX drivers are designed as an generic abstraction for the peripherals modules, portable across various processors making available as much features as possible. There is always trade of between code size and features + portability.

 

PetrL

0 件の賞賛