Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ASlink-Warning-Undefined Global '_assert_failed' #18

Open
bogdan2011 opened this issue May 28, 2020 · 1 comment
Open

ASlink-Warning-Undefined Global '_assert_failed' #18

bogdan2011 opened this issue May 28, 2020 · 1 comment
Labels
help wanted Extra attention is needed

Comments

@bogdan2011
Copy link

bogdan2011 commented May 28, 2020

I get an error during the build process:

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_adc1'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_awu'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_beep'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_clk'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_exti'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_flash'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_gpio'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_i2c'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_itc'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_iwdg'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_rst'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_spi'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_tim1'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_tim2'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_tim4'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_uart1'

?ASlink-Warning-Undefined Global '_assert_failed' referenced by module 'stm8s_wwdg'
*** [.pio/build/stm8sblue/firmware.elf] Error 1

And the build process fails completely. Might be due to the missing library (.lib) or .rel files not being linked properly.
Source code is basic:

#include <stm8s.h>

int main(void) {
    return 0;
}

platformio.ini file:

; PlatformIO Project Configuration File
;
;   Build options: build flags, source filter
;   Upload options: custom upload port, speed and extra flags
;   Library options: dependencies, extra library storages
;   Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html

[env:stm8sblue]
platform = ststm8
board = stm8sblue
framework = spl

@boeckhoff
Copy link

take a look at the SPL examples, all of them define this method in main.c
void assert_failed(uint8_t* file, uint32_t line)

its needed to compile.

@valeros valeros added the help wanted Extra attention is needed label Mar 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants