|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
||||
|
||||
|
Five Second Delay at Beginning of TeleOp
Our team's robot has this issue that I haven't been able to figure out. At the beginning of teleop, we consistently have to wait around five seconds for the robot to start responding to user input. I've looked over my code multiple times, looked online for solutions, and I'm not sure what is causing it. I think it might be caused by the initialization of multiple threads, but similar code was implemented last season without this problem.
I use the SampleRobot template for extensive control over operation. Here's a link to it on Github:https://github.com/CorruptedArk/MTR-...team1528/robot Robot is the main class, and we've been using autonomous0() for autonomous and teleOpLoop0() for teleop. Any insight on what could be causing this would be greatly appreciated. Last edited by CorruptedArk : 01-04-2015 at 17:42. |
|
#2
|
|||||
|
|||||
|
Re: Five Second Delay at Beginning of TeleOp
Do you initialize any cameras at the start of Teleop?
That sucks up about 5-7 seconds. |
|
#3
|
|||||
|
|||||
|
Re: Five Second Delay at Beginning of TeleOp
Line 371 of Robot.java
|
|
#4
|
||||
|
||||
|
Re: Five Second Delay at Beginning of TeleOp
That could be it. Do they go to disabled before teleOp during a match? I thought it went straight to teleOp from autonomous.
|
|
#5
|
|||
|
|||
|
Re: Five Second Delay at Beginning of TeleOp
Quote:
Quote:
|
|
#6
|
||||
|
||||
|
Re: Five Second Delay at Beginning of TeleOp
Quote:
|
|
#7
|
||||
|
||||
|
Re: Five Second Delay at Beginning of TeleOp
Quote:
Yes, I can acknowledge that it helps teams get up and running quickly, but teaches bad practices, and has the potential to create really confusing scenarios when you start utilizing command based programming. Here's a post I wrote on it last year... http://www.chiefdelphi.com/forums/sh...27&postcount=2 I realize that it's late in the season to change how you handle this, but in future seasons please reconsider using Timer.delay for anything other than giving the brain a break. |
|
#8
|
||||
|
||||
|
Re: Five Second Delay at Beginning of TeleOp
I don't initialize any cameras, so that can't be it.
Last edited by CorruptedArk : 01-04-2015 at 19:40. Reason: Grammar/Spelling |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|