ソースを参照

Revert "Firmware upload…" (#24229)

ellensp 2年前
コミット
639b1f64c6
コミッターのメールアドレスに関連付けられたアカウントが存在しません
2個のファイルの変更0行の追加59行の削除
  1. 0
    52
      buildroot/share/PlatformIO/scripts/upload_prompt_extra_script.py
  2. 0
    7
      ini/stm32f1.ini

+ 0
- 52
buildroot/share/PlatformIO/scripts/upload_prompt_extra_script.py ファイルの表示

@@ -1,52 +0,0 @@
1
-#
2
-# upload_prompt_extra_script.py
3
-# set the output_port
4
-#
5
-from __future__ import print_function
6
-
7
-has_tkinter = False
8
-try:
9
-	import sys
10
-	if sys.version_info[0] < 3:
11
-		import Tkinter as tk
12
-		import tkFileDialog as fileDialog
13
-		from Tkinter import Tk
14
-	else:
15
-		import tkinter as tk
16
-		from tkinter import Tk
17
-		from tkinter import filedialog as fileDialog
18
-	has_tkinter = True
19
-except:
20
-	pass
21
-
22
-import pioutil
23
-if has_tkinter and pioutil.is_pio_build():
24
-
25
-	Import("env")
26
-
27
-	def print_error(e):
28
-		print('\nUnable to find destination disk (%s)\n' %( e ) )
29
-
30
-	def before_upload(source, target, env):
31
-		#
32
-		# Find a disk for upload
33
-		#
34
-		upload_disk = ''
35
-
36
-		root = Tk() # pointing root to Tk() to use it as Tk() in program.
37
-		root.withdraw() # Hides small tkinter window.
38
-
39
-		root.attributes('-topmost', True) # Opened windows will be active. above all windows despite of selection.
40
-
41
-		upload_disk = fileDialog.askdirectory(title="Select the root of your SDCARD") # Returns opened path as str
42
-		if not upload_disk:
43
-			print_error('Canceled')
44
-			return
45
-		else:
46
-			env.Replace(
47
-				UPLOAD_FLAGS="-P$UPLOAD_PORT"
48
-			)
49
-			env.Replace(UPLOAD_PORT=upload_disk)
50
-			print('\nUpload disk: ', upload_disk, '\n')
51
-
52
-	env.AddPreAction("upload", before_upload)

+ 0
- 7
ini/stm32f1.ini ファイルの表示

@@ -148,10 +148,6 @@ upload_protocol = custom
148 148
 [env:STM32F103RE_creality]
149 149
 extends = STM32F103Rx_creality
150 150
 board   = genericSTM32F103RE
151
-extra_scripts  = ${STM32F103Rx_creality.extra_scripts}
152
-                 buildroot/share/PlatformIO/scripts/upload_prompt_extra_script.py
153
-upload_protocol = mbed
154
-
155 151
 
156 152
 [env:STM32F103RE_creality_xfer]
157 153
 extends = STM32F103Rx_creality_xfer
@@ -168,9 +164,6 @@ board_upload.offset_address = 0x08010000
168 164
 [env:STM32F103RC_creality]
169 165
 extends = STM32F103Rx_creality
170 166
 board   = genericSTM32F103RC
171
-extra_scripts  = ${STM32F103Rx_creality.extra_scripts}
172
-                 buildroot/share/PlatformIO/scripts/upload_prompt_extra_script.py
173
-upload_protocol = mbed
174 167
 
175 168
 [env:STM32F103RC_creality_xfer]
176 169
 extends = STM32F103Rx_creality_xfer

読み込み中…
キャンセル
保存