View Single Post
  #6   Spotlight this post!  
Unread 10-02-2012, 15:18
Patrick Chiang Patrick Chiang is offline
Programming
FRC #3070 (Team Pronto)
Team Role: Mentor
 
Join Date: Feb 2009
Rookie Year: 2009
Location: Seattle
Posts: 162
Patrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to allPatrick Chiang is a name known to all
Re: Camera Vision Processing

Quote:
Originally Posted by 2869Robotics View Post
Im not sure what you guys mean by running it in a seperate thread
Having a separate thread makes it so that your code won't be stuck on some piece of code until it finishes running. It makes it so that it can run multiple pieces of code (technically no on the low level, but for all practical purposes yes).

If you don't stick a piece of particularly long running loop in a thread (say, one that deliberately waits for 5 seconds before it finishes executing), the rest of your program will get stuck on it, and your other code, like your drive/shoot code will stop executing until the 5 seconds is done.

Read this piece of documentation on how you can implement this in Java: http://docs.oracle.com/javase/tutori...l/concurrency/
Attached Thumbnails
Click image for larger version

Name:	loopingthreading.png
Views:	18
Size:	18.3 KB
ID:	11833  
Reply With Quote