Kaynağa Gözat

Fysetc S6 direct DFU upload (#17943)

Eric Ptak 4 yıl önce
ebeveyn
işleme
9d545f1231
No account linked to committer's email address

+ 0
- 22
buildroot/share/PlatformIO/scripts/fysetc_STM32S6.py Dosyayı Görüntüle

@@ -31,25 +31,3 @@ for file_name in os.listdir(source_dir):
31 31
     full_file_name = os.path.join(source_dir, file_name)
32 32
     if os.path.isfile(full_file_name):
33 33
         shutil.copy(full_file_name, variant_dir)
34
-
35
-# Relocate firmware from 0x08000000 to 0x08002000
36
-#env['CPPDEFINES'].remove(("VECT_TAB_ADDR", 134217728))
37
-#env['CPPDEFINES'].append(("VECT_TAB_ADDR", "0x08010000"))
38
-#env.Replace(LDSCRIPT_PATH="buildroot/share/PlatformIO/ldscripts/fysetc_aio_ii.ld")
39
-
40
-# Custom HEX from ELF
41
-env.AddPostAction(
42
-	"$BUILD_DIR/${PROGNAME}.elf",
43
-	env.VerboseAction(" ".join([
44
-				"$OBJCOPY",
45
-				"-O",
46
-				"ihex",
47
-				"$BUILD_DIR/${PROGNAME}.elf",
48
-				"$BUILD_DIR/${PROGNAME}.hex"
49
-			]), "Building $TARGET"))
50
-
51
-# In-line command with arguments
52
-env.Replace(
53
-	UPLOADER=platform.get_package_dir("tool-stm32duino") + '/stm32flash/stm32flash',
54
-	UPLOADCMD='"${UPLOADER}" -v -i rts,-dtr,dtr,-rts -R -b 115200 -g 0x8000000 -w "${BUILD_DIR}/${PROGNAME}.hex" ${UPLOAD_PORT}'
55
-)

+ 2
- 2
platformio.ini Dosyayı Görüntüle

@@ -729,8 +729,8 @@ extra_scripts     = pre:buildroot/share/PlatformIO/scripts/fysetc_STM32S6.py
729 729
 src_filter        = ${common.default_src_filter} +<src/HAL/STM32>
730 730
 lib_ignore        = Arduino-L6470, SoftwareSerial
731 731
 debug_tool        = stlink
732
-#upload_protocol   = stlink
733
-upload_protocol   = serial
732
+upload_protocol   = dfu
733
+upload_command    = dfu-util -a 0 -s 0x08010000:leave -D "$SOURCE"
734 734
 
735 735
 #
736 736
 # STM32F407VET6 with RAMPS-like shield

Loading…
İptal
Kaydet