cancel
Showing results for 
Search instead for 
Did you mean: 

How to flash stm8 with ST-Link2 in Arduino IDE?

MexicoCat
Associate

How to flash stm8 with ST-Link2 in Arduino IDE? I tried to install Sduino for Arduino IDE 1.8.16 on Mac os. When I click on the firmware button, I get the error An error occurred while uploading the sketch. How to fix this?

Error:

Arduino: 1.8.16 (Mac OS X), Board: "STM8S103F3 Breakout Board"

/Users/artem_koval/Library/Arduino15/packages/sduino/tools/sdcc/build.11242/bin/sdcc sketch/Blink.ino.cpp preproc/ctags_target_for_gcc_minus_e.cpp re12 -c -Ddouble=float -DUSE_STDINT -D__PROG_TYPES_COMPAT__ -E -MC -mstm8 -DSTM8S103 -DF_CPU=16000000L -DARDUINO=10816 -DARDUINO_STM8S_BLUE -DARDUINO_ARCH_STM8 -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/cores/sduino -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/variants/standard -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/STM8S_StdPeriph_Driver/inc -I/Users/artem_koval/Library/Arduino15/packages/sduino/tools/sdcc/build.11242/share/sdcc/include
Mark re12:/Users/artem_koval/Library/Arduino15/packages/sduino/tools/sdcc/build.11242/bin/sdcc -c -Ddouble=float -DUSE_STDINT -D__PROG_TYPES_COMPAT__ -E -MC -mstm8 -DSTM8S103 -DF_CPU=16000000L -DARDUINO=10816 -DARDUINO_STM8S_BLUE -DARDUINO_ARCH_STM8 -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/cores/sduino -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/variants/standard -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/STM8S_StdPeriph_Driver/inc -I/Users/artem_koval/Library/Arduino15/packages/sduino/tools/sdcc/build.11242/share/sdcc/include sketch/Blink.ino.cpp -o preproc/ctags_target_for_gcc_minus_e.cpp
cpp gefunden
/Users/artem_koval/Library/Arduino15/packages/sduino/tools/sdcc/build.11242/bin/sdcc sketch/Blink.ino.cpp sketch/Blink.ino.cpp.o re2 -MMD -c -Ddouble=float -DUSE_STDINT -D__PROG_TYPES_COMPAT__ --less-pedantic -mstm8 -DSTM8S103 -DF_CPU=16000000L -DARDUINO=10816 -DARDUINO_STM8S_BLUE -DARDUINO_ARCH_STM8 -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/cores/sduino -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/variants/standard -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/STM8S_StdPeriph_Driver/inc -I/Users/artem_koval/Library/Arduino15/packages/sduino/tools/sdcc/build.11242/share/sdcc/include
Mark re2:/Users/artem_koval/Library/Arduino15/packages/sduino/tools/sdcc/build.11242/bin/sdcc -MMD -c -Ddouble=float -DUSE_STDINT -D__PROG_TYPES_COMPAT__ --less-pedantic -mstm8 -DSTM8S103 -DF_CPU=16000000L -DARDUINO=10816 -DARDUINO_STM8S_BLUE -DARDUINO_ARCH_STM8 -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/cores/sduino -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/variants/standard -I/Users/artem_koval/Library/Arduino15/packages/sduino/hardware/stm8/0.5.0/STM8S_StdPeriph_Driver/inc -I/Users/artem_koval/Library/Arduino15/packages/sduino/tools/sdcc/build.11242/share/sdcc/include sketch/Blink.ino.cpp -o sketch/Blink.ino.cpp.o
cpp gefunden
Sketch uses 1693 bytes (20%) of program storage space. Maximum is 8192 bytes.
Global variables use 72 bytes (7%) of dynamic memory, leaving 952 bytes for local variables. Maximum is 1024 bytes.
dyld[12769]: Library not loaded: '/opt/local/lib/libusb-1.0.0.dylib'
Referenced from: '/Users/artem_koval/Library/Arduino15/packages/sduino/tools/STM8Tools/2019.02.05/macosx/stm8flash'
Reason: tried: '/opt/local/lib/libusb-1.0.0.dylib' (no such file), '/usr/local/lib/libusb-1.0.0.dylib' (no such file), '/usr/lib/libusb-1.0.0.dylib' (no such file)
An error occurred while uploading the sketch


This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

1 REPLY 1
Issamos
Lead II

Hello @MexicoCat 

Those two tutorials may help you solving that issue.

Best regards.

II