130
130
"esp8266" , "esp32" , "metro_m4" , "trinket_m0" ),
131
131
"arcada_platforms" : ("pybadge" , "pygamer" , "hallowing_m4" ,
132
132
"cpb" , "cpx_ada" ),
133
+ "wippersnapper_platforms" : ("metro_m4_airliftlite_tinyusb" , "pyportal_tinyusb" ),
133
134
"rp2040_platforms" : ("pico_rp2040" , "feather_rp2040" )
134
135
}
135
136
@@ -227,7 +228,8 @@ def generate_uf2(example_path):
227
228
return False
228
229
# Convert .hex to .uf2
229
230
family_id = ALL_PLATFORMS [platform ][1 ]
230
- input_file = glob1 (os .path .join (example_path , "build/*/*.hex" ))
231
+ cli_build_path = "build/*.*." + fqbn .split (':' )[2 ] + "/*.hex"
232
+ input_file = glob1 (os .path .join (example_path , cli_build_path ))
231
233
output_file = os .path .splitext (input_file )[0 ] + ".uf2"
232
234
cmd = ['python3' , 'uf2conv.py' , input_file , '-c' , '-f' , family_id , '-o' , output_file ]
233
235
proc = subprocess .Popen (cmd , stdout = subprocess .PIPE , stderr = subprocess .PIPE )
@@ -249,9 +251,11 @@ def generate_uf2(example_path):
249
251
250
252
# expand groups:
251
253
for arg in sys .argv [1 :]:
252
- platform = ALL_PLATFORMS .get (arg , None )[0 ]
254
+ platform = ALL_PLATFORMS .get (arg , None )
255
+ print ("254 platform " , platform )
253
256
if isinstance (platform , str ):
254
- platforms .append (arg )
257
+ print ('Platform append: ' , platform )
258
+ platforms .append (platform )
255
259
elif isinstance (platform , collections .abc .Iterable ):
256
260
for p in platform :
257
261
platforms .append (p )
0 commit comments