first file

This commit is contained in:
Gauthier BASSEREAU 2024-03-12 14:14:46 +01:00
parent 29be0471fd
commit 8f8b53e7ea
2 changed files with 23 additions and 9 deletions

23
motion/motion.ino Normal file
View File

@ -0,0 +1,23 @@
#include "Arduino.h"
#include "Wire.h"
#include "MeMCore.h"
int speed = 100;
MeDCMotor _leftMotor(9);
MeDCMotor _rightMotor(10);
void setup() {
// put your setup code here, to run once:
_leftMotor.run(0);
_rightMotor.run(0);
}
void loop() {
// put your main code here, to run repeatedly:
_leftMotor.run(speed);
_rightMotor.run(speed);
delay(2000);
_leftMotor.stop();
_rightMotor.stop();
delay(2000);
}

View File

@ -1,9 +0,0 @@
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}