I want to make a website to control my robot with. I know how to set up the website and I can do some basic HTML. My motor controller board for the robot is controlled via python. Here is the code to make one wheel go forwards:
I would need to repeat the last line three more times to make all four of the wheels go forwards. PHP is really hard for me, but that is the only language that the online tutorials have. Once I have the basic code, I can duplicate it to make it go in all directions. Also, I don't quite know how to make buttons in HTML(But I can in Python fine), so if someone could explain how to run the Python code when a button is clicked, that would be nice. Sorry if I seem a little grouchy, I'm really exhausted.
Code: Select all
from adafruit_motorkit import MotorKit kit=motorKit() kit.motor1.throttle = 1.0