Skip to content

Commit 2cfe249

Browse files
lucarin91facchinm
authored andcommitted
feat: add flash to ram for unoq
1 parent 1cd1dd5 commit 2cfe249

File tree

3 files changed

+23
-2
lines changed

3 files changed

+23
-2
lines changed

boards.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
menu.debug=Debug
22
menu.link_mode=Link mode
3+
menu.flash_mode=Flash mode
34

45
##########################################################################################
56

@@ -532,6 +533,11 @@ unoq.menu.link_mode.static=Static
532533
unoq.menu.link_mode.static.build.link_mode=static
533534
unoq.menu.link_mode.static.upload.extension=bin-zsk.bin
534535

536+
unoq.menu.flash_mode.flash=Flash
537+
unoq.menu.flash_mode.flash.openocd_cfg=flash_sketch.cfg
538+
unoq.menu.flash_mode.ram=RAM
539+
unoq.menu.flash_mode.ram.openocd_cfg=flash_sketch_ram.cfg
540+
535541
unoq.build.zephyr_target=arduino_uno_q
536542
unoq.build.zephyr_args=
537543
unoq.build.variant=arduino_uno_q_stm32u585xx

platform.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ tools.remoteocd.path={runtime.tools.remoteocd.path}
269269
tools.remoteocd.cmd=remoteocd
270270
tools.remoteocd.upload.params.verbose=--verbose
271271
tools.remoteocd.upload.params.quiet=
272-
tools.remoteocd.upload.pattern="{path}/{cmd}" upload --adb-path "{runtime.tools.adb.path}/adb" -s "{upload.port.properties.serialNumber}" -f "{build.variant.path}/flash_sketch.cfg" "{upload.verbose}" "{build.path}/{build.project_name}.{upload.extension}"
272+
tools.remoteocd.upload.pattern="{path}/{cmd}" upload --adb-path "{runtime.tools.adb.path}/adb" -s "{upload.port.properties.serialNumber}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" "{build.path}/{build.project_name}.{upload.extension}"
273273

274274
tools.remoteocd.bootloader.params.verbose=--verbose
275275
tools.remoteocd.bootloader.params.quiet=
@@ -283,7 +283,7 @@ tools.remoteocd_network.path={runtime.tools.remoteocd.path}
283283
tools.remoteocd_network.cmd=remoteocd
284284
tools.remoteocd_network.upload.params.verbose=--verbose
285285
tools.remoteocd_network.upload.params.quiet=
286-
tools.remoteocd_network.upload.pattern="{path}/{cmd}" upload -a "{upload.port.address}" --password "{upload.field.password}" -f "{build.variant.path}/flash_sketch.cfg" "{upload.verbose}" "{build.path}/{build.project_name}.{upload.extension}"
286+
tools.remoteocd_network.upload.pattern="{path}/{cmd}" upload -a "{upload.port.address}" --password "{upload.field.password}" -f "{build.variant.path}/{openocd_cfg}" "{upload.verbose}" "{build.path}/{build.project_name}.{upload.extension}"
287287

288288
#
289289
# PYOCD WRAPPER
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
reset_config srst_only srst_push_pull
2+
3+
init
4+
reset
5+
halt
6+
resume
7+
sleep 500
8+
9+
lassign [split [mdw 0x20000000] ":" ] ram base
10+
set base [string trim $base]
11+
puts $base
12+
load_image ${filename} 0x$base bin
13+
sleep 500
14+
resume
15+
shutdown

0 commit comments

Comments
 (0)