added event listner ports for toggle and press