Skip to content

Commit 482ff75

Browse files
boards: add stm32wle5jc to known boards
This adds the stm32wle5jc chip used in the seeed_studio_lora-E5-HF dev board to tockloader's known board list. Communication intended to occur using stlink over openocd.
1 parent a960f9a commit 482ff75

3 files changed

Lines changed: 20 additions & 0 deletions

File tree

tockloader/board_interface.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -317,6 +317,17 @@ class BoardInterface:
317317
"no_attribute_table": True,
318318
"linkserver": {"device": "LPC55S69"},
319319
},
320+
"stm32wle5jc": {
321+
"description": "Seeed Studio LoRa-E5 board based on the STM32WLE5JC SoC",
322+
"arch": "cortex-m4",
323+
"page_size": 2048,
324+
"no_attribute_table": True,
325+
"openocd": {
326+
"prefix": "source [find interface/stlink.cfg]; \
327+
transport select hla_swd; \
328+
source [find target/stm32wlx.cfg];",
329+
},
330+
},
320331
}
321332

322333
def __init__(self, args):

tockloader/openocd.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,11 @@ def _list_emulators(self):
248248
openocd_cmd=self.openocd_cmd
249249
)
250250
)
251+
openocd_commands.append(
252+
'{openocd_cmd} -c "source [find interface/stlink.cfg]; transport select hla_swd; source [find target/stm32wlx.cfg]; init; exit;"'.format(
253+
openocd_cmd=self.openocd_cmd
254+
)
255+
)
251256

252257
# These are the magic strings in the output of openocd we are looking
253258
# for. If there is a better way to do this then we should change. But,
@@ -259,6 +264,7 @@ def _list_emulators(self):
259264
("(mfg: 0x049 (Xilinx), part: 0x3631, ver: 0x1)", "arty"),
260265
("SWD DPIDR 0x2ba01477", "microbit_v2"),
261266
("stm32f4x.cpu", "stm32f4discovery"),
267+
("stm32wlx.cpu", "stm32wle5jc"),
262268
]
263269

264270
emulators = []

tockloader/tockloader.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,9 @@ class TockLoader:
150150
"lpc55s69": {
151151
"start_address": 0x20000,
152152
},
153+
"stm32wle5jc": {
154+
"start_address": 0x8018000,
155+
},
153156
},
154157
}
155158

0 commit comments

Comments
 (0)