BeerSmith Recipes • Associates Batches with Recipes • Stores Times, Temperatures, and Notes • API to Integrate with Brewing Equipment 12 Thursday, March 7, 13
'temper' temper = Temper::PID.new(interval: 1000, minimum: 0, maximum: 1000, direction: :direct) temper.tune(9.0, 25.0, 6.0) # Set Kp, Ki, and Kd temper.setpoint = 100.0 # Set target temperature (Degrees Fahrenheit) while input = read_sensor() # Replace read_sensor with your external system output = temper.control(input) # output is a value between minimum and maximum. This can be used for thresholds or # PWM-‐based control end Thursday, March 7, 13