Merge branch 'dev'

This commit is contained in:
Benjamin VALLET 2022-04-01 08:50:16 +02:00
commit d92d1d6aed
1 changed files with 34 additions and 0 deletions

34
motion/motion.ino Normal file
View File

@ -0,0 +1,34 @@
#include "MeOrion.h"
MeDCMotor motorL(M1); //positive go backward
MeDCMotor motorR(M2); //positive go forward
uint8_t motorSpeed = 100;
void setup()
{
}
void loop()
{
motorL.run(motorSpeed); /* value: between -255 and 255. */
//motorR.run(motorSpeed); /* value: between -255 and 255. */
delay(2000);
motorL.stop();
motorR.stop();
delay(100);
motorL.run(-motorSpeed);
motorR.run(-motorSpeed);
delay(2000);
motorL.stop();
motorR.stop();
delay(2000);
}