Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- os.loadAPI("lib/pidcontrollers.lua")
- local P = 0.15
- local I = 0
- local D = 0.1
- --used for integral clamping--
- local minimum_value = 0
- local maximum_value = 15
- --used for integral clamping--
- local height_PID = pidcontrollers.PID_PWM_scalar(P, I, D, minimum_value ,maximum_value)
- local height_error = current_height - target_height
- while true do
- redstone_height = height_PID:run(height_error)
- end
Advertisement
Add Comment
Please, Sign In to add comment