#367 reworked ownership of tank data and facility instance to make more sense
This commit is contained in:
@@ -16,6 +16,7 @@ local core = require("graphics.core")
|
||||
|
||||
local configure = require("supervisor.configure")
|
||||
local databus = require("supervisor.databus")
|
||||
local facility = require("supervisor.facility")
|
||||
local renderer = require("supervisor.renderer")
|
||||
local supervisor = require("supervisor.supervisor")
|
||||
|
||||
@@ -129,9 +130,12 @@ local function main()
|
||||
println_ts = function (_) end
|
||||
end
|
||||
|
||||
-- create facility and unit objects
|
||||
local sv_facility = facility.new(config)
|
||||
|
||||
-- create network interface then setup comms
|
||||
local nic = network.nic(modem)
|
||||
local superv_comms = supervisor.comms(SUPERVISOR_VERSION, nic, fp_ok)
|
||||
local superv_comms = supervisor.comms(SUPERVISOR_VERSION, nic, fp_ok, sv_facility)
|
||||
|
||||
-- base loop clock (6.67Hz, 3 ticks)
|
||||
local MAIN_CLOCK = 0.15
|
||||
|
||||
Reference in New Issue
Block a user