Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Delay (http://www.chiefdelphi.com/forums/showthread.php?t=101677)

ShadowWing 31-01-2012 23:04

Delay
 
Hello everyone,

There's a five millisecond (0.005 sec) delay in some of the given codes, such as that shown in pg 13 of the "Getting Started with Java for FRC" (by Worcester Polytechnic Institute Robotics Resource Center) manual.

What is the purpose of this short delay?

~Team 3501,
Sunnyvale, CA

RyanCahoon 01-02-2012 00:52

Re: Delay
 
That bit is probably in code that repeats as fast as possible, either in a while loop or in one of the *Continuous methods of IterativeRobot. It ensures that that particular part of the program doesn't consume all of the CPU resources, giving other processes time to run.


All times are GMT -5. The time now is 23:37.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi