![]() |
Re: PIDController not manipulating jaguars
That's most of an answer to my first question. If I understand you correctly, you want to control the drivebase motors in order to maintain a fixed position on the field, right?
Let's try for an answer to my other two questions now. What kind of drivebase do you have? Describe the number, type, and placement of wheels, number and type of motors, kind of gearbox, chain vs. belt, etc. Where do you have the encoders mounted? I'd rather give advice based on what you really need rather than assume things about what your robot is like. Here's another question, now that I think you're talking about the drive motors: Does it matter whether or not the robot gets turned in place? |
Re: PIDController not manipulating jaguars
It is a 6 wheel tank drive with the encoders on the gearbox. It just matters if the gears on either the left or right gearbox turn. Thanks!
|
Re: PIDController not manipulating jaguars
I am reluctant to offer suggestions when I can't get a straight answer to yes-or-no questions. I'll ask them again:
1) You want to control the drivebase motors in order to maintain a fixed position on the field, right? 2) Does it matter whether or not the robot gets turned in place? I'm trying to find out if you care about the orientation of the robot (the direction it's facing) or if you just want to stay over the same patch of field carpet. There are several different ways to do it, and the most appropriate one depends on the details of your requirements. |
Re: PIDController not manipulating jaguars
1) Yes
2) Yes, whether the robot is turned in place matters. |
Re: PIDController not manipulating jaguars
Quote:
Are you using center drop wheel or are you using Omniwheels? If you are not using drop center wheels, I strongly recommend exactly two omnis (front or back) as a good compromise between turning ability and traction. If you have left and right velocity PID loops to your gearbox encoders, it should allow the robot to old it's ground since any movement will be an error verses the commanded zero velocity. If the two loops act independently, they should also hold orientation. Any slop in your drive chain will limit your ability to sense movement and cause sensor delays (phase errors) which make the PID much harder to stabilize. That said, we are finding that for external forces, the accelerometer works well for X and Y. For rotation, we are looking at the gyro. |
Re: PIDController not manipulating jaguars
Quote:
|
Re: PIDController not manipulating jaguars
It can be a little tricky to get PID control and manual control of the same motors with the WPILib PID Controller class. I posted a short description of the method we used here: http://www.chiefdelphi.com/forums/sh...d.php?t=114061
|
Re: PIDController not manipulating jaguars
Quote:
Will this be happening only while the robot is in autonomous mode, or will there be some way of selecting it to "hold position" during teleoperated mode? |
Re: PIDController not manipulating jaguars
It would be for autonomous and a "hold position" control in teleop
|
Re: PIDController not manipulating jaguars
Joe Ross posted a link to a previous discussion of the sort of thing you want to do, along with some information about how to make it work for drive motors.
|
Re: PIDController not manipulating jaguars
Quote:
For our application, returning was not desired behavior. We plan on adding more D term on Tuesday to see if we can limit the "integrator windup". That all said, I agree that for the stated problem a position loop would be adequate, easier to implement and probably preferred. |
Re: PIDController not manipulating jaguars
Thank you everyone
|
Re: PIDController not manipulating jaguars
Quote:
|
Re: PIDController not manipulating jaguars
Quote:
As a point of clarification, we are not using encoders on the gearboxes - we have small, undriven follower omni-wheels with encoders to feedback velocity to the PID on the cRIO. This means that if the driven wheels lose traction while being pushed (or we spin wheels during hard acceleration) the PID still detects and tries to correct the movement. The closed loop PID "set point" is the driver commanded velocity. We do not have a "stay in place" special case, the PID is trying to drive to commanded zero velocity. The WPI PID could potentially do this, but we implemented custom PID because we are using a holonomic drive (modified Killough) where the four driven omni-wheels are at a 30deg angle and we want the driver commands to be Cartesian. We measure the three degrees of freedom (X, Y, Rotation) and derive the four motor voltages. |
Re: PIDController not manipulating jaguars
Quote:
|
| All times are GMT -5. The time now is 12:27. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi