Créer un projet sur Platformio: Difference between revisions
Jump to navigation
Jump to search
Admin nano (talk | contribs) |
Admin nano (talk | contribs) No edit summary |
||
| Line 42: | Line 42: | ||
} | } | ||
</syntaxhighlight> | </syntaxhighlight> | ||
<syntaxhighlight lang="cpp" line> | <syntaxhighlight lang="cpp" line> | ||
Revision as of 12:20, 13 May 2026
Une fois que l'installation de VSCode avec Platformio est accomplie, nous pouvons créer un nouveau projet.
Créer un nouveau projet
Cliquez sur "Finish" et le "Project Wizard" configurera votre projet Platformio.
Une fois le projet créé
Blink avec Platformio
Pour notre premier exemple, nous pouvons fermer platformio.ini.
main.cpp
Dans le panneau EXPLORER, sous >ESP32S3-BLINK >src, cliquez sur main.cpp. L'extension cpp correspond à C++ (C Plus Plus).
Il s'agit du fichier principal de notre programme, comparable au fichier .ino dans Arduino IDE.
Par défault, main.cpp contient :
int main() {
return 0;
}
#include <Arduino.h>
int myFunction(int, int);
void setup() {
int result = myFunction(2, 3);
}
void loop() {
}
int myFunction(int x, int y) {
return x + y;
}


