adding the files ig
This commit is contained in:
commit
939a70aba5
11 files changed
+356
No files matched your search
@@ -0,0 +1,20 @@
|
||||
#include "I2CStepper.h"
|
||||
|
||||
I2CStepper stepper(0x55);
|
||||
|
||||
void setup() {
|
||||
stepper.begin();
|
||||
// Optionally scan for devices
|
||||
uint8_t found[10];
|
||||
uint8_t n = stepper.scanDevices(found, 10);
|
||||
Serial.print("Found "); Serial.print(n); Serial.println(" I2C devices.");
|
||||
}
|
||||
|
||||
void loop() {
|
||||
stepper.setSpeed(50, 1); // Move at 50% speed, forward
|
||||
delay(2000);
|
||||
stepper.setSpeed(50, 0); // Move at 50% speed, backward
|
||||
delay(2000);
|
||||
stepper.stop();
|
||||
delay(1000);
|
||||
}
|
||||
Reference in new issue
Block a user