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

42817 Commits

Author SHA1 Message Date
Florian Lentz
236603cffc pkg/wolfssl: Update wolfSSL to 5.5.4 and add DTLS 1.3 support 2023-02-22 18:32:01 +01:00
bors[bot]
0cce1bc067
Merge #19299 #19301
19299: Add missing newline to output of telnet example r=benpicco a=Enoch247

### Contribution description

From the commit msg:

> The telnet example prints a line to the console, but it is not ended with a newline. When using pyterm, the last line is then never shown as it reads the console line by line and is waiting for the end of the line.
> 
> This patch swaps use of `printf` for `puts` for the last line printed. This means the missing newline character gets added. This is also done to be consistent with the rest of the file, where puts is used whenever possible instead of printf.


### Testing procedure

1. `cd examples/telnet`
2. `make all flash term`
3. observe the final line "Local shell disabled" is printed, but would not have without this patch


### Issues/PRs references

- none known


19301: fib: document unused state r=benpicco a=benpicco



Co-authored-by: Joshua DeWeese <jdeweese@primecontrols.com>
Co-authored-by: Benjamin Valentin <benjamin.valentin@bht-berlin.de>
2023-02-22 15:50:59 +00:00
Benjamin Valentin
378e5e2382 fib: document unused state 2023-02-22 16:47:14 +01:00
Joshua DeWeese
cdf26c9cd0 examples/telnet_server: add missing newline
The telnet example prints a line to the console, but it is not ended
with a newline. When using pyterm, the last line is then never shown as
it reads the console line by line and is waiting for the end of the
line.

This patch swaps use of `printf` for `puts` for the last line printed.
This means the missing newline character gets added. This is also done
to be consistent with the rest of the file, where puts is used whenever
possible instead of printf.
2023-02-22 09:49:10 -05:00
bors[bot]
e738fdd44c
Merge #13943
13943: RDM: The 802.15.4 Radio HAL r=miri64 a=jia200x



Co-authored-by: Jose Alamos <jose@alamos.cc>
2023-02-22 12:37:05 +00:00
bors[bot]
7d882cf736
Merge #19297
19297: tests/rmutex: clean up test and reduce stack size r=maribu a=maribu

### Contribution description

As the title says. This results in a few more boards being able to run the test.

Also, the wording in the README.md is improved to not be interpreted as generally threads with lower thread ID being preferred over threads with higher when locking a mutex.

### Testing procedure

```
make -C tests/rmutex BOARD=foo flash test
```

### Issues/PRs references

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

Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
2023-02-22 12:19:34 +00:00
bors[bot]
ed32ca3cd8
Merge #19293
19293: boards/seeedstudio-gd32: add mtd_sdcard_default r=benpicco a=gschorcht

### Contribution description

This PR adds the default configuration for `mtd_sdcard` module.

### Testing procedure

Green CI

### Issues/PRs references


Co-authored-by: Gunar Schorcht <gunar@schorcht.net>
2023-02-22 12:02:01 +00:00
Jose Alamos
7ac3052388
rdm/radio_hal: add radio HAL design document 2023-02-22 11:15:49 +01:00
bors[bot]
41b54d8594
Merge #18392
18392: drivers/servo: reimplement with high level interface r=benpicco a=maribu

### Contribution description

The previous servo driver didn't provide any benefit over using PWM directly, as users controlled the servo in terms of PWM duty cycles. This changes the interface to provide a high level interface that abstracts the gory PWM details.

In addition, a SAUL layer and auto-initialization is provided.

### Testing procedure

The test application provides access to the servo driver via the `saul` shell command.

```
> saul
2022-08-02 22:12:31,826 # saul
2022-08-02 22:12:31,827 # ID	Class		Name
2022-08-02 22:12:31,830 # #0	ACT_SWITCH	LD1(green)
2022-08-02 22:12:31,832 # #1	ACT_SWITCH	LD2(blue)
2022-08-02 22:12:31,834 # #2	ACT_SWITCH	LD3(red)
2022-08-02 22:12:31,837 # #3	SENSE_BTN	B1(User button)
2022-08-02 22:12:31,838 # #4	ACT_SERVO	servo
> saul write 4 0
2022-08-02 22:12:41,443 # saul write 4 0
2022-08-02 22:12:41,445 # Writing to device #4 - servo
2022-08-02 22:12:41,447 # Data:	             0 
2022-08-02 22:12:41,450 # [servo] setting 0 to 2949 (0 / 255)
2022-08-02 22:12:41,453 # data successfully written to device #4
> saul write 4 256
2022-08-02 22:12:45,343 # saul write 4 256
2022-08-02 22:12:45,346 # Writing to device #4 - servo
2022-08-02 22:12:45,347 # Data:	           256 
2022-08-02 22:12:45,351 # [servo] setting 0 to 6865 (255 / 255)
2022-08-02 22:12:45,354 # data successfully written to device #4
```

Each write resulted in the MG90S servo that I connected to move to the corresponding position.

### Issues/PRs references

Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
2023-02-22 09:15:59 +00:00
Marian Buschsieweke
6dc2a60597
drivers/servo: reimplement with high level interface
The previous servo driver didn't provide any benefit over using PWM
directly, as users controlled the servo in terms of PWM duty cycles.
This changes the interface to provide a high level interface that
abstracts the gory PWM details.

In addition, a SAUL layer and auto-initialization is provided.

Co-authored-by: benpicco <benpicco@googlemail.com>
2023-02-22 10:00:04 +01:00
Marian Buschsieweke
0620ac68ff
tests/rmutex: clean up test and reduce stack size
This results in a few more boards being able to run the test.
Also, the wording in the README.md is improved.
2023-02-22 09:39:01 +01:00
Gunar Schorcht
30f448d2e9 boards/seeedstudio-gd32: add mtd_sdcard_default 2023-02-22 06:43:06 +01:00
bors[bot]
cf540a2648
Merge #19294 #19295
19294: sys/shell: don't include suit command by default r=benpicco a=benpicco



19295: gcoap: Finish the gcoap_get_resource_list_tl -> gcoap_get_resource_list renaming r=benpicco a=chrysn

### Contribution description

In #16688, an argument was added to the `gcoap_get_resource_list` function by creating a new function `gcoap_get_resource_list_tl` with a deprecation and roll-over plan.

This plan has not been acted on so far.

This PR shortens the original plan by just adding the argument to `gcoap_get_resource_list` and removing `gcoap_get_resource_list_tl` in a single go. The rationale for this deviation is that while it's a public API, its only two practical consumers are the (built-in) well-known/core implementation, and the (built-in) CoRE Resource Directory (cord) endpoint. Moreover, a further change to this API (switching over to `coap_block_slicer_t`) is expected to happen within this release cycle, which would take something like 4 total releases to get through otherwise, which is unrealistic for an API that there are no known external users of.

A second commit clean up ToDo items (in the changed function's documentation) that referred to a IETF draft that has long been abandoned by the CoRE WG.

### Testing procedure

Plain inspection and CI passing should suffice.

### AOB

There is a second analogous pair left over from #16688, `gcoap_req_send` / `gcoap_req_send_tl`. As that *is* expected to be used widely, I prefer not to mix these two concerns, and get the present one through without unnecessary hold-up.

Co-authored-by: Benjamin Valentin <benjamin.valentin@bht-berlin.de>
Co-authored-by: chrysn <chrysn@fsfe.org>
2023-02-21 23:15:06 +00:00
chrysn
86e6898fa5 doc/gcoap: Update ToDo item referencing abandoned document 2023-02-21 20:22:46 +01:00
chrysn
5db24d4f51 gcoap: Rename gcoap_get_resource_list_tl to gcoap_get_resource_list
This is an API change in the latter, which would typically now take an
extra argument GCOAP_SOCKET_TYPE_UNDEF.

Follow-Up-For: https://github.com/RIOT-OS/RIOT/pull/16688
2023-02-21 20:22:46 +01:00
bors[bot]
37b64912d4
Merge #19256
19256: pkg/tinyusb: add GD32VF103 support r=gschorcht a=gschorcht

### Contribution description

This PR provides the tinyUSB support for GD32VF103 and enables the `tinyusb_device` feature as well as `stdio_tinyusb_cdc_acm` for GD32VF103 boards.

### Testing procedure

```
BOARD=sipeeed-longan-nano make -C tests/shell flash term
```
should work

### Issues/PRs references


Co-authored-by: Gunar Schorcht <gunar@schorcht.net>
2023-02-21 16:53:06 +00:00
Benjamin Valentin
f3aa2ac42e examples/suit_update: enable suit command 2023-02-21 17:34:29 +01:00
Benjamin Valentin
e2cb3d13ea sys/shell: don't include suit command by default 2023-02-21 17:34:00 +01:00
Gunar Schorcht
1026cb5c70 tests/xtimer_now64_continuity: blacklist GD32V boards 2023-02-21 16:24:27 +01:00
Gunar Schorcht
dc0a5b0731 tests/xtimer_now32_overflow: blacklist GD32V boards 2023-02-21 16:24:05 +01:00
Gunar Schorcht
8845bee858 tests/pkg_wolfssl: blacklist GD32V boards 2023-02-21 15:05:07 +01:00
Gunar Schorcht
560b0675e8 tests/pkg_lz4: blacklist GD32V boards 2023-02-21 15:05:07 +01:00
Gunar Schorcht
32cddb6386 tests/pkg_lvgl: blacklist GD32V boards 2023-02-21 15:05:07 +01:00
Gunar Schorcht
aac90884c2 tests/pkg_cryptoauthlib_internal-tests: blacklist GD32V boards 2023-02-21 15:05:07 +01:00
Gunar Schorcht
0c99859ff7 tests/nanocoap_cli: blacklist GD32V boards 2023-02-21 15:05:07 +01:00
Gunar Schorcht
8ab9164890 tests/gcoap_fileserver: blacklist GD32V boards 2023-02-21 15:05:07 +01:00
Gunar Schorcht
2808947991 tests/gcoap_dns: blacklist GD32V boards 2023-02-21 15:05:07 +01:00
Gunar Schorcht
a324352f33 examples/gcoap_dtls: blacklist GD32V boards 2023-02-21 15:04:13 +01:00
Gunar Schorcht
ebd377b271 examples/rust-gcoap: blacklist GD32V boards 2023-02-21 15:04:13 +01:00
Gunar Schorcht
31141a2350 drivers/periph_common: fix periph_usbdev_clk dependency in Kconfig
`periph_usbdev_clk` is just a pseudomodule that controls the clock selection which does not depend on full featured `periph_usbdev`.
2023-02-21 15:04:13 +01:00
Gunar Schorcht
c95bde4758 boards/seeedstudio-gd32: enable stdio_tinyusb_cdc_acm as default 2023-02-21 15:04:13 +01:00
Gunar Schorcht
fae506697f boards/sipeed-longan-nano: enable stdio_tinyusb_cdc_acm as default 2023-02-21 15:04:13 +01:00
Gunar Schorcht
80c2008bb1 boards/seeedstudio-gd32: add tinyUSB support 2023-02-21 15:04:13 +01:00
Gunar Schorcht
4540f96332 boards/sipeed-longan-nano: add tinyUSB support 2023-02-21 15:04:13 +01:00
Gunar Schorcht
dc7abdf723 pkg/tinyusb: add GD32V support 2023-02-21 15:04:13 +01:00
bors[bot]
27752e5b57
Merge #19291
19291: dist/tools/insufficient_memory: Improve and clean up script r=maribu a=maribu

### Contribution description

- drop all bash specifics and use generic sh
- fix all shellcheck warnings
- use nproc instead of hard-coded `-j4`
- print output on (real) compilation error

### Testing procedure

Script should still work

### Issues/PRs references

None

Co-authored-by: Marian Buschsieweke <marian.buschsieweke@ovgu.de>
2023-02-21 13:12:01 +00:00
Marian Buschsieweke
f7b032e444
dist/tools/insufficient_memory: Improve and clean up script
- drop all bash specifics and use generic sh
- fix all shellcheck warnings
- use nproc instead of hard-coded `-j4`
- print output on (real) compilation error
2023-02-21 12:07:02 +01:00
bors[bot]
be29a00d74
Merge #19278 #19290
19278: gnrc_dhcpv6_client_simple_pd: select upstream based on type/index r=benpicco a=benpicco



19290: sys/crypto: make AES_KEY struct private & rename it r=benpicco a=benpicco



Co-authored-by: Benjamin Valentin <benjamin.valentin@ml-pa.com>
Co-authored-by: Benjamin Valentin <benjamin.valentin@bht-berlin.de>
2023-02-20 19:09:03 +00:00
Benjamin Valentin
d6e2499ab7 tests/sys_crypto: add missing <string.h> include 2023-02-20 18:31:23 +01:00
Benjamin Valentin
2285961810 sys/crypto: make AES_KEY struct private 2023-02-20 18:22:00 +01:00
bors[bot]
523a39acd3
Merge #19288
19288: rust: Update riot-sys and riot-wrappers r=kaspar030 a=chrysn

### Contribution description

rust: Update riot-sys and riot-wrappers

* riot-wrappers:
  * Fix infinite loop when using a Mutex
  * Make ValueInThread Copy/Clone
* riot-sys:
  * Export xxx_DEV (eg. I2C_DEV) C macros as functions
  * Add auto_init_utils.h

### Testing procedure

CI checks should suffice.

### Issues/PRs references

This pulls in fixes from

* https://github.com/RIOT-OS/rust-riot-sys/pull/18
* https://github.com/RIOT-OS/rust-riot-sys/pull/17 / https://github.com/RIOT-OS/rust-riot-wrappers/issues/37
* https://github.com/RIOT-OS/rust-riot-wrappers/pull/42 / https://github.com/RIOT-OS/rust-riot-wrappers/issues/41


Co-authored-by: chrysn <chrysn@fsfe.org>
2023-02-20 08:34:11 +00:00
chrysn
bcea914338 rust: Update riot-sys and riot-wrappers
* riot-wrappers:
  * Fix infinite loop when using a Mutex
  * Make ValueInThread Copy/Clone
* riot-sys:
  * Export xxx_DEV (eg. I2C_DEV) C macros as functions
  * Add auto_init_utils.h
2023-02-20 09:06:33 +01:00
bors[bot]
96a7d0d466
Merge #19142
19142: sock_dtls: move common code into sock_dtls_establish_session() r=benpicco a=benpicco



Co-authored-by: Benjamin Valentin <benpicco@beuth-hochschule.de>
2023-02-19 22:11:05 +00:00
bors[bot]
810f8a83eb
Merge #19285
19285: pkg/u8g2: bump version r=gschorcht a=benpicco



Co-authored-by: Benjamin Valentin <benpicco@beuth-hochschule.de>
2023-02-19 16:38:49 +00:00
Benjamin Valentin
df4ef80790 sock_dodtls: make use of sock_dtls_establish_session() 2023-02-19 15:10:46 +01:00
Benjamin Valentin
d4f57e34f4 pkg/u8g2: bump version 2023-02-19 00:03:10 +01:00
Benjamin Valentin
28289a13cb gnrc_dhcpv6_client_simple_pd: check result of _find_upstream_netif() 2023-02-18 23:59:42 +01:00
bors[bot]
3917c29977
Merge #19287
19287: boards/esp32s2-lilygo-ttgo-t8: fix STDIO selection in Kconfig r=benpicco a=gschorcht

### Contribution description

This PR fixes the default STDIO selection in Kconfig in case the USB port is connected to the USB to UART bridge which is then used for STDIO (default). It solves the compilation problems in the nightly build.

The PR also includes a very small documentation fix.

### Testing procedure

Green CI.

The compilations that caused problems  in nightly build should pass:
```
python3 dist/tools/compile_test/compile_like_murdock.py -a tests/pkg_tinyusb_cdc_msc -b  esp32s2-lilygo-ttgo-t8 -j8
```
```
python3 dist/tools/compile_test/compile_like_murdock.py -a tests/sys_fido2_ctap/ -b  esp32s2-lilygo-ttgo-t8 -j8
```
```
python3 dist/tools/compile_test/compile_like_murdock.py -a tests/usbus_board_reset/ -b  esp32s2-lilygo-ttgo-t8 -j8
```

### Issues/PRs references


Co-authored-by: Gunar Schorcht <gunar@schorcht.net>
2023-02-18 15:55:38 +00:00
bors[bot]
9998b7ac05
Merge #19269
19269: cpu/gd32v/periph_i2c: interrupt based driver r=gschorcht a=gschorcht

### Contribution description

This PR provides an interrupt-driven version of the I2C low-level driver.

The existing I2C low-level driver for GDVF103 uses a busy-waiting approach where the status register is continuously polled while waiting for a certain status when sending or receiving. The MCU is thus occupied the whole time during a send or receive operation.

The driver provided with this PR uses an interrupt-driven approach. This is, while waiting for a certain status when sending or receiving, the calling thread is suspended and woken up by interrupts.

Since the I2C controller allows to receive up to two bytes before the application has to react, receiving a single byte, two bytes or more than two bytes needs a different handling for correct receiption. This requires a tricky implementation which distinguish a number of different case. There the driver requires 860 byte more ROM and 8 byte more RAM.

### Testing procedure

The driver should work with any I2C sensor/actuator. It was tested with
- `tests/driver_bmp180`
   <details>
  
   ```
    main(): This is RIOT! (Version: 2023.04-devel-355-g940c7-cpu/gd32v/periph_i2c_interrupt_driven)
    BMP180 test application
    
    +------------Initializing------------+
    Initialization successful
    
    +------------Calibration------------+
    AC1: 8448
    AC2: -1208
    AC3: -14907
    AC4: 33310
    AC5: 24774
    AC6: 19213
    B1: 6515
    B2: 49
    MB: -32768
    MC: -11786
    MD: 2958
    
    +--------Starting Measurements--------+
    Temperature [°C]: 22.0
    Pressure [hPa]: 1006.49
    Pressure at see level [hPa]: 1025.55
    Altitude [m]: 157
    
    +-------------------------------------+
    Temperature [°C]: 22.0
    Pressure [hPa]: 1006.56
    Pressure at see level [hPa]: 1025.58
    Altitude [m]: 157
    
    +-------------------------------------+
   ```
   
   </details>
- `tests/driver_ccs811`
   <details>
  
   ```
    main(): This is RIOT! (Version: 2023.04-devel-355-g940c7-cpu/gd32v/periph_i2c_interrupt_driven)
    CCS811 test application
    
    +------------Initializing------------+
    
    +--------Starting Measurements--------+
    TVOC [ppb]: 0
    eCO2 [ppm]: 0
    +-------------------------------------+
    TVOC [ppb]: 0
    eCO2 [ppm]: 0
    +-------------------------------------+
    TVOC [ppb]: 0
    eCO2 [ppm]: 0
    +-------------------------------------+
    TVOC [ppb]: 0
    eCO2 [ppm]: 400
    +-------------------------------------+
    TVOC [ppb]: 0
    eCO2 [ppm]: 400
    +-------------------------------------+
    TVOC [ppb]: 0
    eCO2 [ppm]: 400
    +-------------------------------------+
    TVOC [ppb]: 7
    eCO2 [ppm]: 446
    +-------------------------------------+
    TVOC [ppb]: 7
    eCO2 [ppm]: 446
    +-------------------------------------+
    TVOC [ppb]: 7
    eCO2 [ppm]: 446
    +-------------------------------------+
    TVOC [ppb]: 7
    eCO2 [ppm]: 446
    +-------------------------------------+
    ```
   
   </details>
- `tests/driver_sht3x`
   <details>
  
    ```
    main(): This is RIOT! (Version: 2023.04-devel-355-g940c7-cpu/gd32v/periph_i2c_interrupt_driven)
    SHT3X test application
    
    +------------Initializing------------+
    Initialization successful
    
    
    +--------Starting Measurements--------+
    Temperature [°C]: 21.46
    Relative Humidity [%]: 54.50
    +-------------------------------------+
    Temperature [°C]: 21.47
    Relative Humidity [%]: 54.53
    +-------------------------------------+
    Temperature [°C]: 21.46
    Relative Humidity [%]: 54.48
    +-------------------------------------+
    Temperature [°C]: 21.46
    Relative Humidity [%]: 54.47
    +-------------------------------------+
    ```
   
   </details>
- `tests/driver_l3gxxxx`
   <details>
  
    ```
    main(): This is RIOT! (Version: 2023.04-devel-375-g75547-cpu/gd32v/periph_i2c_interrupt_driven)
    L3GXXXX gyroscope driver test application
    
    Initializing L3GXXXX sensor
    [OK]
    
    gyro [dps] x:    +0, y:    -1, z:    -2
    gyro [dps] x:    +0, y:    +0, z:    +0
    gyro [dps] x:    +0, y:    +0, z:    +0
    gyro [dps] x:    +0, y:    +0, z:    +0
    gyro [dps] x:    +0, y:    +0, z:    +0
    gyro [dps] x:    +0, y:    +0, z:    +0
    gyro [dps] x:    -1, y:    +0, z:    +4
    gyro [dps] x:    +0, y:    +0, z:   -21
    gyro [dps] x:    +0, y:    +0, z:    +6
    gyro [dps] x:   -43, y:    +0, z:   -13
    gyro [dps] x:   -21, y:    -2, z:    +0
    gyro [dps] x:    +0, y:    +1, z:    +3
    gyro [dps] x:   +25, y:    +0, z:    +0
    ```
   
   </details>
- `tests/driver_hd44780` with `pcf8574a` I2C interface

### Issues/PRs references



Co-authored-by: Gunar Schorcht <gunar@schorcht.net>
2023-02-18 07:54:59 +00:00
Gunar Schorcht
5207c6fdf8 boards/esp32s2-lilygo-ttgo-t8: documentation fix 2023-02-18 08:29:02 +01:00