I think the firmware of an Arduino should be able to handle this... the best part is that PID circuits will automatically adjust if they miss a cycle because that element was not priority and another one was on...
here is 'ascii-art' of NAND gates to give priority:
here is 'ascii-art' of NAND gates to give priority:
