Created
February 18, 2017 08:34
-
-
Save e-Gizmo/5af88fc5dec08b4fcb7f6699f4fda685 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
e-Gizmo Beefy Motor Driver Sample code | |
This sketch can simply run your motor in one | |
direction. | |
Wiring Connections: | |
gizDuinoPLUS MCU ===> BeefyMotorDriver | |
GND ===> GND | |
RESET ===> RESET | |
+5V ===> SR | |
D3 ===> PH | |
+5V ===> PWL | |
PWM PIN/D4 ===> PWH | |
by | |
e-Gizmo Mechatronix Central | |
Feb 13, 2017 | |
http://www.e-gizmo.com | |
*/ | |
int PH_PIN = 3; // Direction pin | |
int PWH_PIN = 4; // Speed control/PWM pin | |
void setup(){ | |
pinMode(PH_PIN, OUTPUT); | |
pinMode(PWH_PIN, OUTPUT); | |
} | |
void loop(){ | |
digitalWrite(PH_PIN, HIGH); | |
analogWrite(PWH_PIN, 180); | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment