fixed process controller assuming ramp complete if burn rate setpoint was identical to setpoint before process control start

This commit is contained in:
Mikayla Fischler
2023-02-04 13:47:00 -05:00
parent ba8bfb6e14
commit b5c70b0d37
14 changed files with 225 additions and 159 deletions

View File

@@ -41,6 +41,7 @@ function facility.new(num_reactors, cooling_conf)
induction = {},
redstone = {},
status_text = { "START UP", "initializing..." },
all_sys_ok = false,
-- process control
units_ready = false,
mode = PROCESS.INACTIVE,
@@ -199,6 +200,11 @@ function facility.new(num_reactors, cooling_conf)
self.im_stat_init = false
end
self.all_sys_ok = true
for i = 1, #self.units do
self.all_sys_ok = self.all_sys_ok and not self.units[i].get_control_inf().degraded
end
-------------------------
-- Run Process Control --
-------------------------
@@ -570,6 +576,7 @@ function facility.new(num_reactors, cooling_conf)
-- get automatic process control status
function public.get_control_status()
return {
self.all_sys_ok,
self.units_ready,
self.mode,
self.waiting_on_ramp,