Thread: Motor Buttons
View Single Post
  #4   Spotlight this post!  
Unread 06-02-2016, 00:14
rich2202 rich2202 is offline
Registered User
FRC #2202 (BEAST Robotics)
Team Role: Mentor
 
Join Date: Jan 2012
Rookie Year: 2012
Location: Wisconsin
Posts: 1,117
rich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond reputerich2202 has a reputation beyond repute
Re: Motor Buttons

It looks something like this:
Quote:
x=isbuttonpressed();
if(x) {
setmotorspeed(SPEED);
} else {
setmorospeed(0);
}
You need to put in the code for checking to see if the button is pressed, and how to set the motor speed for your motors.
Reply With Quote