0
$\begingroup$

I am working on a robot that has an accelerometer. This accelerometer measures the vibration of the robot. When the robot hits a certain vibration, I would like it to slow down in order to reduce the vibration. I thought about a PID controller, but I don't think it would work. Does anybody have some input on different types of controllers I can use?

  • Mechaman
$\endgroup$
5
  • $\begingroup$ Are the vibrations indicative of a resonant frequency, or are they directly correlated to motor speed? $\endgroup$
    – Ian
    Jun 30 '14 at 17:11
  • $\begingroup$ The vibrations are indicative of a sort of 'resonant frequency' or rather damaging frequency of something being being held by the robot... and it cannot reach that frequency and damage the that something. $\endgroup$
    – mechaman
    Jul 1 '14 at 21:40
  • $\begingroup$ Just to check my assumptions here, are you slowing down a free-spinning load that is vibrating due to being off balance, or is this robot more like a speeding car -- slowing down when the bumpiness of the road gets too intense? $\endgroup$
    – Ian
    Jul 2 '14 at 3:06
  • $\begingroup$ I am slowing down a speeding car when it notices that the terrain has just become too bumpy. So the latter! $\endgroup$
    – mechaman
    Jul 3 '14 at 3:30
  • $\begingroup$ That changes things a bit... I put my reply into answer form. $\endgroup$
    – Ian
    Jul 5 '14 at 16:49
1
$\begingroup$

Since you are attempting to slow down a car when the road gets too bumpy, a PID controller is not what you want. Or rather, the bumpiness of the road will determine the desired speed that goes into the PID, instead of being part of the PID's sensor feedback loop.

You may want to look at additive increase, multiplicative decrease as a function to control your desired speed. The basic idea would be:

good = 1
bad = 1
while (true):
    if (bumpy_level_detected() > bumpy_level_allowed):
        bad = bad + 1
    else:
        good = good + 1

    desired_speed = (good_speed_constant * good) / (bad_speed_constant ** bad)

In more mathematical notation: $$speed_{desired} = \frac{k_{good} * g}{({k_{bad}})^b} $$ Where $g$ represents the number of iterations where the bump sensor was within limits, $b$ represents the number of iterations where the bump sensor was over the limit, $k_{good}$ controls how quickly the car ramps up its speed when the road is smooth, and $k_{bad}$ controls how quickly the car slows down when the road is bumpy.

(The above is just for explanatory purposes; in practice, rather than keeping $g$ and $b$ in memory and causing an overflow as they increase, you'd just apply the $k_{good}$ > 0 and $k_{bad} > 1$ constants to the running total as appropriate.)

$\endgroup$
2
  • $\begingroup$ After thinking about this problem and getting distracted from this problem, I've came to realize that although this control scheme is good for packets... Robots or rather objects with mass and dynamic properties won't work so well. Have you seen a successful account of this control scheme for a robot? $\endgroup$
    – mechaman
    Jul 29 '14 at 19:36
  • $\begingroup$ I don't know of any robots that use this control scheme. That said, it's the simplest algorithm I know of that provides adaptability to a channel of randomly-changing capacity (in the network case, the congestion level; in your case, the bumpiness that causes the vibration). A more rigorous approach would be to model the bumps as a stochastic process. Why don't you think the AIMD approach I outlined above would work for an object with dynamic mass? $\endgroup$
    – Ian
    Jul 30 '14 at 20:27
0
$\begingroup$

Your main problem is that vibration isn't a well-defined measurement; what number do you assign to vibration? Peak accel value? Average accel value? And over what time range; peak value over the last 1s, 2s, 3s?

Once you've decided precisely what measurement you plan to use, then I would initially go ahead and try a PID. If it works then you're set. Beyond that, it's hard to say what will work well. Ideally, you would use a controller that minimizes energy (e.g. $\mathcal{H}_\infty$ control) but those are quite complex and take a lot of advances math to understand and create.

$\endgroup$
5
  • $\begingroup$ What we end up doing is taking the rms every 4 readings from the accelerometer. I considered PID, but if we have our set point of 'vibration' to be 0 then the vehicle will output a linear velocity that is 0. This is due to the case where no movement = no vibration and we don't want this to occur. What is this energy minimizer controller you speak of? $\endgroup$
    – mechaman
    Jun 28 '14 at 2:14
  • $\begingroup$ Your controller is doing more than just reducing vibration, it is also tracking a reference signal. So your controller input is now some combination of position error and vibration measurement, e.g. $\hat{e} = (p-p^d) + \alpha q$ where $p$ is your postiion, $p^d$ is your desired position, and $q$ is your vibration measurement. $\alpha$ is a coefficient for you to tune. $\endgroup$
    – ryan0270
    Jun 28 '14 at 13:09
  • $\begingroup$ Can you describe the intuition behind including the position inside of my error equation? Perhaps a better description of my system is necessary: I have a mathematical model for my robot and I am designing for the linear velocity and the angular velocity. These two variables translate into the right and left motor velocities of my differential drive robot.For the angular velocity, I used heading error with its own PID. And for the linear velocity I want it to be minimized depending on the vibration of the vehicle. $\endgroup$
    – mechaman
    Jun 28 '14 at 23:22
  • $\begingroup$ This said, I don't see why I need to include position in my PID if I already have that handled. My robot can attain a position with the current setup given any velocity, but now I want to vary the velocity as to minimize it based on the vibrations of the robot. (Sorry had to split this up into 2 comments) $\endgroup$
    – mechaman
    Jun 28 '14 at 23:23
  • $\begingroup$ Sorry, but I don't understand your description. Are you saying that your system input is linear/angular velocity and the output is linear/angular position? Please edit your original question to make this clear. $\endgroup$
    – ryan0270
    Jun 29 '14 at 5:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.