cancel
Showing results for 
Search instead for 
Did you mean: 

I am using STEVAL-ILD004V2 source code for dimmer. I can compile using my ST Develop using STM8 cosmic compiler when no change. But, when I change MCU to STM8S103F3P. I will have this compile problem below. Regards, Walter

WMaca
Associate II

----------- Project ild004v2 - STM8 Cosmic - Configuration Debug -------------

Compiling watchdog.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ watchdog.c

watchdog.c:

Compiling timer_config.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ timer_config.c

timer_config.c:

Compiling stm8_interrupt_vector.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ stm8_interrupt_vector.c

stm8_interrupt_vector.c:

Compiling sc_protec.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ sc_protec.c

sc_protec.c:

Compiling reset.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ reset.c

reset.c:

Compiling pb_reading.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ pb_reading.c

pb_reading.c:

Compiling main.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ main.c

main.c:

Compiling halt_mode.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ halt_mode.c

halt_mode.c:

Compiling gpio_config.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ gpio_config.c

gpio_config.c:

Compiling freq_detect.c...

cxstm8 +modsl0 +debug -pxp -no -pp -l -i"x:\bu_thyristor_triac_rectifier\04_ase_thyristor_triac\promotion tools\digital dimmer with viper_steval-ild004v2\05_software\steval-ild004v2 software v1.0\steval-ild004v2 software v1.0\ild004v2" -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -clDebug\ -coDebug\ freq_detect.c

freq_detect.c:

Assembling smart_reset.s...

castm8 -xx +lDebug\smart_reset.ls -i"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Hstm8" -oDebug\smart_reset.o smart_reset.s

Running Linker

clnk -l"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Lib" -o Debug\ild004v2.sm8 -mDebug\ild004v2.map Debug\ild004v2.lkf 

#error clnk Debug\ild004v2.lkf:1 segment .bss size overflow (38)

 The command: "clnk -l"C:\Program Files\COSMIC\FSE_Compilers\CXSTM8\Lib" -o Debug\ild004v2.sm8 -mDebug\ild004v2.map Debug\ild004v2.lkf " has failed, the returned value is: 1

exit code=1.

ild004v2.elf - 3 error(s), 0 warning(s)

3 REPLIES 3
AvaTar
Lead

> #error clnk Debug\ild004v2.lkf:1 segment .bss size overflow (38)

Code / data size overflow.

Try optimization, a better toolchain/compiler, or a MCU with more memory resources.

Reading and interpreting toolchain console output is a crucial skill - consult compile help pages and tutorials.

WMaca
Associate II

Thanks, originally working in STM8S103F2P. But when I change to bigger ram chip STM8S103F3P, already have the problem.

Difficult to assess without code.

I would check the map file, to see what happens, i.e. what objects() cause the problem.

".bss" is usually for non-initialized objects (variables).

This section could be declared smaller on the second MCU, even with greater RAM size.

I't s several years ago when I last did a project for a STM8 ...