added alarm functionalities