Recommended Posts

Hi,
you will find a robotC code for the balancing problem on https://github.com/OmegaTom/LineBalancer (combined with a line follower and some more optional stuff)
I have used a 'new' approach. The original LEGO solution (education set) is using a simple linear combination of the robot speed/position and the gyro rate/angle to balance the robot. This solution is quite senitive to calibration and mechnaical aspects of the robot. Laurens (robotsquare.com) has enhanced this solution by introducing a single PID control loop for the same linear combination. This improves the stability significantly but still there are limitations in optimizing the control loop. 
My approach is using 4 parallel PID controllers ... one for each parameter seperately. On github you will find a readme that explains the basic idea (and the balancing problem in general) in more detail... this implementation gives a lot more room to play with different parameter sets ... and I am sure that there are some robot fans out there that will come up with nice optimizations ;)
 
feel free to play with my code and improve it ...

Share this post


Link to post
Share on other sites

Just improved the PID contoller part:

now including: setpoint weighting, derivative filtering and anti-windup  --> improved stability for setpoint change (robot speed)

PID derivative term now ready to be used for optimization (currently not used) ... will try to come up with a working parameter set soon ;)

Edited by OmegaTom

Share this post


Link to post
Share on other sites

added:

- Improved PID parameters (derivative terms)

- IR remote control

- basic middle motor support driving a simple arm to test the control performance under variable physical conditions

current performance: see https://youtu.be/GFn5yuKCs_I

significant load change: see  https://youtu.be/Qtc4vbvJ-oA

 

future plan: LQR controller

 

Edited by OmegaTom

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.