Last active
May 2, 2017 01:46
-
-
Save bennuttall/20ab5f93c5f830276fdae3bf1d74cb94 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
from gpiozero import Motor, OutputDevice | |
from time import sleep | |
motor1 = Motor(24, 27) | |
motor1_enable = OutputDevice(5, initial_value=1) | |
motor2 = Motor(6, 22) | |
motor2_enable = OutputDevice(17, initial_value=1) | |
motor3 = Motor(23, 16) | |
motor3_enable = OutputDevice(12, initial_value=1) | |
motor4 = Motor(13, 18) | |
motor4_enable = OutputDevice(25, initial_value=1) | |
motors = (motor1, motor2, motor3, motor4) | |
for motor in motors: | |
motor.forward() | |
sleep(1) | |
motor.stop() |
I tried to to have control using kbhit.py but it seems pizero is not enough powerfull
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Controls: