Skip to content

Conversation

@fpistm
Copy link
Member

@fpistm fpistm commented Nov 20, 2025

No description provided.

fpistm and others added 8 commits November 20, 2025 11:46
Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
ResponseTimeout field not available for all LORAMAC_VERSION

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
This adds some more details about RX and TX bytes and TX config. There
is also some code for RX config, but to minimize the impact on RX
timing, that is commented out.
These warnings are caused because frequencies are stored as `uint32_t`,
which is `unsigned long`, while the printf format expects `int`. In
practice, this does not actually cause problems, since on STM32 gcc
`long` and `int` are both 32-bits and frequencies are never large enough
to cause signed vs unsigned ambiguity.

Since printf has no format specifiers for e.g. uint32_t (libc does have
some macros for this, but those really hurt readability), this is tricky
to fix in a portable way (other architectures or compilers might have
`uint32_t` equal to `unsigned int` instead of `unsigned long`), this fix
just casts the frequency to `unsigned` before passing it to printf (and
for good measure, also convert the specifier from `%d` to `%u`). This
does mean this printing will break if `int` is not at least 32-bits
(e.g. on AVR), but given the scope of this library, that should be
acceptable.
Fixes stm32duino#10

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
@fpistm fpistm added this to the 0.4.1/0.5.0 milestone Nov 20, 2025
@fpistm fpistm added enhancement New feature or request fix 🩹 Bug fix labels Nov 20, 2025
@fpistm fpistm merged commit cf58dcc into stm32duino:main Nov 20, 2025
2 checks passed
@github-project-automation github-project-automation bot moved this from In progress to Done in STM32 core based on ST HAL Nov 20, 2025
@fpistm fpistm deleted the 1.4.0_update branch November 20, 2025 14:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request fix 🩹 Bug fix

Projects

Development

Successfully merging this pull request may close these issues.

2 participants