mirror of https://github.com/arendst/Tasmota.git
fix 4MB PIO script upload regression
This commit is contained in:
parent
80617e96e1
commit
222b47627f
|
@ -29,6 +29,8 @@ if "upload" in COMMAND_LINE_TARGETS:
|
||||||
old_maximum_size = env.BoardConfig().get("upload.maximum_size")
|
old_maximum_size = env.BoardConfig().get("upload.maximum_size")
|
||||||
new_maximum_size = int(size.split("MB")[0]) * 0x100000
|
new_maximum_size = int(size.split("MB")[0]) * 0x100000
|
||||||
|
|
||||||
|
if new_maximum_size > old_maximum_size:
|
||||||
|
|
||||||
extra_flags = env.BoardConfig().get("build.extra_flags").split(" ")
|
extra_flags = env.BoardConfig().get("build.extra_flags").split(" ")
|
||||||
new_flags = ""
|
new_flags = ""
|
||||||
for flag in extra_flags:
|
for flag in extra_flags:
|
||||||
|
|
|
@ -74,10 +74,11 @@ def patch_partitions_bin(size_string):
|
||||||
def esp32_detect_flashsize():
|
def esp32_detect_flashsize():
|
||||||
if not "upload" in COMMAND_LINE_TARGETS:
|
if not "upload" in COMMAND_LINE_TARGETS:
|
||||||
return "4MB",False
|
return "4MB",False
|
||||||
try:
|
size = env.get("TASMOTA_flash_size")
|
||||||
return env.get("TASMOTA_flash_size"),True
|
if size == None:
|
||||||
except:
|
|
||||||
return "4MB",False
|
return "4MB",False
|
||||||
|
else:
|
||||||
|
return size,True
|
||||||
|
|
||||||
def esp32_create_chip_string(chip):
|
def esp32_create_chip_string(chip):
|
||||||
tasmota_platform = env.subst("$BUILD_DIR").split(os.path.sep)[-1]
|
tasmota_platform = env.subst("$BUILD_DIR").split(os.path.sep)[-1]
|
||||||
|
|
Loading…
Reference in New Issue