From 1bc61f62daffff9577343f1fb5f69919b903eafb Mon Sep 17 00:00:00 2001 From: Sebastian Hunkeler Date: Thu, 15 Oct 2020 12:16:26 +0200 Subject: [PATCH 1/4] Nudge user to update the BL through the M7 --- .../PortentaH7_updateBootloader.ino | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libraries/Portenta_System/examples/PortentaH7_updateBootloader/PortentaH7_updateBootloader.ino b/libraries/Portenta_System/examples/PortentaH7_updateBootloader/PortentaH7_updateBootloader.ino index 8b813129c..d32da8878 100644 --- a/libraries/Portenta_System/examples/PortentaH7_updateBootloader/PortentaH7_updateBootloader.ino +++ b/libraries/Portenta_System/examples/PortentaH7_updateBootloader/PortentaH7_updateBootloader.ino @@ -1,6 +1,10 @@ #include "FlashIAP.h" #include "bootloader.h" +#ifndef CORE_CM7 + #error Update the bootloader by uploading the sketch to the M7 core instead of the M4 core. +#endif + #define BOOTLOADER_ADDR (0x8000000) mbed::FlashIAP flash; From d50d3dc173e7f46b26f16d4295dd11d1356f7a08 Mon Sep 17 00:00:00 2001 From: Sebastian Hunkeler Date: Thu, 15 Oct 2020 12:16:35 +0200 Subject: [PATCH 2/4] Nudge user to update the WiFi FW through the M7 --- .../PortentaWiFiFirmwareUpdater.ino | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libraries/WiFi/examples/PortentaWiFiFirmwareUpdater/PortentaWiFiFirmwareUpdater.ino b/libraries/WiFi/examples/PortentaWiFiFirmwareUpdater/PortentaWiFiFirmwareUpdater.ino index 584a6441e..9af831daf 100644 --- a/libraries/WiFi/examples/PortentaWiFiFirmwareUpdater/PortentaWiFiFirmwareUpdater.ino +++ b/libraries/WiFi/examples/PortentaWiFiFirmwareUpdater/PortentaWiFiFirmwareUpdater.ino @@ -4,6 +4,10 @@ #include "wiced_resource.h" #include "certificates.h" +#ifndef CORE_CM7 + #error Update the WiFi firmware by uploading the sketch to the M7 core instead of the M4 core. +#endif + QSPIFBlockDevice root(PD_11, PD_12, PF_7, PD_13, PF_10, PG_6, QSPIF_POLARITY_MODE_1, 40000000); mbed::MBRBlockDevice wifi_data(&root, 1); mbed::FATFileSystem wifi_data_fs("wlan"); @@ -87,4 +91,4 @@ void setup() { void loop() { -} \ No newline at end of file +} From 0920c1fe7960850d58dbc9ee145b9d7c5537205e Mon Sep 17 00:00:00 2001 From: Sebastian Hunkeler Date: Mon, 19 Oct 2020 22:11:45 +0200 Subject: [PATCH 3/4] Avoid compiling system sketches on M4 --- .github/workflows/compile-examples.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/compile-examples.yml b/.github/workflows/compile-examples.yml index 1befc9996..e2e36445c 100644 --- a/.github/workflows/compile-examples.yml +++ b/.github/workflows/compile-examples.yml @@ -42,7 +42,7 @@ jobs: additional-sketch-paths: '"libraries/PDM" "libraries/ThreadDebug"' - board: fqbn: arduino:mbed:envie_m4 - additional-sketch-paths: '"libraries/doom" "libraries/KernelDebug" "libraries/Portenta_SDCARD" "libraries/Portenta_System" "libraries/Portenta_Video" ' + additional-sketch-paths: '"libraries/doom" "libraries/KernelDebug" "libraries/Portenta_SDCARD" "libraries/Portenta_Video"' - board: fqbn: arduino:mbed:envie_m7 additional-sketch-paths: '"libraries/doom" "libraries/KernelDebug" "libraries/Portenta_SDCARD" "libraries/Portenta_System" "libraries/Portenta_Video" "libraries/ThreadDebug" "libraries/USBHOST"' From 859a4635e7dc327b30f7ce51437a89853a42b450 Mon Sep 17 00:00:00 2001 From: Sebastian Hunkeler Date: Mon, 19 Oct 2020 22:15:28 +0200 Subject: [PATCH 4/4] Add WiFi library to compile workflow --- .github/workflows/compile-examples.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/compile-examples.yml b/.github/workflows/compile-examples.yml index e2e36445c..ab59ac29d 100644 --- a/.github/workflows/compile-examples.yml +++ b/.github/workflows/compile-examples.yml @@ -45,7 +45,7 @@ jobs: additional-sketch-paths: '"libraries/doom" "libraries/KernelDebug" "libraries/Portenta_SDCARD" "libraries/Portenta_Video"' - board: fqbn: arduino:mbed:envie_m7 - additional-sketch-paths: '"libraries/doom" "libraries/KernelDebug" "libraries/Portenta_SDCARD" "libraries/Portenta_System" "libraries/Portenta_Video" "libraries/ThreadDebug" "libraries/USBHOST"' + additional-sketch-paths: '"libraries/doom" "libraries/KernelDebug" "libraries/Portenta_SDCARD" "libraries/Portenta_System" "libraries/Portenta_Video" "libraries/ThreadDebug" "libraries/USBHOST" "libraries/WiFi"' steps: - name: Checkout repository