Преглед изворни кода

STM32F1: Remove extra py imports (#15898)

Tanguy Pruvot пре 5 година
родитељ
комит
94e18ce324

+ 0
- 2
buildroot/share/PlatformIO/scripts/STM32F103VE_longer.py Прегледај датотеку

17
 
17
 
18
 # Rename ${PROGNAME}.bin and save it as 'project.bin' (No encryption on the Longer3D)
18
 # Rename ${PROGNAME}.bin and save it as 'project.bin' (No encryption on the Longer3D)
19
 def encrypt(source, target, env):
19
 def encrypt(source, target, env):
20
-    import os
21
-
22
     firmware = open(target[0].path, "rb")
20
     firmware = open(target[0].path, "rb")
23
     marlin_alfa = open(target[0].dir.path +'/project.bin', "wb")
21
     marlin_alfa = open(target[0].dir.path +'/project.bin', "wb")
24
     length = os.path.getsize(target[0].path)
22
     length = os.path.getsize(target[0].path)

+ 0
- 2
buildroot/share/PlatformIO/scripts/chitu_crypt.py Прегледај датотеку

113
 
113
 
114
 # Encrypt ${PROGNAME}.bin and save it as 'update.cbd'
114
 # Encrypt ${PROGNAME}.bin and save it as 'update.cbd'
115
 def encrypt(source, target, env):
115
 def encrypt(source, target, env):
116
-    import os
117
-
118
     firmware = open(target[0].path, "rb")
116
     firmware = open(target[0].path, "rb")
119
     update = open(target[0].dir.path +'/update.cbd', "wb")
117
     update = open(target[0].dir.path +'/update.cbd', "wb")
120
     length = os.path.getsize(target[0].path)
118
     length = os.path.getsize(target[0].path)

+ 0
- 2
buildroot/share/PlatformIO/scripts/jgaurora_a5s_a1_with_bootloader.py Прегледај датотеку

16
 
16
 
17
 #append ${PROGNAME}.bin firmware after bootloader and save it as 'jgaurora_firmware.bin'
17
 #append ${PROGNAME}.bin firmware after bootloader and save it as 'jgaurora_firmware.bin'
18
 def addboot(source,target,env):
18
 def addboot(source,target,env):
19
-	import os
20
-
21
 	firmware = open(target[0].path, "rb")
19
 	firmware = open(target[0].path, "rb")
22
 	lengthfirmware = os.path.getsize(target[0].path)
20
 	lengthfirmware = os.path.getsize(target[0].path)
23
 	bootloader_dir = "buildroot/share/PlatformIO/scripts/jgaurora_bootloader.bin"
21
 	bootloader_dir = "buildroot/share/PlatformIO/scripts/jgaurora_bootloader.bin"

+ 0
- 1
buildroot/share/PlatformIO/scripts/mks_robin.py Прегледај датотеку

16
 
16
 
17
 # Encrypt ${PROGNAME}.bin and save it as 'Robin.bin'
17
 # Encrypt ${PROGNAME}.bin and save it as 'Robin.bin'
18
 def encrypt(source, target, env):
18
 def encrypt(source, target, env):
19
-    import os
20
     import sys
19
     import sys
21
 
20
 
22
     key = [0xA3, 0xBD, 0xAD, 0x0D, 0x41, 0x11, 0xBB, 0x8D, 0xDC, 0x80, 0x2D, 0xD0, 0xD2, 0xC4, 0x9B, 0x1E, 0x26, 0xEB, 0xE3, 0x33, 0x4A, 0x15, 0xE4, 0x0A, 0xB3, 0xB1, 0x3C, 0x93, 0xBB, 0xAF, 0xF7, 0x3E]
21
     key = [0xA3, 0xBD, 0xAD, 0x0D, 0x41, 0x11, 0xBB, 0x8D, 0xDC, 0x80, 0x2D, 0xD0, 0xD2, 0xC4, 0x9B, 0x1E, 0x26, 0xEB, 0xE3, 0x33, 0x4A, 0x15, 0xE4, 0x0A, 0xB3, 0xB1, 0x3C, 0x93, 0xBB, 0xAF, 0xF7, 0x3E]

+ 0
- 1
buildroot/share/PlatformIO/scripts/mks_robin_lite.py Прегледај датотеку

17
 
17
 
18
 # Encrypt ${PROGNAME}.bin and save it as 'mksLite.bin'
18
 # Encrypt ${PROGNAME}.bin and save it as 'mksLite.bin'
19
 def encrypt(source, target, env):
19
 def encrypt(source, target, env):
20
-    import os
21
     import sys
20
     import sys
22
 
21
 
23
     key = [0xA3, 0xBD, 0xAD, 0x0D, 0x41, 0x11, 0xBB, 0x8D, 0xDC, 0x80, 0x2D, 0xD0, 0xD2, 0xC4, 0x9B, 0x1E, 0x26, 0xEB, 0xE3, 0x33, 0x4A, 0x15, 0xE4, 0x0A, 0xB3, 0xB1, 0x3C, 0x93, 0xBB, 0xAF, 0xF7, 0x3E]
22
     key = [0xA3, 0xBD, 0xAD, 0x0D, 0x41, 0x11, 0xBB, 0x8D, 0xDC, 0x80, 0x2D, 0xD0, 0xD2, 0xC4, 0x9B, 0x1E, 0x26, 0xEB, 0xE3, 0x33, 0x4A, 0x15, 0xE4, 0x0A, 0xB3, 0xB1, 0x3C, 0x93, 0xBB, 0xAF, 0xF7, 0x3E]

+ 0
- 2
buildroot/share/PlatformIO/scripts/mks_robin_mini.py Прегледај датотеку

1
 import os
1
 import os
2
-
3
 Import("env")
2
 Import("env")
4
 
3
 
5
 # Relocate firmware from 0x08000000 to 0x08007000
4
 # Relocate firmware from 0x08000000 to 0x08007000
18
 
17
 
19
 # Encrypt ${PROGNAME}.bin and save it as 'Robin_mini.bin'
18
 # Encrypt ${PROGNAME}.bin and save it as 'Robin_mini.bin'
20
 def encrypt(source, target, env):
19
 def encrypt(source, target, env):
21
-    import os
22
     import sys
20
     import sys
23
 
21
 
24
     key = [0xA3, 0xBD, 0xAD, 0x0D, 0x41, 0x11, 0xBB, 0x8D, 0xDC, 0x80, 0x2D, 0xD0, 0xD2, 0xC4, 0x9B, 0x1E, 0x26, 0xEB, 0xE3, 0x33, 0x4A, 0x15, 0xE4, 0x0A, 0xB3, 0xB1, 0x3C, 0x93, 0xBB, 0xAF, 0xF7, 0x3E]
22
     key = [0xA3, 0xBD, 0xAD, 0x0D, 0x41, 0x11, 0xBB, 0x8D, 0xDC, 0x80, 0x2D, 0xD0, 0xD2, 0xC4, 0x9B, 0x1E, 0x26, 0xEB, 0xE3, 0x33, 0x4A, 0x15, 0xE4, 0x0A, 0xB3, 0xB1, 0x3C, 0x93, 0xBB, 0xAF, 0xF7, 0x3E]

+ 0
- 1
buildroot/share/PlatformIO/scripts/mks_robin_nano.py Прегледај датотеку

17
 
17
 
18
 # Encrypt ${PROGNAME}.bin and save it as 'Robin_nano.bin'
18
 # Encrypt ${PROGNAME}.bin and save it as 'Robin_nano.bin'
19
 def encrypt(source, target, env):
19
 def encrypt(source, target, env):
20
-    import os
21
     import sys
20
     import sys
22
 
21
 
23
     key = [0xA3, 0xBD, 0xAD, 0x0D, 0x41, 0x11, 0xBB, 0x8D, 0xDC, 0x80, 0x2D, 0xD0, 0xD2, 0xC4, 0x9B, 0x1E, 0x26, 0xEB, 0xE3, 0x33, 0x4A, 0x15, 0xE4, 0x0A, 0xB3, 0xB1, 0x3C, 0x93, 0xBB, 0xAF, 0xF7, 0x3E]
22
     key = [0xA3, 0xBD, 0xAD, 0x0D, 0x41, 0x11, 0xBB, 0x8D, 0xDC, 0x80, 0x2D, 0xD0, 0xD2, 0xC4, 0x9B, 0x1E, 0x26, 0xEB, 0xE3, 0x33, 0x4A, 0x15, 0xE4, 0x0A, 0xB3, 0xB1, 0x3C, 0x93, 0xBB, 0xAF, 0xF7, 0x3E]

Loading…
Откажи
Сачувај