Added preset_pid() function, to allow smooth transtion between open-loop and closed-loop modes