use template
This commit is contained in:
10
src/Program.cpp
Normal file
10
src/Program.cpp
Normal file
@ -0,0 +1,10 @@
|
||||
#include "Program.h"
|
||||
|
||||
Program::Program() {
|
||||
// Startup
|
||||
Serial.begin(MONITOR_SPEED);
|
||||
}
|
||||
|
||||
void Program::loop() {
|
||||
// Loop
|
||||
}
|
3
src/README.md
Normal file
3
src/README.md
Normal file
@ -0,0 +1,3 @@
|
||||
# Code source du projet
|
||||
|
||||
En savoir plus: https://docs.platformio.org/en/latest/core/quickstart.html
|
15
src/main.cpp
15
src/main.cpp
@ -1,18 +1,11 @@
|
||||
#include <Arduino.h>
|
||||
#include "Program.h"
|
||||
|
||||
// put function declarations here:
|
||||
int myFunction(int, int);
|
||||
Program* program;
|
||||
|
||||
void setup() {
|
||||
// put your setup code here, to run once:
|
||||
int result = myFunction(2, 3);
|
||||
program = new Program();
|
||||
}
|
||||
|
||||
void loop() {
|
||||
// put your main code here, to run repeatedly:
|
||||
program->loop();
|
||||
}
|
||||
|
||||
// put function definitions here:
|
||||
int myFunction(int x, int y) {
|
||||
return x + y;
|
||||
}
|
Reference in New Issue
Block a user