#232 option to disable flow view screen for legacy setups
This commit is contained in:
@@ -338,11 +338,21 @@ function iocontrol.fp_has_speaker(has_speaker) io.fp.ps.publish("has_speaker", h
|
||||
function iocontrol.fp_link_state(state) io.fp.ps.publish("link_state", state) end
|
||||
|
||||
-- report monitor connection state
|
||||
---@param id integer unit ID or 0 for main
|
||||
---@param id string|integer unit ID for unit monitor, "main" for main monitor, or "flow" for flow monitor
|
||||
function iocontrol.fp_monitor_state(id, connected)
|
||||
local name = "main_monitor"
|
||||
if id > 0 then name = "unit_monitor_" .. id end
|
||||
io.fp.ps.publish(name, connected)
|
||||
local name = nil
|
||||
|
||||
if id == "main" then
|
||||
name = "main_monitor"
|
||||
elseif id == "flow" then
|
||||
name = "flow_monitor"
|
||||
elseif type(id) == "number" then
|
||||
name = "unit_monitor_" .. id
|
||||
end
|
||||
|
||||
if name ~= nil then
|
||||
io.fp.ps.publish(name, connected)
|
||||
end
|
||||
end
|
||||
|
||||
-- report PKT firmware version and PKT session connection state
|
||||
|
||||
Reference in New Issue
Block a user