🛠 Premier programme : installer le core et faire clignoter la LED (M7 à 480 MHz !)
Objectives
Discover the Arduino Portenta H7, Arduino's industrial flagship (SKU ABX00042, ~€120.80 on the official store as of October 2026): a dual-core ST STM32H747XI featuring a Cortex-M7 up to 480 MHz (double-precision FPU) and a Cortex-M4 up to 240 MHz, 2 MB of internal flash, 8 MB of SDRAM, and 16 MB of external NOR flash. You will install the correct core in the Board Manager, understand the dual programming mode (M7 and/or M4), and blink the LED with a first serial program.
Hardware
- 1 × Arduino Portenta H7 (the H7 Lite / Lite Connected variants work the same for this tutorial)
- 1 × USB-C data cable (cheap charging cables only provide power)
- Arduino IDE 2.x or Arduino CLI
- In the Board Manager: “Arduino Mbed OS Portenta Boards” (the historical core) or “Arduino Zephyr Boards” (the new core intended to replace it) — for this tutorial, use the Mbed core
Complete code
// premier_programme.ino — blink + série sur la Portenta H7
// Dans l'IDE, sélectionne "Portenta H7" puis la cible M7 (ou M4).
int compteur = 0;
void setup {
Serial.begin(115200); // série sur le port USB-C
while (!Serial) {} // attends l'ouverture du moniteur série
pinMode(LEDG, OUTPUT); // LED verte embarquée (il y a aussi LEDR)
Serial.println("Portenta H7 - core M7 par defaut");
}
void loop {
digitalWrite(LEDG, HIGH); // LED ON
delay(250);
digitalWrite(LEDG, LOW); // LED OFF
delay(750);
Serial.print("tick "); Serial.println(compteur++);
}
Expected verification
The green LED blinks (250 ms ON / 750 ms OFF) and the serial monitor displays the ticks. The program runs by default on the Cortex-M7; the M4 remains idle — the dual-core RPC tutorial will wake it up. If the board seems dead, double-tap RESET: you enter the MCUboot bootloader (the LED cycles), and “Burn bootloader” in the IDE restores a clean bootloader.
Common errors
- Using a “charging” USB-C cable without data lines: the board powers up but never appears in the IDE — this is the #1 cause of false failures.
- Looking for documentation on docs.portenta.io: the old dedicated site no longer resolves (DNS failure) and the arduino/PortentaDocs repository returns 404; everything has migrated to docs.arduino.cc — many old deep links are broken.
- Confusing the two cores in the Board Manager: the Mbed core (mbed_portenta) and the Zephyr core do not have the same flash model (Zephyr uses a loader, see the advanced tutorial); do not install both “just in case” without knowing which one you are targeting.
- Forgetting that the board has TWO cores: when flashing RPC examples, you will need to flash the same sketch on M7 and M4, otherwise the remote call fails silently.
- Getting stuck in bootloader mode after a double-tap: double-tap RESET again or connect to the IDE to reflash; bootloader mode is indicated by a specific LED behavior.
- >
Other tutorials for this board
- Se connecter au Wi-Fi avec le module Murata 1DX (station WPA2)
- Apprivoiser les connecteurs 80 broches : bouton, LED et entrée analogique
- Dual-core M7 ↔ M4 : appels de fonctions distants avec la bibliothèque RPC
- Client HTTPS/TLS : interroger une API sécurisée via le Murata 1DX
- Serveur web sur le port Ethernet 10/100 embarqué
- MicroPython + machine vision : le firmware OpenMV sur un cœur, C++ sur l'autre
Code examples for this board
clignotante.inoArduinobouton-poussoir.inoArduinopwm-respiration.inoArduinoentree-analogique.inoArduinomulti-uart.inoArduinocapteur-i2c-bmp280.inoArduino