implment the alarm