Skip to content

Commit 00d7214

Browse files
authored
Merge pull request #2860 from fpistm/stm32cubewl3_update
chore(wl3): update to latest STM32CubeWL3 v1.3.0
2 parents be99e02 + dd4046d commit 00d7214

File tree

65 files changed

+32466
-5740
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

65 files changed

+32466
-5740
lines changed

CI/update/patch/HAL/WL3/0001-fix-wl3-HAL-and-LL-warnings.patch

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
From 6d24d07674b242544e2f24a26dd9785efb178650 Mon Sep 17 00:00:00 2001
1+
From cf9d51a1f1763f3452c8ce2312b79357ac9766fc Mon Sep 17 00:00:00 2001
22
From: Frederic Pillon <[email protected]>
33
Date: Tue, 23 Sep 2025 14:48:50 +0200
44
Subject: [PATCH 1/1] fix(wl3): HAL and LL warnings
@@ -7,8 +7,7 @@ Signed-off-by: Frederic Pillon <[email protected]>
77
---
88
.../Inc/stm32wl3x_ll_dma.h | 104 ++++++++++++++++++
99
.../Src/stm32wl3x_hal_flash_ex.c | 2 +-
10-
.../Src/stm32wl3x_ll_adc.c | 2 +-
11-
3 files changed, 106 insertions(+), 2 deletions(-)
10+
2 files changed, 105 insertions(+), 1 deletion(-)
1211

1312
diff --git a/system/Drivers/STM32WL3x_HAL_Driver/Inc/stm32wl3x_ll_dma.h b/system/Drivers/STM32WL3x_HAL_Driver/Inc/stm32wl3x_ll_dma.h
1413
index b94790b32..e49d7c53f 100644
@@ -859,19 +858,6 @@ index 9cd95caf3..d1b9f3dd0 100644
859858
uint32_t index;
860859

861860
/* Check the parameters */
862-
diff --git a/system/Drivers/STM32WL3x_HAL_Driver/Src/stm32wl3x_ll_adc.c b/system/Drivers/STM32WL3x_HAL_Driver/Src/stm32wl3x_ll_adc.c
863-
index 5455a5343..4a88375ed 100644
864-
--- a/system/Drivers/STM32WL3x_HAL_Driver/Src/stm32wl3x_ll_adc.c
865-
+++ b/system/Drivers/STM32WL3x_HAL_Driver/Src/stm32wl3x_ll_adc.c
866-
@@ -24,7 +24,7 @@
867-
#ifdef USE_FULL_ASSERT
868-
#include "stm32_assert.h"
869-
#else
870-
-#define assert_param(expr) ((void)0UL)
871-
+#define assert_param(expr) ((void)0U)
872-
#endif /* USE_FULL_ASSERT */
873-
874-
/** @addtogroup STM32WL3x_LL_Driver
875861
--
876862
2.34.1
877863

CI/update/stm32variant.py

Lines changed: 43 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1647,12 +1647,36 @@ def print_variant(generic_list, alt_syswkup_list):
16471647
def search_product_line(valueline: str, extra: str) -> str:
16481648
product_line = ""
16491649
product_line_list = product_line_dict[mcu_family]
1650-
if not valueline.startswith("STM32MP1"):
1650+
if valueline.startswith("STM32MP1"):
1651+
# previous
1652+
# Unfortunately, MP1 does not follows the same naming rules
1653+
for pline in product_line_dict[mcu_family]:
1654+
vline = valueline
1655+
product_line = pline
1656+
# Remove the 'x' character from pline and
1657+
# the one at same index in the vline
1658+
while 1:
1659+
idx = pline.find("x")
1660+
if idx > 0:
1661+
pline = pline.replace("x", "", 1)
1662+
if "STM32MP15xx" != vline:
1663+
vline = vline[:idx] + vline[idx + 1 :]
1664+
else:
1665+
break
1666+
if pline >= vline and pline[:10] == vline[:10]:
1667+
break
1668+
else:
1669+
# In case of CMSIS device does not exist
1670+
product_line = "STM32MP15xx"
1671+
elif valueline.startswith("STM32WL3"):
16511672
for idx_pline, pline in enumerate(product_line_list):
16521673
vline = valueline
1674+
# Add an 'x' at the end to match the length
1675+
# as startup file contains only one 'x' at the end
1676+
# STM32WL3xx -> STM32WL30K8
1677+
# STM32WL3Rx -> STM32WL3RK8
16531678
product_line = pline
1654-
if vline.startswith("STM32WB0") or vline.startswith("STM32WL3"):
1655-
pline = pline + "xx"
1679+
pline = pline + "x"
16561680
# Remove the 'x' character from pline and
16571681
# the one at same index in the vline
16581682
while 1:
@@ -1662,7 +1686,8 @@ def search_product_line(valueline: str, extra: str) -> str:
16621686
vline = vline[:idx] + vline[idx + 1 :]
16631687
else:
16641688
break
1665-
if pline >= vline:
1689+
# Exact match or generic name
1690+
if pline == vline or product_line == "STM32WL3xx":
16661691
if (
16671692
extra
16681693
and len(product_line_list) > idx_pline + 1
@@ -1674,27 +1699,34 @@ def search_product_line(valueline: str, extra: str) -> str:
16741699
else:
16751700
# In case of CMSIS device does not exist
16761701
product_line = ""
1702+
product_line = product_line.upper()
16771703
else:
1678-
# previous
1679-
# Unfortunately, MP1 does not follows the same naming rules
1680-
for pline in product_line_dict[mcu_family]:
1704+
for idx_pline, pline in enumerate(product_line_list):
16811705
vline = valueline
16821706
product_line = pline
1707+
if vline.startswith("STM32WB0"):
1708+
pline = pline + "xx"
16831709
# Remove the 'x' character from pline and
16841710
# the one at same index in the vline
16851711
while 1:
16861712
idx = pline.find("x")
16871713
if idx > 0:
16881714
pline = pline.replace("x", "", 1)
1689-
if "STM32MP15xx" != vline:
1690-
vline = vline[:idx] + vline[idx + 1 :]
1715+
vline = vline[:idx] + vline[idx + 1 :]
16911716
else:
16921717
break
1693-
if pline >= vline and pline[:10] == vline[:10]:
1718+
if pline >= vline:
1719+
if (
1720+
extra
1721+
and len(product_line_list) > idx_pline + 1
1722+
and product_line_list[idx_pline + 1] == (product_line + extra)
1723+
):
1724+
# Look for the next product line if contains the extra
1725+
product_line = product_line_list[idx_pline + 1]
16941726
break
16951727
else:
16961728
# In case of CMSIS device does not exist
1697-
product_line = "STM32MP15xx"
1729+
product_line = ""
16981730
return product_line
16991731

17001732

CI/update/stm32wrapper.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,12 +123,16 @@ def printCMSISStartup(log):
123123
for fn_list in group_startup_list:
124124
if len(fn_list) == 1:
125125
valueline = re.split("_|\\.", fn_list[0])
126-
vline = valueline[1].upper().replace("X", "x")
126+
vline = valueline[1].upper()
127+
if not valueline[1].startswith("stm32wl3"):
128+
vline = vline.replace("X", "x")
127129
cmsis_list.append({"vline": vline, "fn": fn_list[0], "cm": ""})
128130
else:
129131
for fn in fn_list:
130132
valueline = re.split("_|\\.", fn)
131-
vline = valueline[1].upper().replace("X", "x")
133+
vline = valueline[1].upper()
134+
if not valueline[1].startswith("stm32wl3"):
135+
vline = vline.replace("X", "x")
132136
cm = valueline[2].upper()
133137
cmsis_list.append({"vline": vline, "fn": fn, "cm": cm})
134138
with open(CMSIS_Startupfile, "w", newline="\n") as out_file:

boards.txt

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1026,7 +1026,7 @@ Nucleo_64.menu.pnum.NUCLEO_WL33CC1.upload.maximum_data_size=32768
10261026
Nucleo_64.menu.pnum.NUCLEO_WL33CC1.build.mcu=cortex-m0plus
10271027
Nucleo_64.menu.pnum.NUCLEO_WL33CC1.build.board=NUCLEO_WL33CC1
10281028
Nucleo_64.menu.pnum.NUCLEO_WL33CC1.build.series=STM32WL3x
1029-
Nucleo_64.menu.pnum.NUCLEO_WL33CC1.build.product_line=STM32WL3xx
1029+
Nucleo_64.menu.pnum.NUCLEO_WL33CC1.build.product_line=STM32WL3XX
10301030
Nucleo_64.menu.pnum.NUCLEO_WL33CC1.build.variant=STM32WL3x/WL33C(8-B-C)Vx(X)
10311031
Nucleo_64.menu.pnum.NUCLEO_WL33CC1.build.variant_h=variant_NUCLEO_WL33CCx.h
10321032
Nucleo_64.menu.pnum.NUCLEO_WL33CC1.build.st_extra_flags=-D{build.product_line} {build.xSerial} -D__CORTEX_SC=0
@@ -1045,7 +1045,7 @@ Nucleo_64.menu.pnum.NUCLEO_WL33CC2.upload.maximum_data_size=32768
10451045
Nucleo_64.menu.pnum.NUCLEO_WL33CC2.build.mcu=cortex-m0plus
10461046
Nucleo_64.menu.pnum.NUCLEO_WL33CC2.build.board=NUCLEO_WL33CC2
10471047
Nucleo_64.menu.pnum.NUCLEO_WL33CC2.build.series=STM32WL3x
1048-
Nucleo_64.menu.pnum.NUCLEO_WL33CC2.build.product_line=STM32WL3xx
1048+
Nucleo_64.menu.pnum.NUCLEO_WL33CC2.build.product_line=STM32WL3XX
10491049
Nucleo_64.menu.pnum.NUCLEO_WL33CC2.build.variant=STM32WL3x/WL33C(8-B-C)Vx(X)
10501050
Nucleo_64.menu.pnum.NUCLEO_WL33CC2.build.variant_h=variant_NUCLEO_WL33CCx.h
10511051
Nucleo_64.menu.pnum.NUCLEO_WL33CC2.build.st_extra_flags=-D{build.product_line} {build.xSerial} -D__CORTEX_SC=0
@@ -13647,7 +13647,7 @@ GenWL3.menu.pnum.GENERIC_WL33C8VX=Generic WL33C8Vx
1364713647
GenWL3.menu.pnum.GENERIC_WL33C8VX.upload.maximum_size=65536
1364813648
GenWL3.menu.pnum.GENERIC_WL33C8VX.upload.maximum_data_size=16384
1364913649
GenWL3.menu.pnum.GENERIC_WL33C8VX.build.board=GENERIC_WL33C8VX
13650-
GenWL3.menu.pnum.GENERIC_WL33C8VX.build.product_line=STM32WL3xx
13650+
GenWL3.menu.pnum.GENERIC_WL33C8VX.build.product_line=STM32WL3XX
1365113651
GenWL3.menu.pnum.GENERIC_WL33C8VX.build.variant=STM32WL3x/WL33C(8-B-C)Vx(X)
1365213652
GenWL3.menu.pnum.GENERIC_WL33C8VX.debug.svd_file={runtime.tools.STM32_SVD.path}/svd/STM32WL3x/STM32WL33.svd
1365313653

@@ -13656,7 +13656,7 @@ GenWL3.menu.pnum.GENERIC_WL33C8VXX=Generic WL33C8VxX
1365613656
GenWL3.menu.pnum.GENERIC_WL33C8VXX.upload.maximum_size=65536
1365713657
GenWL3.menu.pnum.GENERIC_WL33C8VXX.upload.maximum_data_size=16384
1365813658
GenWL3.menu.pnum.GENERIC_WL33C8VXX.build.board=GENERIC_WL33C8VXX
13659-
GenWL3.menu.pnum.GENERIC_WL33C8VXX.build.product_line=STM32WL3xx
13659+
GenWL3.menu.pnum.GENERIC_WL33C8VXX.build.product_line=STM32WL3XX
1366013660
GenWL3.menu.pnum.GENERIC_WL33C8VXX.build.variant=STM32WL3x/WL33C(8-B-C)Vx(X)
1366113661
GenWL3.menu.pnum.GENERIC_WL33C8VXX.debug.svd_file={runtime.tools.STM32_SVD.path}/svd/STM32WL3x/STM32WL33.svd
1366213662

@@ -13665,7 +13665,7 @@ GenWL3.menu.pnum.GENERIC_WL33CBVX=Generic WL33CBVx
1366513665
GenWL3.menu.pnum.GENERIC_WL33CBVX.upload.maximum_size=131072
1366613666
GenWL3.menu.pnum.GENERIC_WL33CBVX.upload.maximum_data_size=32768
1366713667
GenWL3.menu.pnum.GENERIC_WL33CBVX.build.board=GENERIC_WL33CBVX
13668-
GenWL3.menu.pnum.GENERIC_WL33CBVX.build.product_line=STM32WL3xx
13668+
GenWL3.menu.pnum.GENERIC_WL33CBVX.build.product_line=STM32WL3XX
1366913669
GenWL3.menu.pnum.GENERIC_WL33CBVX.build.variant=STM32WL3x/WL33C(8-B-C)Vx(X)
1367013670
GenWL3.menu.pnum.GENERIC_WL33CBVX.debug.svd_file={runtime.tools.STM32_SVD.path}/svd/STM32WL3x/STM32WL33.svd
1367113671

@@ -13674,7 +13674,7 @@ GenWL3.menu.pnum.GENERIC_WL33CBVXX=Generic WL33CBVxX
1367413674
GenWL3.menu.pnum.GENERIC_WL33CBVXX.upload.maximum_size=131072
1367513675
GenWL3.menu.pnum.GENERIC_WL33CBVXX.upload.maximum_data_size=32768
1367613676
GenWL3.menu.pnum.GENERIC_WL33CBVXX.build.board=GENERIC_WL33CBVXX
13677-
GenWL3.menu.pnum.GENERIC_WL33CBVXX.build.product_line=STM32WL3xx
13677+
GenWL3.menu.pnum.GENERIC_WL33CBVXX.build.product_line=STM32WL3XX
1367813678
GenWL3.menu.pnum.GENERIC_WL33CBVXX.build.variant=STM32WL3x/WL33C(8-B-C)Vx(X)
1367913679
GenWL3.menu.pnum.GENERIC_WL33CBVXX.debug.svd_file={runtime.tools.STM32_SVD.path}/svd/STM32WL3x/STM32WL33.svd
1368013680

@@ -13683,7 +13683,7 @@ GenWL3.menu.pnum.GENERIC_WL33CCVX=Generic WL33CCVx
1368313683
GenWL3.menu.pnum.GENERIC_WL33CCVX.upload.maximum_size=262144
1368413684
GenWL3.menu.pnum.GENERIC_WL33CCVX.upload.maximum_data_size=32768
1368513685
GenWL3.menu.pnum.GENERIC_WL33CCVX.build.board=GENERIC_WL33CCVX
13686-
GenWL3.menu.pnum.GENERIC_WL33CCVX.build.product_line=STM32WL3xx
13686+
GenWL3.menu.pnum.GENERIC_WL33CCVX.build.product_line=STM32WL3XX
1368713687
GenWL3.menu.pnum.GENERIC_WL33CCVX.build.variant=STM32WL3x/WL33C(8-B-C)Vx(X)
1368813688
GenWL3.menu.pnum.GENERIC_WL33CCVX.debug.svd_file={runtime.tools.STM32_SVD.path}/svd/STM32WL3x/STM32WL33.svd
1368913689

@@ -13692,7 +13692,7 @@ GenWL3.menu.pnum.GENERIC_WL33CCVXX=Generic WL33CCVxX
1369213692
GenWL3.menu.pnum.GENERIC_WL33CCVXX.upload.maximum_size=262144
1369313693
GenWL3.menu.pnum.GENERIC_WL33CCVXX.upload.maximum_data_size=32768
1369413694
GenWL3.menu.pnum.GENERIC_WL33CCVXX.build.board=GENERIC_WL33CCVXX
13695-
GenWL3.menu.pnum.GENERIC_WL33CCVXX.build.product_line=STM32WL3xx
13695+
GenWL3.menu.pnum.GENERIC_WL33CCVXX.build.product_line=STM32WL3XX
1369613696
GenWL3.menu.pnum.GENERIC_WL33CCVXX.build.variant=STM32WL3x/WL33C(8-B-C)Vx(X)
1369713697
GenWL3.menu.pnum.GENERIC_WL33CCVXX.debug.svd_file={runtime.tools.STM32_SVD.path}/svd/STM32WL3x/STM32WL33.svd
1369813698

0 commit comments

Comments
 (0)