changed > to >= and alarm is working