Recovering coming down from above setpoint

42 views
Skip to first unread message

Anders

unread,
Jun 13, 2023, 3:18:18 PM6/13/23
to DIY PID Control
Hi everybody,

I'm using a PI-controller to control the speed limit of my electric bike. Accelerating up to the speed limit/setpoint works fine. My issue is that when going down hill the speed will increase above setpoint (because of me pedalling and down hill, not because of motor) and when the road levels out and the speed decreases, it goes too far below the setpoint before starting to accelerate again. I think this is to be expected, as output will be low or zero when above setpoint (in most cases). So instead I want to achieve something like in picture B, rather than A (green is speed, black is set point). I'm using an Arduino. 
Any ideas on how to do this? Any ideas are appreciated! 

Recover.png

Pieter S

unread,
Jun 14, 2023, 12:44:32 AM6/14/23
to diy-pid...@googlegroups.com
Check if there is an "I" / Integrator-wound up limit?  If an error persist the integration term get very large and could take long to wound down resulting in shooting past the set point.

--
You received this message because you are subscribed to the Google Groups "DIY PID Control" group.
To unsubscribe from this group and stop receiving emails from it, send an email to diy-pid-contr...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/diy-pid-control/0cd0102c-3ec0-4dbc-98c1-16fe9c816d17n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages