|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hi, I'm having a bit of a problem with autonomous mode on my team's robot. after starting autonomous, the robot waits a few seconds and a bunch of these errors:
Code:
Error 1 Robot Drive... Output not updated often enough. java.lang.Thread.run(Thread.java.747) |
|
#2
|
|||||
|
|||||
|
Re: Robot takes a while to start up in autonomous mode
Initializing a camera at the start of Autonomous might cause a blocking delay like that.
|
|
#3
|
|||
|
|||
|
Re: Robot takes a while to start up in autonomous mode
Thanks, but our code doesn't have any camera initialization. We are initializing a Gyro, would that cause something like this?
|
|
#4
|
||||
|
||||
|
Re: Robot takes a while to start up in autonomous mode
Yep. Gyro's have a 5sec blocking period when you initialize them.
|
|
#5
|
|||||
|
|||||
|
Re: Robot takes a while to start up in autonomous mode
I'd suggest commenting out all code leaving just enough to see that Auto is running and Teleop is running, then if the delay is gone just add things back in gradually to see when the delay reappears.
Initialize the gyro during Disabled. |
|
#6
|
||||
|
||||
|
Re: Robot takes a while to start up in autonomous mode
I would recommend initializing the gyro during robotInit, otherwise the field might think you're ready and start a match before the gyro finishes initialization.
|
|
#7
|
||||
|
||||
|
Re: Robot takes a while to start up in autonomous mode
Quote:
*A simple thumbs down is sufficient. No need to start banging that thumb into the glass unless a countdown to start match has begun. |
|
#8
|
|||
|
|||
|
Re: Robot takes a while to start up in autonomous mode
Thanks for the help!
Turns out that a PID loop was causing the problem, I took it out and everything works fine now. |
|
#9
|
|||||
|
|||||
|
Re: Robot takes a while to start up in autonomous mode
Thanks for letting us know how you fixed it.
![]() |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|