Browse Source

📌 Ask for PlatformIO 6.1.1 or newer (#24435)

Scott Lahteine 2 years ago
parent
commit
068624a726
No account linked to committer's email address

+ 7
- 2
buildroot/share/PlatformIO/scripts/pioutil.py View File

@@ -4,5 +4,10 @@
4 4
 
5 5
 # Make sure 'vscode init' is not the current command
6 6
 def is_pio_build():
7
-	from SCons.Script import COMMAND_LINE_TARGETS
8
-	return "idedata" not in COMMAND_LINE_TARGETS and "_idedata" not in COMMAND_LINE_TARGETS
7
+	from SCons.Script import DefaultEnvironment
8
+	env = DefaultEnvironment()
9
+	return not env.IsIntegrationDump()
10
+
11
+def get_pio_version():
12
+	from platformio import util
13
+	return util.pioversion_to_intstr()

+ 5
- 0
buildroot/share/PlatformIO/scripts/preflight-checks.py View File

@@ -52,6 +52,11 @@ if pioutil.is_pio_build():
52 52
 		if 'PIOENV' not in env:
53 53
 			raise SystemExit("Error: PIOENV is not defined. This script is intended to be used with PlatformIO")
54 54
 
55
+		# Require PlatformIO 6.1.1 or later
56
+		vers = pioutil.get_pio_version()
57
+		if vers < [6, 1, 1]:
58
+			raise SystemExit("Error: Marlin requires PlatformIO >= 6.1.1. Use 'pio upgrade' to get a newer version.")
59
+
55 60
 		if 'MARLIN_FEATURES' not in env:
56 61
 			raise SystemExit("Error: this script should be used after common Marlin scripts")
57 62
 

+ 7
- 6
ini/esp32.ini View File

@@ -20,6 +20,7 @@ build_src_filter = ${common.default_src_filter} +<src/HAL/ESP32>
20 20
 lib_ignore       = NativeEthernet
21 21
 upload_speed     = 500000
22 22
 monitor_speed    = 250000
23
+monitor_filters  = colorize, time, send_on_enter, log2file, esp32_exception_decoder
23 24
 #upload_port     = marlinesp.local
24 25
 #board_build.flash_mode = qio
25 26
 
@@ -28,13 +29,13 @@ extends                = env:esp32
28 29
 board_build.partitions = default_16MB.csv
29 30
 
30 31
 [env:PANDA]
31
-extends       = env:esp32
32
-build_flags   = ${env:esp32.build_flags} -DUSE_ESP32_EXIO -DUSE_ESP32_TASK_WDT
33
-lib_deps      = ${common.lib_deps}
34
-  SoftwareSerialEsp32
32
+extends                = env:esp32
33
+build_flags            = ${env:esp32.build_flags} -DUSE_ESP32_EXIO -DUSE_ESP32_TASK_WDT
34
+lib_deps               = ${common.lib_deps}
35
+                         SoftwareSerialEsp32
35 36
 board_build.partitions = Marlin/src/HAL/ESP32/esp32.csv
36
-upload_speed  = 115200
37
-monitor_speed = 115200
37
+upload_speed           = 115200
38
+monitor_speed          = 115200
38 39
 
39 40
 [env:mks_tinybee]
40 41
 extends                = env:esp32

+ 3
- 10
platformio.ini View File

@@ -267,17 +267,10 @@ framework         = arduino
267 267
 extra_scripts     = ${common.extra_scripts}
268 268
 build_flags       = ${common.build_flags}
269 269
 lib_deps          = ${common.lib_deps}
270
-platform_packages = platformio/tool-dfuutil@^1.11.0
271 270
 monitor_speed     = 250000
272
-monitor_flags     =
273
-  --quiet
274
-  --echo
275
-  --eol
276
-    LF
277
-  --filter
278
-    colorize
279
-  --filter
280
-    time
271
+monitor_eol       = LF
272
+monitor_echo      = yes
273
+monitor_filters   = colorize, time, send_on_enter, log2file
281 274
 
282 275
 #
283 276
 # Just print the dependency tree

Loading…
Cancel
Save