I use one button to toggle enable on the control panels here in the shop.
Just put the code in the signal library in the screen load script.
I modified my code so one input will enable mach and the other will disable mach.
[mc.ISIG_INPUT6] = function (state)
if (state == 1) then
local inst = mc.mcGetInstance();
mc.mcCntlEnable(inst,1)
end
end,
[mc.ISIG_INPUT7] = function (state)
if (state == 1) then
local inst = mc.mcGetInstance();
mc.mcCntlEnable(inst,0)
end
end,