|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
|
|
Thread Tools | Rate Thread | Display Modes |
|
|
|
#1
|
|||
|
|||
|
Re: Robot Drive running too slow????
If you are processing vision, that is likely to be a part of the problem. The vision will use a pretty good amount of CPU for the time it takes to process the image. Higher priority tasks will take cuts, but some tasks could get starved out while that proceeds.
In the game, wen you aren't using the info from the camera, perhaps you should toggle the enable off or slow the frame rate. Also, the loops in periodic do not have to use much CPU. It depends on what is placed in them or how often they are asked to run. Loops that run numerous times with no delay in them are truly what eats the CPU. Greg McKaskle |
|
#2
|
||||
|
||||
|
Re: Robot Drive running too slow????
Quote:
|
|
#3
|
|||
|
|||
|
Re: Robot Drive running too slow????
Thanks for the replies. I'll look into trimming down the vision code, but please consider this. Yesterday, I edited the code to take all the vision code away and ran a test. The performance was better but we were still getting the error.
So I get this error regardless of if there is vision code or not. I can't figure out where it's coming from. |
|
#4
|
|||
|
|||
|
Re: Robot Drive running too slow????
To help locate where this is, in Begin, you are probably opening a single RobotDrive with some numbers of motors. You are probably saving that in the registry with a name. You may want to hit Ctl-F and locate all of the places where you are updating the named RobotDrive. One of those locations is sometimes taking more than 100ms between updates -- the default timeout for the Safety watchdog. If you cannot determine which ones, post some images of ones you are unsure of. There are typically not that any updates to RobotDrive.
Greg McKaskle |
|
#5
|
|||
|
|||
|
Re: Robot Drive running too slow????
Ok. I'll be working on it tonight so I'll try to grab some images and post them. Thanks so much for the input!
|
|
#6
|
|||
|
|||
|
Re: Robot Drive running too slow????
Apologies but I did not get the chance to work on this issue last night like I said. I got side tracked trying to fix another issue. No update yet.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|