If you connect the Arduino via serial to the Duet board, you could use something like serialOM.py to talk to the Duet and make use of the Object Model and direct GCode via serial commands to effect any changes (even bidirectional). You would still need to look into meta commands and BtnCmd or comparable to surface any info in the Web UI.