From 51ddc0da27569057e81c6a1a426da92474d76d7d Mon Sep 17 00:00:00 2001 From: valeros Date: Mon, 19 Feb 2024 15:19:37 +0200 Subject: [PATCH 1/3] Update Arduino-mbed core to v4.1.1 --- platform.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform.json b/platform.json index c83fd755..9744d874 100644 --- a/platform.json +++ b/platform.json @@ -214,7 +214,7 @@ "type": "framework", "optional": true, "owner": "platformio", - "version": "~4.0.6" + "version": "~4.1.1" }, "framework-stm32cubef0": { "type": "framework", From 82e53581a0099bbd2bf010ec1feda3d507416f80 Mon Sep 17 00:00:00 2001 From: valeros Date: Mon, 26 Feb 2024 16:10:02 +0200 Subject: [PATCH 2/3] Update Zephyr to v3.6.0 --- examples/zephyr-drivers-can/src/main.c | 14 +++++++++++--- platform.json | 2 +- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/examples/zephyr-drivers-can/src/main.c b/examples/zephyr-drivers-can/src/main.c index 49bcdf77..2119069e 100644 --- a/examples/zephyr-drivers-can/src/main.c +++ b/examples/zephyr-drivers-can/src/main.c @@ -63,7 +63,7 @@ void rx_thread(void *arg1, void *arg2, void *arg3) ARG_UNUSED(arg2); ARG_UNUSED(arg3); const struct can_filter filter = { - .flags = CAN_FILTER_DATA | CAN_FILTER_IDE, + .flags = CAN_FILTER_IDE, .id = COUNTER_MSG_ID, .mask = CAN_EXT_ID_MASK }; @@ -76,6 +76,10 @@ void rx_thread(void *arg1, void *arg2, void *arg3) while (1) { k_msgq_get(&counter_msgq, &frame, K_FOREVER); + if (IS_ENABLED(CONFIG_CAN_ACCEPT_RTR) && (frame.flags & CAN_FRAME_RTR) != 0U) { + continue; + } + if (frame.dlc != 2U) { printf("Wrong data length: %u\n", frame.dlc); continue; @@ -92,6 +96,10 @@ void change_led_work_handler(struct k_work *work) int ret; while (k_msgq_get(&change_led_msgq, &frame, K_NO_WAIT) == 0) { + if (IS_ENABLED(CONFIG_CAN_ACCEPT_RTR) && (frame.flags & CAN_FRAME_RTR) != 0U) { + continue; + } + if (led.port == NULL) { printf("LED %s\n", frame.data[0] == SET_LED ? "ON" : "OFF"); } else { @@ -192,7 +200,7 @@ void state_change_callback(const struct device *dev, enum can_state state, int main(void) { const struct can_filter change_led_filter = { - .flags = CAN_FILTER_DATA, + .flags = 0U, .id = LED_MSG_ID, .mask = CAN_STD_ID_MASK }; @@ -230,7 +238,7 @@ int main(void) } if (led.port != NULL) { - if (!device_is_ready(led.port)) { + if (!gpio_is_ready_dt(&led)) { printf("LED: Device %s not ready.\n", led.port->name); return 0; diff --git a/platform.json b/platform.json index 9744d874..00c34b5e 100644 --- a/platform.json +++ b/platform.json @@ -298,7 +298,7 @@ "type": "framework", "optional": true, "owner": "platformio", - "version": "~2.30500.0" + "version": "~2.30600.0" }, "tool-stm32duino": { "type": "uploader", From 1352e5ff94ef513b162bfadeb9f457cbc15f8458 Mon Sep 17 00:00:00 2001 From: valeros Date: Tue, 27 Feb 2024 15:19:28 +0200 Subject: [PATCH 3/3] Bump version to 17.3.0 --- platform.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform.json b/platform.json index 00c34b5e..10b9a08e 100644 --- a/platform.json +++ b/platform.json @@ -18,7 +18,7 @@ "type": "git", "url": "https://github.com/platformio/platform-ststm32.git" }, - "version": "17.2.0", + "version": "17.3.0", "frameworks": { "mbed": { "package": "framework-mbed",