View Single Post
  #8   Spotlight this post!  
Unread 08-02-2006, 01:42
Keith Watson Keith Watson is offline
Registered User
FRC #0957 (WATSON)
Team Role: Mentor
 
Join Date: Feb 2006
Rookie Year: 2006
Location: Wilsonville, OR
Posts: 112
Keith Watson is just really niceKeith Watson is just really niceKeith Watson is just really niceKeith Watson is just really nice
Re: Will camera keep running if i have a while statement going

Remove your while statement. Why? Because your code is already running inside of a while loop.

The loop your code runs inside of runs at 26.2ms per loop.

Setting pwms and LEDs does not immediately change the actual hardware. That occurs later in the loop by the default code after your code is left. So making your light scrolling work needs delays between setting successive lights.

It's not really a C question, it's about how the default code is set up (that you don't normally see).
__________________
Keith Watson - Professional Software Engineer
No relation to "Kevin" Watson, who created the camera tracking code.