Added code for the control box