Good morning
Can someone shed a light on this loader error message?
Linking .pio/build/nucleo_f042k6/firmware.elf
/home/me/PlatformIO/Projects/USB Device/.pio/build/nucleo_f042k6/STM32F042X6.ld.link_script.ld:82 cannot move location counter backwards (from 0000000020000998 to 0000000020000800)
collect2: error: ld returned 1 exit status
*** [.pio/build/nucleo_f042k6/firmware.elf] Error 1
Is the generated code too big?
Which would be strange as the used USBDevice library is specially for the F042K6 platform…
thanks in advance
richard
Sounds like a weird version of an overflow message if maybe the previous linker segment gets to large and then it tries to set the current address to some other value, but that fails. The error message indicates you are 198 bytes beyond something.
Do you have the full project for reproduction?
I suspect it uses just too much RAM…assuming mbed os eats up too much…
Well I have the whole project…can I somehow export it including the installed library?
Just your project folder should be good enough to compile your project, shouldn’t it? A repo on github or google driver upload would be appreciated.
Uploaded the project here: https://drive.google.com/file/d/1xKqnYYf6i0Acml4bbXk5F4HYTOxhHZ0A/view?usp=sharing
The library used is:
{
“__pkg_dir”: “/home/klingler/.platformio/lib/USBDevice”,
“__src_url”: “hg+https://os.mbed.com/users/raghavakumar8/code/USBDevice/”,
“name”: “USBDevice”,
“version”: “33c22b6de512”,
“authors”: [],
“frameworks”: [],
“platforms”: [],
“keywords”: []
}
thanks in advance
richard