qmk_firmware icon indicating copy to clipboard operation
qmk_firmware copied to clipboard

[Bug] i can't flash qmk firmware to stm32f103c6t6a

Open izbj opened this issue 2 years ago • 4 comments

Opening DFU capable USB device... Device ID 1eaf:0003 Device DFU version 0110 Claiming USB DFU Interface... Setting Alternate Interface #2 ... Determining device status... DFU state(5) = dfuDNLOAD-IDLE, status(0) = No error condition is present Aborting previous incomplete transfer Determining device status... DFU state(2) = dfuIDLE, status(0) = No error condition is present DFU mode device DFU version 0110 Device returned transfer size 1024 Copying data from PC to DFU device Download [=========================] 100% 21192 bytes Download done. DFU state(8) = dfuMANIFEST-WAIT-RESET, status(0) = No error condition is present Resetting USB to switch back to runtime mode error resetting after download (LIBUSB_ERROR_TIMEOUT) Done! gmake[1]: *** [platforms/chibios/flash.mk:98: flash] Error 74 gmake: *** [Makefile:413: stm32test:default:flash] Error 1 Make finished with errors

it always has a error when i flash qmk firmware to stm32f103c6t6a

the stm32duino bootloader was flashed in stm32f103c6t6a alread

izbj avatar Apr 21 '22 15:04 izbj

i am M1 mac i don't know if it about M1

izbj avatar Apr 21 '22 15:04 izbj

Download [=========================] 100% 21192 bytes
Download done.
DFU state(8) = dfuMANIFEST-WAIT-RESET, status(0) = No error condition is present

Flash was successful, however its likely you have not applied the additional changes listed in #15297.

zvecr avatar Apr 21 '22 18:04 zvecr

Download [=========================] 100% 21192 bytes
Download done.
DFU state(8) = dfuMANIFEST-WAIT-RESET, status(0) = No error condition is present

Flash was successful, however its likely you have not applied the additional changes listed in #15297.

Compiling: platforms/chibios/boards/STM32_F103_STM32DUINO/board/board.c platforms/chibios/boards/STM32_F103_STM32DUINO/board/board.c:34:3: error: extra brace group at end of initializer {VAL_GPIOEODR, VAL_GPIOECRL, VAL_GPIOECRH}, ^ platforms/chibios/boards/STM32_F103_STM32DUINO/board/board.c:34:3: note: (near initialization for 'pal_default_config') platforms/chibios/boards/STM32_F103_STM32DUINO/board/board.c:34:3: error: excess elements in struct initializer [-Werror] platforms/chibios/boards/STM32_F103_STM32DUINO/board/board.c:34:3: note: (near initialization for 'pal_default_config') cc1: all warnings being treated as errors [ERRORS] | | | gmake[1]: *** [builddefs/common_rules.mk:456: .build/obj_stm32test/platforms/chibios/boards/STM32_F103_STM32DUINO/board/board.o] Error 1 gmake: *** [Makefile:413: stm32test:default] Error 1 Make finished with errors

Ⅰ update my keyboard file from #15297 ,but it has a new error

izbj avatar Apr 22 '22 14:04 izbj

Can you test the STM32F103C6 support code from #17853?

Note that you need to use at least board.h and the bootloader-related section of rules.mk from the handwired/onekey/bluepill_f103c6 keyboard in your custom code, because the bootloader parameters also specify MCU_LDSCRIPT = STM32F103x6_stm32duino_bootloader. Also use EEPROM_DRIVER = transient for now, because the proper firmware size check which takes the EEPROM backing store into account is not implemented yet, and with only 24 KiB of flash available for QMK it would be easy to get the backing store overlapping the firmware code.

sigprof avatar Jul 30 '22 18:07 sigprof

Closing as #17853 added tested examples.

zvecr avatar Nov 14 '23 02:11 zvecr