HALMX project templates with Codeblocks

Development of new Cores using the STMCubeMX and HAL
User avatar
Pito
Posts: 1529
Joined: Sat Mar 26, 2016 3:26 pm
Location: Rapa Nui

Re: HALMX project templates with Codeblocks

Post by Pito » Tue Aug 09, 2016 2:51 pm

I've taken your latest cbp-halmx, placed in hardware folder (IDE 1.6.10, Win7).
Board F103CB_BluePill chosen, your blink demo above.
While linking I get:

Code: Select all

Linking everything together...
..
C:\Users\pito\MyCode\Arduino\hardware\cbp-halmx\stm32\cores\stm32hal/main.cpp:31: multiple definition of `main'
..
Pukao Hats Cleaning Services Ltd.

User avatar
Slammer
Posts: 245
Joined: Tue Mar 01, 2016 10:35 pm
Location: Athens, Greece

Re: HALMX project templates with Codeblocks

Post by Slammer » Tue Aug 09, 2016 7:38 pm

Pull the latest sources, I tested every example, except Digital2 (needs definition of a BUTTON) on BluePill
In adruino IDE use only the examples from Libraries folder (Examples>CBP_HALMX_EXAMPLES>) not the sources from test....

User avatar
Pito
Posts: 1529
Joined: Sat Mar 26, 2016 3:26 pm
Location: Rapa Nui

Re: HALMX project templates with Codeblocks

Post by Pito » Tue Aug 09, 2016 8:06 pm

Ok understood..
FYI - getting a lot of warnings eg with Blink2

Code: Select all

Linking everything together...
"C:\Users\pito\AppData\Local\Arduino15\packages\arduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-gcc"  "-LC:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp" -Os -Wl,--gc-sections -save-temps  "-Tstm32f103xb.ld" "-Wl,-Map,C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp/Blink2.ino.map" --specs=nano.specs -mcpu=cortex-m3 -msoft-float -mfix-cortex-m3-ldrd -mthumb -Os -nostdlib -Wl,--cref -Wl,--check-sections -Wl,--gc-sections -Wl,--unresolved-symbols=report-all -Wl,--warn-common -Wl,--warn-section-align -Wl,-static "-LC:\Users\pito\MyCode\Arduino\hardware\cbp-halmx\stm32\system/lib" "-LC:\Users\pito\MyCode\Arduino\hardware\cbp-halmx\stm32\system/ld" -o "C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp/Blink2.ino.elf" "C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp\sketch\Blink2.ino.cpp.o" "C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp\core\rcc.c.o" "C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp\core\usart.c.o" "C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp\core\variant.cpp.o" -Wl,-whole-archive "C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp/core\core.a" -lhal-f103xb-8m -Wl,-no-whole-archive -lstdc++ -lsupc++ -lm -lgcc -lc -lnosys
c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .vfp11_veneer by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .v4_bx by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .iplt by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .rel.dyn by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .vfp11_veneer by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .v4_bx by 2 bytes

"C:\Users\pito\AppData\Local\Arduino15\packages\arduino\tools\arm-none-eabi-gcc\4.8.3-2014q1/bin/arm-none-eabi-objcopy" -O binary  "C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp/Blink2.ino.elf" "C:\Users\pito\AppData\Local\Temp\buildb289e2be8bfe67184059a3c0081fb0d2.tmp/Blink2.ino.bin"
c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .iplt by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .rel.dyn by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .vfp11_veneer by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .v4_bx by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .iplt by 2 bytes

c:/users/pito/appdata/local/arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/../lib/gcc/arm-none-eabi/4.8.3/../../../../arm-none-eabi/bin/ld.exe: warning: changing start of section .rel.dyn by 2 bytes


Sketch uses 3,158 bytes (2%) of program storage space. Maximum is 131,072 bytes.
Global variables use 24 bytes of dynamic memory.
Pukao Hats Cleaning Services Ltd.

User avatar
Slammer
Posts: 245
Joined: Tue Mar 01, 2016 10:35 pm
Location: Athens, Greece

Re: HALMX project templates with Codeblocks

Post by Slammer » Tue Aug 09, 2016 8:12 pm

These warnings are harmless, normally the arduino building system ignores them by setting the appropriate -W flag.

Post Reply