1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

43302 Commits

Author SHA1 Message Date
9467f04008
pkg/semtech-loramac/doc: sx1261 and sx1262 are also supported 2023-04-30 21:56:52 +02:00
bors[bot]
7213c0ad3e
Merge #19354
19354: core/compiler_hints: add assume() hint r=maribu a=benpicco



Co-authored-by: Benjamin Valentin <benpicco@beuth-hochschule.de>
2023-04-27 15:23:25 +00:00
Benjamin Valentin
a5bc1b3722 core/compiler_hints: fix detection of __builtin_unreachable() 2023-04-27 16:15:16 +02:00
bors[bot]
d371f132f2
Merge #19503
19503: release-notes.txt: add 2023.04 release notes r=MrKevinWeiss a=jia200x



Co-authored-by: Jose Alamos <jose@alamos.cc>
2023-04-27 13:57:00 +00:00
Jose Alamos
2c111ae644
release-notes.txt: add 2023.04 release notes 2023-04-27 15:25:47 +02:00
bors[bot]
ffdc1df807
Merge #19516
19516: cpu/rpx0xx: add initial ADC support r=dylad a=dylad

### Contribution description

This PR adds initial support for RP2040 ADC peripheral.
It is rather minimalist, and only use oneshot trigger to perform a single acquisition.

I've tested this PR using a potentiometer connected between GND and 3V3.
GP26, GP27, GP28 has been tested.

### Testing procedure
Select `ADC_RES_12BIT` and flash `tests/periph_adc`
`make BOARD=rpi-pico -C tests/periph_adc`

### Issues/PRs references
None.


Co-authored-by: Dylan Laduranty <dylan.laduranty@mesotic.com>
2023-04-27 10:35:10 +00:00
Dylan Laduranty
a68cfc0d57 boards/rpi-pico: add ADC support in Kconfig
Signed-off-by: Dylan Laduranty <dylan.laduranty@mesotic.com>
2023-04-27 12:15:19 +02:00
Dylan Laduranty
aaecb5419e cpu/rpx0xx: add minimal ADC support
Signed-off-by: Dylan Laduranty <dylan.laduranty@mesotic.com>
2023-04-27 12:15:19 +02:00
bors[bot]
429de92251
Merge #19346 #19512 #19513 #19514
19346: pkg/tinydtls: allow build for AVR r=benpicco a=benpicco



19512: SUBSYSTEMS.md: add jia200x to subsystems r=benpicco a=jia200x



19513: boards/nrf52840dongle/doc: Update nrfutil pointers r=benpicco a=chrysn

### Contribution description

Nordic changed its nrfutil; this change adjust to it.

I'm not fully happy with recommending that tool at all due to its bad quality (see rambling in https://github.com/RIOT-OS/RIOT/issues/19511), but short of soldering on a debug header or touch-probing it with wires it's the only way in to the device. I may later add follow-up recommendations to switch to riotboot, but this now at least fixes the immediate issue.

### Testing procedure

* Look at the updated documentation.

### Issues/PRs references

Closes: https://github.com/RIOT-OS/RIOT/issues/19511

19514: dist/testbed-support: remove obsolete boards from iotlab archi r=benpicco a=aabadie



Co-authored-by: Benjamin Valentin <benjamin.valentin@ml-pa.com>
Co-authored-by: Benjamin Valentin <benjamin.valentin@bht-berlin.de>
Co-authored-by: Jose Alamos <jose@alamos.cc>
Co-authored-by: chrysn <chrysn@fsfe.org>
Co-authored-by: Alexandre Abadie <alexandre.abadie@inria.fr>
2023-04-26 15:40:08 +00:00
bors[bot]
36c5f2c7b0
Merge #19515
19515: drivers/servo: Fix missing dep r=maribu a=maribu

### Contribution description

The servo test app uses `USEMODULE += servo` and lets the build system pick automatically the best suitable backend. If one explicitly chooses a backend e.g. via `USEMODULE += servo_timer`, this currently requires adding `USEMODULE += servo` in addition. This commit fixes the issue.

### Testing procedure

The app provided in https://github.com/RIOT-OS/RIOT/issues/19474 should now compile. (It does so for me.)

### Issues/PRs references

Fixes https://github.com/RIOT-OS/RIOT/issues/19474

Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
2023-04-26 13:34:12 +00:00
Marian Buschsieweke
c0a614d896
drivers/servo: Fix missing dep
The servo test app uses `USEMODULE += servo` and lets the build system
pick automatically the best suitable backend. If one explicitly chooses
a backend e.g. via `USEMODULE += servo_timer`, this currently requires
adding `USEMODULE += servo` in addition. This commit fixes the issue.

Fixes https://github.com/RIOT-OS/RIOT/issues/19474
2023-04-26 15:15:53 +02:00
bbf2ce5628
dist/testbed-support: remove obsolete boards from iotlab archi 2023-04-26 15:02:12 +02:00
chrysn
1ded4edd9e boards/nrf52840dongle/doc: Fix heading link target 2023-04-26 14:55:39 +02:00
chrysn
2b50c61429 boards/nrf52840dongle/doc: Update nrfutil pointers
Closes: https://github.com/RIOT-OS/RIOT/issues/19511
2023-04-26 14:30:29 +02:00
Jose Alamos
32ec63b4cd
SUBSYSTEMS.md: add jia200x to subsystems 2023-04-26 11:52:33 +02:00
bors[bot]
dadfa88911
Merge #19507
19507: cpu/cc26x0_cc13x0: Drop feature cortexm_mpu r=maribu a=maribu

### Contribution description

At least the CC2650 doesn't have an MPU, I assume this is also true for the rest of the family.

The CC2652 does have an MPU according to the datasheet. So I keep the feature there in place.

### Testing procedure

E.g.

```
make BOARD=cc2650-launchpad -C tests/mpu_noexec_ram flash test
```

fails. (Note: A successful test run would also crash but with a mem manage handler rather than a hardfault due to an invalid instruction on the stack being executed.)

It would be nice to also test the same for a `cc2652-launchpad`, for which the MPU should work.

### Issues/PRs references

None

Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
2023-04-26 09:20:01 +00:00
Marian Buschsieweke
5c8e3c7c93
cpu/cc26x0_cc13x0: Drop feature cortexm_mpu
At least the CC2650 doesn't have an MPU, I assume this is also true
for the rest of the family.

The CC2652 does have an MPU according to the datasheet. So I keep the
feature there in place.
2023-04-26 10:51:52 +02:00
Benjamin Valentin
824d2f8f03 tests: update Makefile.ci where tinyDTLS is used 2023-04-26 10:31:35 +02:00
Benjamin Valentin
81dfcc253d examples: update Makefile.ci where tinyDTLS is used 2023-04-26 10:31:09 +02:00
Benjamin Valentin
5274e30178 cpu/avr8_common: implement perror() 2023-04-26 10:31:09 +02:00
bors[bot]
23f7087845
Merge #19315
19315: cpu/native: add host fs access via VFS r=benpicco a=benpicco



Co-authored-by: Benjamin Valentin <benpicco@beuth-hochschule.de>
Co-authored-by: Benjamin Valentin <benjamin.valentin@ml-pa.com>
2023-04-25 23:14:45 +00:00
Benjamin Valentin
5bf83c2556 tests/gcoap_fileserver: set CONFIG_NATIVE_ISOLATE_FS 2023-04-26 00:53:15 +02:00
Benjamin Valentin
f78911ebf7 gcoap_fileserver: set permissions on create 2023-04-26 00:53:14 +02:00
Benjamin Valentin
67f23b283e boards/native: default to fs_native 2023-04-26 00:53:14 +02:00
Benjamin Valentin
6fe5d85e11 cpu/native: unmount fs on exit 2023-04-26 00:53:14 +02:00
Benjamin Valentin
5708ca1945 vfs: add auto_unmount_vfs() 2023-04-26 00:53:14 +02:00
Benjamin Valentin
f4e9da51fa boards/native: add mount point for host fs 2023-04-26 00:53:14 +02:00
Benjamin Valentin
c438c80548 cpu/native: add host fs access via VFS 2023-04-26 00:53:14 +02:00
Dylan Laduranty
9c5e508d2f cpu/rpx0xx: initialize USB PLL and ADC clock
Signed-off-by: Dylan Laduranty <dylan.laduranty@mesotic.com>
2023-04-25 21:12:42 +02:00
Dylan Laduranty
80e3f57205 cpu/rpx0xx: fix doc error in periph_cpu.h
Signed-off-by: Dylan Laduranty <dylan.laduranty@mesotic.com>
2023-04-25 21:02:54 +02:00
bors[bot]
46af92d3a0
Merge #18620 #19296 #19504 #19506
18620: core: add core_mutex_debug to aid debugging deadlocks r=maribu a=maribu

### Contribution description

Adding `USEMODULE += core_mutex_debug` to your `Makefile` results in
on log messages such as

    [mutex] waiting for thread 1 (pc = 0x800024d)

being added whenever `mutex_lock()` blocks. This makes tracing down
deadlocks easier.

### Testing procedure

Run e.g.

```sh
USEMODULE=core_mutex_debug BOARD=nucleo-f767zi make -C tests/mutex_cancel flash test
```

which should provide output such as

```
Welcome to pyterm!
Type '/exit' to exit.
READY
s
[mutex] waiting for thread 1 (pc = 0x8000f35)
START
main(): This is RIOT! (Version: 2022.10-devel-841-g5cc02-core/mutex/debug)
Test Application for mutex_cancel / mutex_lock_cancelable
=========================================================

Test without cancellation: OK
Test early cancellation: OK
Verify no side effects on subsequent calls: [mutex] waiting for thread 1 (pc = 0x800024d)
OK
Test late cancellation: [mutex] waiting for thread 1 (pc = 0x0)
OK
TEST PASSED
```

```sh
$ arm-none-eabi-addr2line -a 0x800024d -e tests/mutex_cancel/bin/nucleo-f767zi/tests_mutex_cancel.elf 
0x0800024d
/home/maribu/Repos/software/RIOT/tests/mutex_cancel/main.c:51
```

### Issues/PRs references

Depends on and includes https://github.com/RIOT-OS/RIOT/pull/18619

19296: nanocoap: allow to define CoAP resources as XFA r=maribu a=benpicco



19504: cpu/cc26xx_cc13xx: Fix bogus array-bound warning r=maribu a=maribu

### Contribution description

GCC 12 create a bogus array out of bounds warning as it assumes that because there is special handling for `uart == 0` and `uart == 1`, `uart` can indeed be `1`. There is an `assert(uart < UART_NUMOF)` above that would blow up prior to any out of bounds access.

In any case, optimizing out the special handling of `uart == 1` for when `UART_NUMOF == 1` likely improves the generated code and fixes the warning.

    /home/maribu/Repos/software/RIOT/cc2650/cpu/cc26xx_cc13xx/periph/uart.c:88:8: error: array subscript 1 is above array bounds of 'uart_isr_ctx_t[1]' [-Werror=array-bounds]
       88 |     ctx[uart].rx_cb = rx_cb;
          |     ~~~^~~~~~
    /home/maribu/Repos/software/RIOT/cc2650/cpu/cc26xx_cc13xx/periph/uart.c:52:23: note: while referencing 'ctx'
       52 | static uart_isr_ctx_t ctx[UART_NUMOF];
          |                       ^~~
    /home/maribu/Repos/software/RIOT/cc2650/cpu/cc26xx_cc13xx/periph/uart.c:89:8: error: array subscript 1 is above array bounds of 'uart_isr_ctx_t[1]' [-Werror=array-bounds]
       89 |     ctx[uart].arg = arg;
          |     ~~~^~~~~~
    /home/maribu/Repos/software/RIOT/cc2650/cpu/cc26xx_cc13xx/periph/uart.c:52:23: note: while referencing 'ctx'
       52 | static uart_isr_ctx_t ctx[UART_NUMOF];
          |                       ^~~

### Testing procedure

The actual change is a pretty obvious one-liner, so that code review and a green CI should be sufficient. If not, running any UART example app without regression should do.

### Issues/PRs references

None

19506: tools/openocd: Fix handling of OPENOCD_CMD_RESET_HALT r=maribu a=maribu

### Contribution description

The OPENOCD_CMD_RESET_HALT was not longer correctly passed to the script. This fixes the issue.

### Testing procedure

Flashing of e.g. the `cc2650-launchpad` with upstream OpenOCD should work again.

### Issues/PRs references

The change was added to https://github.com/RIOT-OS/RIOT/pull/19050 after testing the PR and before merging. I'm not sure if the fix never worked because of this, or if behavior of `target-export-variables` or GNU Make changed.

Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
Co-authored-by: Benjamin Valentin <benjamin.valentin@bht-berlin.de>
Co-authored-by: Benjamin Valentin <benjamin.valentin@ml-pa.com>
2023-04-25 15:46:11 +00:00
Marian Buschsieweke
f220c23c20
tools/openocd: Fix handling of OPENOCD_CMD_RESET_HALT
The OPENOCD_CMD_RESET_HALT was not longer correctly passed to the
script. This fixes the issue.
2023-04-25 15:59:30 +02:00
Marian Buschsieweke
d6499fa8fd
cpu/cc26xx_cc13xx: Fix bogus array-bound warning
GCC 12 create a bogus array out of bounds warning as it assumes that
because there is special handling for `uart == 0` and `uart == 1`,
`uart` can indeed be `1`. There is an `assert(uart < UART_NUMOF)` above
that would blow up prior to any out of bounds access.

In any case, optimizing out the special handling of `uart == 1` for
when `UART_NUMOF == 1` likely improves the generated code and fixes
the warning.

    /home/maribu/Repos/software/RIOT/cc2650/cpu/cc26xx_cc13xx/periph/uart.c:88:8: error: array subscript 1 is above array bounds of 'uart_isr_ctx_t[1]' [-Werror=array-bounds]
       88 |     ctx[uart].rx_cb = rx_cb;
          |     ~~~^~~~~~
    /home/maribu/Repos/software/RIOT/cc2650/cpu/cc26xx_cc13xx/periph/uart.c:52:23: note: while referencing 'ctx'
       52 | static uart_isr_ctx_t ctx[UART_NUMOF];
          |                       ^~~
    /home/maribu/Repos/software/RIOT/cc2650/cpu/cc26xx_cc13xx/periph/uart.c:89:8: error: array subscript 1 is above array bounds of 'uart_isr_ctx_t[1]' [-Werror=array-bounds]
       89 |     ctx[uart].arg = arg;
          |     ~~~^~~~~~
    /home/maribu/Repos/software/RIOT/cc2650/cpu/cc26xx_cc13xx/periph/uart.c:52:23: note: while referencing 'ctx'
       52 | static uart_isr_ctx_t ctx[UART_NUMOF];
          |                       ^~~
2023-04-25 15:31:27 +02:00
Marian Buschsieweke
3e86e39646
core: add core_mutex_debug to aid debugging deadlocks
Adding `USEMODULE += core_mutex_debug` to your `Makefile` results in
on log messages such as

    [mutex] waiting for thread 1 (pc = 0x800024d)

being added whenever `mutex_lock()` blocks. This makes tracing down
deadlocks easier.
2023-04-25 15:10:34 +02:00
Benjamin Valentin
006ad81c0c cpu/native: wire up more fs related syscalls 2023-04-25 13:28:20 +02:00
Benjamin Valentin
8ec1934226 cpu/native: add braces to condition 2023-04-25 13:27:39 +02:00
bors[bot]
8b58e55580
Merge #19495
19495: Rust: Update dependencies r=chrysn a=chrysn

### Contribution description

This updates both the RIOT-specific and generic dependencies of Rust examples and modules.

It also follows a deprecation from the G unit renaming originally done in https://github.com/RIOT-OS/RIOT/pull/19292.

### Testing procedure

* Green CI should do

### Issues/PRs references

Copying from one of the commits with some sed:

* riot-sys:
    * https://github.com/RIOT-OS/rust-riot-sys/pull/26
    * https://github.com/RIOT-OS/rust-riot-sys/pull/31
    * https://github.com/RIOT-OS/rust-riot-sys/pull/30
    * https://github.com/RIOT-OS/rust-riot-sys/pull/28
    * https://github.com/RIOT-OS/rust-riot-sys/pull/27
    * https://github.com/RIOT-OS/rust-riot-sys/pull/25
    * https://github.com/RIOT-OS/rust-riot-sys/pull/23
    * https://github.com/RIOT-OS/rust-riot-sys/pull/22
    * https://github.com/RIOT-OS/rust-riot-sys/pull/21
* riot-wrappers:
    * https://github.com/RIOT-OS/rust-riot-wrappers/pull/36
    * https://github.com/RIOT-OS/rust-riot-wrappers/pull/50
    * https://github.com/RIOT-OS/rust-riot-wrappers/pull/48
    * https://github.com/RIOT-OS/rust-riot-wrappers/pull/47
    * https://github.com/RIOT-OS/rust-riot-wrappers/pull/44
    * https://github.com/RIOT-OS/rust-riot-wrappers/pull/45
    * https://github.com/RIOT-OS/rust-riot-wrappers/pull/43
    * (later, when the mistake became apparent) https://github.com/RIOT-OS/rust-riot-wrappers/pull/55

### How to do similar PRs

Updating the RIOT-related dependencies (which here also updated bindgen because the dependency of riot-sys changed):

```
$ for x in **/Cargo.lock; do cargo update --manifest-path=${x%.lock}.toml --package riot-sys --package riot-wrappers; done
```

Updating everything (should never really be needed, b/c if something has a concrete dependency change it'd say so, but dependencies generally get better over time):

```
$ for x in **/Cargo.lock; do cargo update --manifest-path=${x%.lock}.toml; done
```

Creating the commit message:

```
$ git log --first-parent --format='%s (%b)' 9c29faf55d4c14d2d7f55f8df5059c52af4e5317..e4973a6ee88427f702dac41b3dce4fd6b6b9689e | sed 's/Merges: //' | sed 's/^/    * /'
```

git shortlog unfortunately doesn't show the merges the way I prefer linking them. The versions in the command line can be taken from `git diff --text` and looking for the riot-sys or riot-wrappers line, respectively.

Co-authored-by: chrysn <chrysn@fsfe.org>
2023-04-25 07:42:57 +00:00
chrysn
8e2d26923a drivers/lsm303agr: Rename deprecated unit G to GForce 2023-04-25 09:23:21 +02:00
chrysn
6724e851ca Rust: Update riot-wrappers
This fixes a regression by merging https://github.com/RIOT-OS/rust-riot-wrappers/pull/55
(the "G" unit has been deprecated, but that deprecation was done wrong
in https://github.com/RIOT-OS/rust-riot-wrappers/pull/50).
2023-04-25 09:20:58 +02:00
bors[bot]
70e91e4cac
Merge #19499 #19500
19499: makefiles/features_modules: ignore periph_wdt_auto_start r=benpicco a=benpicco



19500: makefiles/features_modules: ignore periph_spidev_linux r=benpicco a=benpicco



Co-authored-by: Benjamin Valentin <benpicco@beuth-hochschule.de>
2023-04-24 23:26:07 +00:00
Benjamin Valentin
0078ab4522 makefiles/features_modules: ignore periph_spidev_linux 2023-04-24 16:57:42 +02:00
Benjamin Valentin
4965a229c9 makefiles/features_modules: ignore periph_wdt_auto_start 2023-04-24 15:40:15 +02:00
chrysn
d630f00cde Rust examples: Update coap-handler-implementations dependency
This helps remove duplicate code after previous updates.
2023-04-24 11:41:13 +02:00
chrysn
5f91bd8812 Rust: Update non-RIOT dependencies 2023-04-24 11:38:59 +02:00
chrysn
de410314a3 Rust: Update riot-sys and riot-wrappers
This pulls in several fixes from these repositories:

* riot-sys:
    * Add `random` module to `riot-headers` (https://github.com/RIOT-OS/rust-riot-sys/pull/26)
    * README: fix 2 typos (https://github.com/RIOT-OS/rust-riot-sys/pull/31)
    * bindgen: Use 0.64 (https://github.com/RIOT-OS/rust-riot-sys/pull/30)
    * wolfSSL support added (https://github.com/RIOT-OS/rust-riot-sys/pull/28)
    * extern-types: Generate replacement types dynamically (https://github.com/RIOT-OS/rust-riot-sys/pull/27)
    * Extern types: Add netq_t, make them large (https://github.com/RIOT-OS/rust-riot-sys/pull/25)
    * doc: Suppress warnings about things C2Rust does not uphold (https://github.com/RIOT-OS/rust-riot-sys/pull/23)
    * export macro_DAC_LINE (https://github.com/RIOT-OS/rust-riot-sys/pull/22)
    * Add BINDGEN_OUTPUT_FILE export (https://github.com/RIOT-OS/rust-riot-sys/pull/21)
* riot-wrappers:
    * DAC: Add wrapper around RIOTs DAC-interface (https://github.com/RIOT-OS/rust-riot-wrappers/pull/36)
    * saul: Compatibly rename G* variants (https://github.com/RIOT-OS/rust-riot-wrappers/pull/50)
    * tests: Add test for auto-init when auto-init debug is active (https://github.com/RIOT-OS/rust-riot-wrappers/pull/48)
    * gcoap: Provide link encoder (https://github.com/RIOT-OS/rust-riot-wrappers/pull/47)
    * Drop SUIT support in riot-wrappers (https://github.com/RIOT-OS/rust-riot-wrappers/pull/44)
    * Add an auto init module (https://github.com/RIOT-OS/rust-riot-wrappers/pull/45)
    * gcoap: Allow registration without scope for 'static listeners (https://github.com/RIOT-OS/rust-riot-wrappers/pull/43)

Through direct dependency changes (the bindgen update), the number of
transitive dependencies could be reduced.
2023-04-24 11:29:52 +02:00
bors[bot]
bd295b00b2
Merge #19494
19494: pkg/qcbor: bump to v1.2 r=kaspar030 a=aabadie



Co-authored-by: Alexandre Abadie <alexandre.abadie@inria.fr>
2023-04-22 21:20:57 +00:00
bd3e6a230f
pkg/qcbor: document how to disable features using CFLAGS 2023-04-22 18:25:14 +02:00
8c5bff8877
pkg/qcbor: bump to v1.2 2023-04-22 17:48:14 +02:00
bors[bot]
0101663e39
Merge #19485
19485: sys/shell: Fix missing dependency r=aabadie a=maribu

### Contribution description

The shell commands depend on the shell module being use. This was already the case in KConfig, but was overlooked in the shell's `Makefile.dep`.

In addition, this uncovered that `tests/memarray` had a bogus dependency on shell commands without every using the shell.

### Testing procedure

Ideally binaries should not differ (except for debug section).

### Issues/PRs references

Split out of https://github.com/RIOT-OS/RIOT/pull/19483

Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
2023-04-22 06:21:38 +00:00
bors[bot]
ca4be42d88
Merge #19488
19488: usbus: remove deprecated USBUS_HANDLER_FLAG_TR_FAIL flag r=gschorcht a=dylad

### Contribution description

This PR removes the deprecated `USBUS_HANDLER_FLAG_TR_FAIL` flag.

### Testing procedure

CI should be enough.

### Issues/PRs references

Was deprecated by #17046

Co-authored-by: Dylan Laduranty <dylan.laduranty@mesotic.com>
2023-04-21 10:17:28 +00:00