cancel
Showing results for 
Search instead for 
Did you mean: 

Error Compiling LoRaWAN_End_Node_DualCoreFreeRTOS Example

Martin.Sergio
Associate III

Hi all,

I'm reading some code and compiling some examples before receive NUCLEO-WL55JC board.

Problems with this Example: [CM0PLUS]

en.stm32cubewl\STM32Cube_FW_WL_V1.0.0\Projects\NUCLEO-WL55JC\Applications\LoRaWAN\LoRaWAN_End_Node_DualCoreFreeRTOS

Consola Error:

c:\st\stm32cubeide_1.2.0\stm32cubeide\plugins\com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.7-2018-q2-update.win32_1.5.0.202011040924\tools\arm-none-eabi\bin\ld.exe: LoRaWAN_End_Node_DualCoreFreeRTOS_CM0PLUS.elf section `.text' will not fit in region `ROM'

c:\st\stm32cubeide_1.2.0\stm32cubeide\plugins\com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.7-2018-q2-update.win32_1.5.0.202011040924\tools\arm-none-eabi\bin\ld.exe: region `ROM' overflowed by 7360 bytes

collect2.exe: error: ld returned 1 exit status

make: *** [makefile:69: LoRaWAN_End_Node_DualCoreFreeRTOS_CM0PLUS.elf] Error 1

"make -j4 all" terminated with exit code 2. Build might be incomplete.

To try to correct this error, I add optimization (-Os) to reduce the size of the CM0PLUS binary to 68KB (seeing it in the .map, since the size of the binary is 400MB ???).

Best Regards,

Sergio

4 REPLIES 4
Frank Hefter
Associate III

No reactions from the developers of this example yet? I have chosen this MCU because of these FreeRTOS examples.

Binaries will be large when there are sparse memory sections in the output object file

The developers of the code generally don't participate here, there are a handful of support staff. Most direct engagement is done via local FAE's

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
PowersOf12
Associate

Well, I have the same Dev board (just arrived and blinks a lot).

My goals are in this order (Note: I am used to NXP Cortex M4 and i.MX CPUs so this may take a bit)

0) Create Dev Environment with STM Tools

1) Compile a Demo

2) Debug Successfully via USB

3) Debug Successfully via Stand Alone J-Link Device

4) Modify code on both cores 'slightly' and recompile and Debug

5) Then do something more meaningful with FreeRTOS and Lora Radio

charles23
Associate III

I had the same problem and found I could solve it in two ways:

(1) Change from the Debug configuration to the Release configuration (Project > Build Configurations > Set Active)

(2) By changing the compiler optimsation to optimise for size (Properties > C/C++ Build > Settings > MCU GCC Compiler > Optimization select -Os)

I had earlier tried to change the debug settings but that made no difference...

I should say that I don't yet have hardware, so I have not tested this, but it builds.

I would like to understand is the effect of the settings changes. It looks like the system auto-generates makefiles in the Debug and Release folders, but I don't see the optimisation or debug flags there.