View Single Post
  #7   Spotlight this post!  
Unread Yesterday, 01:18
euhlmann's Avatar
euhlmann euhlmann is offline
CTO, Programmer
AKA: Erik Uhlmann
FRC #2877 (LigerBots)
Team Role: Leadership
 
Join Date: Dec 2015
Rookie Year: 2015
Location: United States
Posts: 410
euhlmann has much to be proud ofeuhlmann has much to be proud ofeuhlmann has much to be proud ofeuhlmann has much to be proud ofeuhlmann has much to be proud ofeuhlmann has much to be proud ofeuhlmann has much to be proud ofeuhlmann has much to be proud of
Re: Pneumatics code problems.

Quote:
Originally Posted by charlier999 View Post
The one problem with this code is that when i press the button longer than 1/50th of a second(50 cycles per second the rio reads the code), it hastily switches back and forth between on and off. Is there any way of fixing the problem or do i just need to have extremely fast fingers for that button.

Thx.
My code shouldn't do that. Notice how it sets a flag wasAPressed to make sure it doesn't continuously run shifting. Make sure wasAPressed is a member variable, not a local variable
__________________
Creator of SmartDashboard.js, an extensible nodejs/webkit replacement for SmartDashboard


https://ligerbots.org
Reply With Quote