View Full Version : Joysticks Laggy/Jerky
TheBigCheese
19-03-2011, 15:05
We have been experiencing a problem with our joysticks where the response seems to be laggy or almost deadbanded. Sometimes it will work as expected, but most of the time, it doesn't register until past 1/3 of the way forward or back. I've been able to have it not register until the joystick is fully forward, by moving is slowly.
It doesn't seem to be a problem with the joysticks themselves as we've tried different models and are experiencing the same problems.
Has anyone else experienced this, or does anyone have any suggestions as to what the problem may be?
Thanks in advance.
Andrew Lawrence
19-03-2011, 15:12
Is there something in the code, or is it a mechanical issue? Maybe there is something blocking your wheels, or your motors? Maybe slowing them down? That's all I can think of.
Conor Ryan
19-03-2011, 15:13
Do you have a webcam? The increased data flow might cause the problem, so just unplug it. Also are you using a classmate?
TheBigCheese
19-03-2011, 15:39
I don't think it's a mechanical issue, everything seems to be clear.
I've been using it a bit and it seems like it might be a problem with the wireless. There seems to be a specific .5-1 second lag between moving the arm joystick and the arm actually moving.
We're not using a webcam, though I'll check to see at what rate we're checking specific sensors. We may be tying up resources I suppose, though I think the cRIO should be able to handle a fair amount of requests.
Mark McLeod
19-03-2011, 17:52
I'd do a speed check on your code to see if it's slow in certain spots.
Try putting the robot up on blocks and getting it to repeat the problem while tethered.
In case this helps, we noticed significant control lag when running the driver station on Vista laptops.
Sean1038
19-03-2011, 18:55
We also were having a lag problem with the joysticks, and our best guess is that, while debugging, the code depends on the laptop to run it and since our laptop is really slow, we get a lag. The lag seems to go away when we run the permanent code.
TheBigCheese
20-03-2011, 15:33
Tethering seems to help a little, though it's not obviously better. I timed the code. An entire loop of TeleOp periodic only takes about 32ms, so I think that's fine.
Another problem that has been cropping up is that when braking hard or putting load on the motors, the jaguars turn a solid red and the robot stops moving. The connection is fine, and we can ping to robot, but it doesn't move.
We're using a CAN-based system, so that may be part of the problem, though I'm not sure.
nighterfighter
20-03-2011, 16:36
Are your jaguars in brake or coast mode?
Are you tripping a breaker?
Ken Streeter
20-03-2011, 16:54
We have been experiencing a problem with our joysticks where the response seems to be laggy or almost deadbanded. Sometimes it will work as expected, but most of the time, it doesn't register until past 1/3 of the way forward or back. I've been able to have it not register until the joystick is fully forward, by moving is slowly.
We (1519) were having this problem starting a couple weeks ago when we upgraded our Driver Station (the Classmate) to the new 2011 release running Windows 7. (We had not been having the problem with Windows XP on the classmate.)
This week, we switched to using a different laptop (a Dell Latitude D610) and the lag problem has gone away completely. We believe our problem was due to the Classmate, rather than the robot!
CoachPoore
20-03-2011, 17:01
We (1519) were having this problem starting a couple weeks ago when we upgraded our Driver Station (the Classmate) to the new 2011 release running Windows 7. (We had not been having the problem with Windows XP on the classmate.)
This week, we switched to using a different laptop (a Dell Latitude D610) and the lag problem has gone away completely. We believe our problem was due to the Classmate, rather than the robot!
Yes, we were also seeing other concerning symptoms such as the robot continuing to operate for up to about 5s after it should have been disabled via the driver station. This was observed when disabling by pressing the space bar or clicking on the "Disable" button. The Classmate in question had been re-imaged to Windows 7 using the (unmodified) memory stick provided in the KoP. Other than activating Windows 7, the only other thing we had done to the Classmate was to install the latest driver station update.
Mark McLeod
20-03-2011, 17:06
When I've seen the slow down/stutter due to the Classmate it has been when there is very little free disk space left.
The OS starts struggling to keep up with it's regular housekeeping and commands to the robot begin to get delayed.
TheBigCheese
20-03-2011, 18:06
Well we've determined that it's actually two problems.
1. We're tripping a breaker if you jam hard in the opposite direction with inertia.
I'm not really sure why this is happening, since we've never had the problem in previous years. It's just a cim and toughbox chained to a wheel.
2. The Joysticks give some faulty readings.
The joysticks will read zero if properly moved. I can move it slowly to full and about 5-10% of the time the Y axis will read at zero, then quickly jump to the correct reading if I wiggle the stick a bit. It's strange because it happens on all models, and on certain sticks more than others. We're going to go ahead and install the proprietary drivers to see if that helps.
We've tried different laptops as well, though that doesn't seem to be the problem, nor does tethering help.
We also just switched to Victors and we're still tripping the breaker and having Joystick problems, so it's definitely not a problem with CAN.
Thanks for the ongoing help.
vBulletin® v3.6.4, Copyright ©2000-2017, Jelsoft Enterprises Ltd.